I am newbie to Git bash.
Just out of curiosity trying to make a .bat file which contains commands(Dont know if Git Bash supports .bat file)
What I want to achieve is simply drag and drop this .bat file to Git Bash terminal and commands in the file get executed(Is it possible?).
My commands in .bat file
cd "C:\Users\USER\abc\xyz" cd "C:\Users\USER\abc\xyz\pqr" export HOME="C:\Users\USER\some_directory" export HOME2="C:\Program Files\directoy"
You call them as you would .exe's, normally omitting the extension. Unfortunately, these . bat files are not available inside Git Bash shells, as Git Bash fails to look them up as it does .exe's. Even when PATH is set properly, Git Bash throws its hands up as to where a batch program lies.
Launch Git Bash console by clicking on the Start button, type git, and click on Git Bash. 2. Run the below git config command to add your name ( YourName ) as your git username ( user.name ). The git config command administers configuration variables that control how Git looks and operates.
You can run batch files just from git bash e.g.
./clear.bat
From Out of a git console: how do I execute a batch file and then return to git console?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With