Created
June 24, 2014 16:15
-
-
Save caiguanhao/d2f5528e27b30d214548 to your computer and use it in GitHub Desktop.
Unix/Linux commands on Windows
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(echo @echo ^%cd^%) > C:\WINDOWS\pwd.bat | |
(echo @copy %*) > C:\WINDOWS\cp.bat | |
(echo @move %*) > C:\WINDOWS\mv.bat | |
(echo @dir /d %*) > C:\WINDOWS\ls.bat | |
(echo @dir %*) > C:\WINDOWS\ll.bat | |
(echo @dir /b %*) > C:\WINDOWS\l.bat | |
(echo @del %*) > C:\WINDOWS\rm.bat | |
(echo @explorer %*) > C:\WINDOWS\open.bat | |
(echo @type %*) > C:\WINDOWS\cat.bat | |
(echo @more %*) > C:\WINDOWS\less.bat | |
(echo @cls %*) > C:\WINDOWS\clear.bat | |
(echo @where %*) > C:\WINDOWS\which.bat | |
(echo @taskkill /f /im %*) > C:\WINDOWS\pkill.bat | |
(echo @query process) > C:\WINDOWS\ps.bat | |
(echo @query session) > C:\WINDOWS\w.bat | |
(echo @query user) > C:\WINDOWS\who.bat | |
(echo @echo ^%username^%) > C:\WINDOWS\whoami.bat | |
(echo @shutdown /t 0 /r /f) > C:\WINDOWS\reboot.bat | |
(echo @wmic logicaldisk get Caption, Description, FileSystem, FreeSpace, Size) > C:\WINDOWS\df.bat | |
(echo @runas /noprofile /user:Administrator "cmd /c %*") > C:\WINDOWS\sudo.bat |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment