Skip to content

Instantly share code, notes, and snippets.

@jackinf
Last active August 19, 2019 17:32
Show Gist options
  • Save jackinf/8767548 to your computer and use it in GitHub Desktop.
Save jackinf/8767548 to your computer and use it in GitHub Desktop.
Windows CMD scripts

CMD scripts

If env variables changed and you don't want to close the session

refreshenv

Cleans all the bin folders recursively

FOR /F "tokens=*" %G IN ('DIR /B /AD /S *bin*') DO RMDIR /S /Q "%G"

Script to remove all traces in folder for specific file format

FOR /R foldername %%X IN (.hg) DO (RD /S /Q "%%X" 2>nul)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment