I'm using batch files quite often to automatize some processes, but I'm still really unexperienced. As I know that there are coders here that have worked with batch files way longer and are experienced, I thought, I'd kindly ask for help here if someone could post a little script, that does the following:
- move all files of a downward folder structure into the directory the script is started
- rename each file with its file path, replacing "/" with "~" and taking the location of the script as root
The folder structure can be really deep, so it's best to keep the above order to avoid names with more than 256 characters.
If it's easier, just take the full path - deleting the parts I don't need is easy.
I'd be very thankful if someone could post such a batch here!
Thanks for your help!

