How to run Windows command prompt utilities options in Git Bash (how to specify /slash options)?
5,341
Solution 1
Change the slash to a dash. At least it did work for me on 1.9.4 on Windows 7.
$ ipconfig -all
Alternatively escape the /
by using \/
.
$ ipconfig \/all
Solution 2
It should be ipconfig //all
(two forward slashes).
It also works in git bash; this is what is called POSIX path conversion and is documented here.
Related videos on Youtube
Comments
-
Green over 1 year
An example that doesn't work in Git Bash but only in Windows prompt:
// Git Bash $ ipconfig /all Error: unrecognized or incomplete command line. // Windows User> ipconfig /all C:\Users\sergey>ipconfig /all Windows IP Configuration Host Name . . . . . . . . . . . . : HOST-12345 Primary Dns Suffix . . . . . . . : Node Type . . . . . . . . . . . . : NodeType IP Routing Enabled. . . . . . . . : No WINS Proxy Enabled. . . . . . . . : No ... so on
How to provide slash option in Git Bash
/all
,/renew
, etc-
barlop over 7 yearsi'm curious, do you find git bash has any advantage over just adding git to the path?
-
Green over 7 years@barlop, It has many UNIX utilities enabled, like
ls
,ll
,touch
,cat
,curl
,ssh
, so on. Copy on select. Place command line cursor by click. It has colors.
-
-
Green over 7 yearsEscape didn't work for me, but a dash did the trick. Thanks!
-
Kenneth Chan almost 4 yearsit help. but if the code is in a bat file. it won't work.