Najeebsk

CMDR.ahk

Dec 13th, 2023
131
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ;#Warn
  2. #NoEnv
  3. #SingleInstance, Force
  4. SetWorkingDir %A_ScriptDir%
  5. global winTitle
  6. winTitle := "ahk_class ConsoleWindowClass"
  7. Gui, -DPIScale
  8. Gui,Font,s12 CYellow,Lucida Console
  9. Gui,Color,Black, Black
  10. ;--------------------------
  11. Commands =
  12. (Ltrim Join|
  13. mspaint.exe
  14. notepad.exe
  15. write.exe
  16. charmap.exe
  17. calc.exe
  18. winver.exe
  19. vlc.exe
  20. APP\PDF.exe
  21. ATTRIB +H +S +R *.*
  22. ATTRIB -H -S -R *.*
  23. START Mspaint.exe & Exit
  24. START winword
  25. START shutdown -s -f -t 300 -c "Should have asked for permission...SHUTDOWN INITIATED"
  26. START D:\DATA
  27. START http://www.google.com/
  28. START http://www.youtube.com/
  29. START APP\Everything.exe
  30. START C:\Users\%USERNAME%\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup
  31. TYPE NUL > EMPTY-FILE.*
  32. TYPE NUL > %CD%\EmptyFile.txt
  33. MD NAJEEB
  34. MD user1 user2 user3
  35. MD "my example directory"
  36. MD c:\test
  37. MD c:\test1\test2
  38. MKDIR "computer hope"
  39. MKDIR \a\b\c\d      ;For example, assume \a does not exist then:
  40. MKDIR \A\B\C|MD ..\example
  41. CALL notepad.exe
  42. COPY *.* D:
  43. COPY *.txt C:\Users\Najeeb\Desktop\
  44. COPY D:\file1.txt+Z:\file2.txt+Z:\file3.txt D:\combined.txt
  45. COPY /b DATA\PIC.jpg + File.rar DATA\PICNEW.jpg
  46. COPY /b DATA\P.jpg + PIC.rar DATA\PICR.jpg
  47. COPY myfile1.txt+myfile2.txt
  48. COPY /b Pic.jpg+Text.txt NewPic.jpg
  49. COPY /b PIC.jpg + File.rar PICNEW.jpg
  50. XCOPY C:\Files E:\Files /i
  51. XCOPY C:\Videos "\\SERVER\Media Backup" /f /j /s /w /z
  52. XCOPY "C:\Important Files" D:\Backup /c /d /e /h /i /k /q /r /s /x /y
  53. ROBOCOPY C:\hope C:\hope2 *.txt
  54. ROBOCOPY C:\hope C:\hope2
  55. ROBOCOPY C:\hope C:\hope2 /e
  56. ROBOCOPY C:\hope C:\hope2 /MIR
  57. ROBOCOPY \\computer\hope C:\hope2
  58. MOVE *.doc c:\statistics
  59. MOVE /y "*.*" DATA\
  60. MOVE /y "E:\*.*" D:\
  61. MOVE c:\windows\temp\*.* c:\temp
  62. MOVE "computer hope" example
  63. MOVE c:\example.txt h:
  64. MV       ;Copy in-use files
  65. MV hope.txt hope.html
  66. RENAME *.txt *.bak
  67. RENAME "computer hope.txt" "example file.txt"
  68. RENAME *.shn *.wav
  69. REN *.* *.EXT REN *.EXT *.EXT
  70. REN *.DOC *.TXT
  71. REN *.JPEG *.TXT
  72. REN *.BAT *.TXT
  73. ;DEL C:\windows\temp\*.*  NoteUse
  74. ;DEL "*.rar"
  75. ;DEL /F *.ext
  76. ;DEL /S /Q "*.*"
  77. ;DEL J:\*.* /F /S /Q
  78. ;Rmdir old_folder /s /q
  79. ;RD /S /Q D:\  Note Use
  80. DIR /W /B >> LIST.EXT
  81. DIR C:\"Program Files" >> %COMPUTERNAME%-IS.txt
  82. DIR /S /B /A  "C:\" >> %COMPUTERNAME%-LISTC.txt
  83. DIR /S /B /A  "D:\" >> %COMPUTERNAME%-LISTD.txt
  84. DIR /A:H /S /B >> LIST.txt
  85. CMD /R DIR /B > List.txt
  86. DIR \*.mp3 /s /b > filename.txt
  87. DIR /B > List.txt
  88. DIR > myfile.txt
  89. DIR /s /a:hs /q C:\Windows > myfile.txt
  90. DIR \ /s | find "i" | more
  91. DIR \ /s /b | find /I "searchstring"
  92. DIR \ /s /b | find /I "mike"
  93. SHUTDOWN Shutdown the computer
  94. SHUTDOWN -s -t 100 c “Installing Updates”
  95. @SUBST Z: "G:\F"    (VIRTUAL-FOLDER-DRIVE-Z)
  96. @SUBST Z: /D          (UN-VIRTUAL-FOLDER-DRIVE-Z)
  97. APP\Split.exe File.txt -b 10m    (Cut 1 To 500 MB)
  98. APP\Split.exe File.txt -l 100    (Cut 1 To 1000... Lines)
  99. schtasks /create /tn "MyTask" /tr "C:\Path\to\Task.exe" /sc daily /st 12:00
  100. ;-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-;
  101. APP\rar a archive.rar file.txt
  102. APP\rar a -pYourPassword archive.rar file.txt
  103. APP\rar a -v10M archive.part1.rar file.txt
  104. APP\rar a -sfx archive.exe file.txt
  105. APP\rar u archive.rar newfile.txt
  106. APP\rar x archive.rar
  107. APP\rar x archive.rar -o+
  108. APP\rar l archive.rar
  109. APP\rar t archive.rar
  110. APP\rar r archive.rar
  111. APP\rar c archive.rar
  112. APP\rar d archive.rar file.txt
  113. APP\rar u -s archive.rar
  114. APP\rar a -m5 archive.rar file.txt
  115. APP\rar a -x*.bak archive.rar folder/
  116. APP\UnRAR.exe E -inul -y -psonyNSK "PIC.rar" "%CD%"COLOR A5,E9,1B & MODE 65,3
  117. APP\Rar a -r -psonyNSK PIC.rar %CD%
  118. APP\Rar.exe a -psonyNSK secrate game\*.*
  119. APP\Rar.exe a -psonyNSK secrate.rar Folder/File
  120. APP\UnRar.exe x -psonyNSK *.rar/secrate.rar
  121. APP\rar.exe a -psony FileName.rar File.ext or Folder
  122. APP\unrar.exe x -psony File.rar
  123. APP\7z.exe a -psony File.7z File.ext or Folder
  124. APP\7z.exe x -psony File.7z
  125. APP\7z a archive.7z file.txt
  126. APP\7z a -pYourPassword archive.7z file.txt
  127. APP\7z a -v10M archive.7z file.txt
  128. APP\7z a -sfx archive.exe file.txt
  129. APP\7z u archive.7z newfile.txt
  130. APP\7z x archive.7z
  131. APP\7z t archive.7z
  132. APP\7z r archive.7z
  133. APP\7z c archive.7z
  134. APP\7z d archive.7z file.txt
  135. APP\7z u archive.7z
  136. APP\7z a -mx=5 archive.7z file.txt
  137. APP\7z a archive.7z folder/ -x!*.bak
  138. APP\zip.exe -r File.zip File.ext or Folder
  139. APP\zip.exe -x File.zip
  140. APP\gzip.exe File.ext
  141. APP\gzip.exe -d File.ext
  142. APP\tar cvf File.tar File1.txt File2.txt .....
  143. APP\tar xvf File.tar
  144. APP\bzip2.exe -z B.txt  or bunzip2
  145. APP\bzip2.exe -d B.txt.bz2
  146. APP\bzip2.exe -d •.bz2
  147. APP\base64.exe B.txt > F.txt
  148. APP\base64.exe -d F.txt > B.txt
  149. )
  150. Gui,Font,s12 CYellow,Lucida Console
  151. Gui,Color,Black, Black
  152. Gui, Add, DropDownList, x10 y10 vCmdDropdown gCMD w800
  153. Gui, Add, Edit, vCmdEdit x10 y40 w800 h60
  154. Gui, Add, Button, x10 y110 Default, Run Command
  155. Gui, Add, Button, x160 y110 gREF,REFRESH
  156. ; Add your predefined commands to the dropdown list
  157. ;Commands := "dir|ipconfig|ping|netstat|systeminfo|notepad"
  158.  
  159. Loop, Parse, Commands, |
  160.     GuiControl,, CmdDropdown,  %A_LoopField%
  161.    
  162. Gui, Show, w820 h150 , NAJEEB CMD Command Runner
  163. return
  164.  
  165. GuiClose:
  166. ExitApp
  167. CMD:
  168. Gui, Submit, NoHide
  169. GuiControl,,CmdEdit, %CmdDropdown% ; Clear the dropdown list
  170. return  
  171.  
  172. ButtonRunCommand:
  173.    Gui, Submit, NoHide
  174.     SelectedCmd := CmdEdit       ;CmdDropdown
  175.  
  176.     if (SelectedCmd != "") {
  177.         ; Run the CMD command
  178.         RunWait, %ComSpec% /c %SelectedCmd%, , Hide
  179.     }
  180. return
  181. REF:
  182.    Gui, Submit, NoHide
  183. Reload
  184. return
  185. ;============ END SCRIPT ==============
  186. #R::Reload
  187. #S::Suspend
  188. #P::Pause
  189. #ESC::ExitApp
Add Comment
Please, Sign In to add comment