10 Cool MacOS Terminal Commands

Terminal is an application that runs commands given by user, actually there is a special program inside Terminal called Shell – which reads in commands and execute them on Mac OS operating system.Terminal’s only job is to open windows and manage shells, while shells actually do real work of Command Execution.

Next question to be asked will be What are Terminal Commands? Terminal Commands are specific instructions which can be given to Mac OS Operating. For example – pwdcd ~ls and many more. Just note that these commands are case-sensitive, so PWD will not work and pwd will work.

Below is a table containing some simple, but useful Terminal Commands

Terminal Commands in MacOS
Displaying a Calender on Terminal
cal apr 2021
Listing content inside Applicaiton Folder of Mac
ls /Applications
Number of items in Documents Folder of Mac
ls $HOME/Documents | wc -l
How much space is used on Hard Disk
df -h /
Seeing What processes are currently running on Mac
top
Check How long you’ve been logged in
last -1 $USER
Download PDF File to MAC without Browser
curl -0 URL (Just replace URL here with PDF URL which you want to download)
mv sample.pdf $HOME/Desktop
Display IP address of Mac
ipconfig getifaddr en0     (For MAC wired to Wi-Fi)
ipconfig getifaddr en1 (For wireless connection to Wi-Fi)
Get Information about a Domain Name
whois domain_name.com | less
Clearing Terminal Window
clear
Exiting Terminal Window
exit

These are some of cool but quite useful Mac OS Terminal Commands. I hope that you found this article useful, if in case you don’t know about What is Terminal in Mac or how does Terminal actually works? then check out this article – Introduction to Mac OS Terminal.

Gagan

Hi, there I'm founder of ComputerScienceHub(Started this to bring useful Computer Science information just at one place). Personally I've been doing JavaScript, Python development since 2015(Been long) - Worked upon couple of Web Development Projects, Did some Data Science stuff using Python. Nowadays primarily I work as Freelance JavaScript Developer(Web Developer) and on side-by-side managing team of Computer Science specialists at ComputerScienceHub.io

Leave a Reply

Your email address will not be published. Required fields are marked *

Recent Posts