Top Command Line Commands Every CMD, Git Bash, and PowerShell User Should Know

Top Command Line Commands Every CMD, Git Bash, and PowerShell User Should Know

As a full-stack web developer, mastering terminal commands is crucial for efficient workflow and system management. Whether you’re using Command Prompt (CMD), Git Bash, or PowerShell, here are some essential commands to enhance your productivity.

DetailsCMDPowerShellGit Bash
Check current directorycdpwdpwd
Check inner file/directorydirdir or lsdir or ls
Show hidden filedir/a:hdir -forcels -a
Create directorymkdir <directory_name>mkdir <directory_name>mkdir <directory_name>
Delete directoryrmdir <directory_name>rmdir <directory_name>rmdir <directory_name>
Force delete directoryrmdir <directory_name -force>
Change directorycd <directory_name>cd <directory_name>cd <directory_name>
Go to parent directorycd ..cd ..cd ..
Create file in a directoryecho >file.extecho >file.exttouch file.ext
Delete filedel <file.ext>rm <file.ext>rm <file.ext>
Force to delete filerm <file.ext -force>
Open filestart <file.ext>start <file.ext>start <file.ext>
Rename file/directory nameren <old_name> <new_name>mv <old_name> <new_name>mv <old_name> <new_name>
Clear terminalclsclsclear
Copy any filecopy <file_name.ext>Copy-Item <file_name.ext>cp <file_name.ext>
System informationsysteminfoGet-ComputerInfosysteminfo

Conclusion

Mastering these terminal commands can significantly streamline your development process, making tasks like file management, system navigation, and version control more efficient. Whether you’re working on a new project or maintaining an existing one, these commands will help you navigate and manage your system with ease.

Feel free to explore and experiment with these commands to see how they can fit into your workflow. Happy coding! 🚀

Feel free to connect with me on social media: