cygwin

SSH/SCP quick help

Written by  on October 17, 2019

Challenge was to reconfigure a device, which has a Linux running on a TQ-board. Some files had to be adjusted.

Connect to the device:

(Then enter password.)

List amount of free space:

Show target of symlink:

“un-optimize” a VisualStudio-solution

Written by  on March 2, 2018

By default after generating the solution from mpc-files for each vcxproj the optimization-level is set to maximum (O2), which can lead to trouble while debugging. Variables not “visible”, content of containers not readable, .. and then you can stop debugging, reset manually the optimization, restart and go to the breakpoint/crash. Which is a total waste of time.
I’ve also found no way to convince the mpc-buildsystem of building un-optimized.

Ok, then we build us a sed-oneliner which replaces in all project-files the line about optimization and run it under cygwin:

Need to fake some incoming packets?

Written by  on October 26, 2017

Try Packet Sender (available for all major OS: I used the portable version for Windows as well as the AppImage for Linux (I love that AppImage-idea. Already the third OSS which was packaged like this instead of a *.deb or as pure source ..)) to emulate the sending of some UDP-datagrams to test one of my programs. And it works really neatly.
You’ve got a tidy window with some textfields for receiver, type and content, a “fire away”-button, some repeat-ability. Nice!
On the receiving end we all know Wireshark. But the emulation was (at least to me) before some big black hole.

Yes, I know, there would be as well sendip. But at work I barely could make a Cygwin work. Not to speak about some dynamic “oh, I load more packages on the fly from the internet”-possibility, meh.
But for those interested: short tutorial for sendip.

clean my code: reloaded!

Written by  on June 21, 2017

As always: some projects need a first (working) implementation and then over time you can improve them.
During lunch I was talking with a colleague about this tool. Then the idea to just use those actually changed files from the current implementation (means: the current branch in Git) shall be used as input. Et voila: consider it done!
Also added some fine-tuning to the call-parameter of the script itself, so it can be run as well with some custom string beside “todoM” (which is my marker).

Cleaning an implementation of properly tagged lines takes now a second – not minutes (like before!
Enjoy and have fun 🙂

Code can be found as always at https://github.com/marcelpetrick/cleanMyCode/blob/master/remove_todoM.sh

collection of hints for the easier use of cygwin

Written by  on June 14, 2017

some better package-manager than via that set-up.exe: apt-cyg!
url: https://github.com/transcode-open/apt-cyg
=================================================
make shell-scripts runnable under Win (7):
add to the first line after “#!/bin/bash

else you get the error message that “\r” is not a command … ha
=================================================
how to use proxy for firewalled use:

Maybe more will be added. All just small, but fixing tricky