Skip to content

Instantly share code, notes, and snippets.

@kylelambert101
Created November 3, 2020 14:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kylelambert101/b1f061ada44057611ab271d1324b9d2c to your computer and use it in GitHub Desktop.
Save kylelambert101/b1f061ada44057611ab271d1324b9d2c to your computer and use it in GitHub Desktop.
Git Bash -> Call CMD Prompt
# To run a cmd command from git bash, prefix with "cmd //c"
cmd //c echo %PATH%
# I have experienced scenarios where I have custom batch files that are in my cmd
# path and I want to call them from Git Bash.
# To do this, alias the command names in ~/.bashrc to add the cmd prefix:
# .bashrc
alias search='cmd //c search'
alias explore='cmd //c explore'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment