7 of the Useful Mac Terminal Commands You Should Know
7.0/7 rating 1 vote

7 of the Useful Mac Terminal Commands You Should Know

The terminal is a wonderful app for Macs that allows you to get a number of tasks done on your machine without requiring you to interact with the graphical user interface. In a Terminal window, you can just type a command, it will be executed and its actions will be performed on your Mac.

Now that you know Terminal is a great command line tool, you might want to learn some of the commands that you can use this command line tool. In the post below, we have compiled some of the great Mac Terminal commands that you should know as an Apple Mac user.

1. Burning Disk Images to DVD

If you don’t already know, Terminal can help you burn a disk image to a DVD on your Mac. This won’t work if your Mac doesn’t have a DVD drive, though.

Open Terminal and type in the following command and press Enter to execute the command. Replace mydiskimage.img with the name of your disk image.

hdiutil burn ~/mydiskimage.dmg

Useful Mac Terminal

It should get the disk image burned on your DVD.

2. Convert Files to Web Pages

If you have a file on your Mac that you would like to convert to a web page, i.e., HTML format, then Terminal can help you do that with a single command as follows:

textutil -convert html ~/filename.txt

Useful Mac Terminal

In the above command, replace filename.txt with the file that you wish to convert to the web page format.

3. Get Easy Access to the Recent Apps in the Dock

You can now add a section in your Dock that shows your recently opened applications. That way you can quickly get access to an app that you have recently launched on your Mac.

Type in the following command into a Terminal window and press Enter.

defaults write com.apple.dock persistent-others -array-add \
'{ "tile-data" = { "list-type" = 1; }; "tile-type" = "recents-tile"; }' && \
killall Dock

Useful Mac Terminal

It should add a new section to the Dock on your Mac where you can see your recent apps.

4. Divide Dock Icons with a Divider

If you would like to divide the apps in the Dock in their sections, then you can use the following command to do that:

defaults write com.apple.dock persistent-apps -array-add '{"tile-type"="spacer-tile";}' && \
killall Dock	

Useful Mac Terminal

What the command will do is it will create a blank space in the Dock that helps you separate your apps there.

5. Changing the Dock Settings Back to the Default

If you have played around with the Dock on your Mac a little too much, you might want to set the settings back to default so it looks like what it did when you first booted up your Mac.

Open Terminal and type in the following command and press Enter to reset the Dock.

defaults delete com.apple.dock && \
killall Dock	

Useful Mac Terminal  

6. Close the Finder App

You will see the quit option in all of the apps on your Mac but the Finder is the only app that doesn’t have this option. Fortunately, you can have that option added to the Finder using the following command in Terminal:

defaults write com.apple.finder QuitMenuItem -bool true && \
killall Finder

Useful Mac Terminal

The Finder should now have the quit option.

7. Hide and Unhide Icons on the Desktop

If you would like to hide but not delete all of the icons on your Mac’s desktop, then you can do so using the following command in Terminal:

defaults write com.apple.finder CreateDesktop -bool false && \
killall Finder	

Useful Mac Terminal

All of the icons on your desktop will now be hidden. Your desktop should now be completely empty.

If you would like to unhide the icons and to bring them back, use the following command in Terminal:

defaults write com.apple.finder CreateDesktop -bool true && \
killall Finder

Useful Mac Terminal

The icons should now be back on your desktop.

So, above were some of the useful commands you could use in the Terminal app on your Mac. Let us know if these commands helped you achieve more on your Mac!


Author

Mahesh Makvana
Mahesh Makvana

Mahesh is a tech enthusiast who loves writing about technology. Mostly, he prefers writing How To posts that help users get the most out of their tech gadgets. While he is not writing a post, he's usually thinking of the next set of posts he could create. You can follow him on Twitter at @maheshhari.

comment

Leave a comment

You are commenting as guest.

About Website

OMG!HOWTO is a technology website where we cover the latest from Apple, Facebook, Microsoft and Tips & Tricks. We seek to present fresh news, useful tips, tutorials, applications that the modern technology user will appreciate. OMGHOWTO.COM is powered by Joomla.

0
Shares
0
Shares