10 useful commands for Terminal in Mac

Terminal is a powerful tool in OS X. You give your computer commands, and the operating system performs them dutifully. Using terminal, you can perform actions that much more difficult or impossible to perform using graphical user interface. However, the terminal can not be called a friendly tool for common users. Many of his shun in fear to give the wrong command, and to deal with unforeseen consequences. In this article you will find a selection of simple and even funny teams from which to start exploring the terminal.

Check response from the server

The Ping command allows you to check the availability of a domain name or IP address. You can also see how quickly will be given a response from the server. Try to see how quickly you get a response from “www.appleinisder.ru”. For this there is a very simple command:

ping www.appleinsider.ru

To disable the shadow in screenshots

If you make a screenshot of a window in OS X, by default it is created with shadow. You can disable the shadow in screenshots with a simple command:

defaults write com.apple.screencapture disable-shadow-bool TRUE

After it type:

are true systemuiserver killall

This command will cause the changes to take effect. If you want to re-enable the shadows in the screenshots, just perform the same operation, replacing the command “TRUE” to “FALSE”.

Show hidden files in Finder

Order in the Finder started to show all hidden files, just type in the terminal:

defaults write com.apple.finder AppleShowAllFiles -bool TRUE

To apply the changes you need to restart Finder. For this you can use the command:

killall Finder

All hidden files will be shown. Want to hide them? Follow the same steps, replacing the command “TRUE” to “FALSE”.

Make your Mac speak

A simple command you can force your computer to pronounce any phrase. Try typing:

say Hello the terminal says

Make your Mac to give up sleep

If you need to avoid falling asleep your computer, it is very simple to do with the help of the terminal. Type:

caffeinate

You can also specify the time that the Mac needs to work without sleep, in seconds:

caffeinate -t 150000

You can prematurely cancel the command with Ctrl+C.

View the command history in the terminal

To remember all that you have entrusted the terminal, type:

history

Want to clear the command history? Type:

history-c

Stress test

The stress test will create a process to “yes” and point to execute all the power of the processor. We then discussed the use of this command. To do a stress test just:

yes > /dev/null &

To complete the process with the command:

killall yes

To turn on the sound charger connection from iOS

Typically the Mac is silent when you plug in the charger. If you want to turn up the volume on this is similar to what makes your iPhone. It is enabled with the following command:

defaults write com.apple.PowerChime ChimeOnAllHardware -bool TRUE; open /System/Library/CoreServices/PowerChime.app &

To disable this sound, use the command:

defaults write com.apple.PowerChime ChimeOnAllHardware -bool FALSE; killall PowerChime

To check for updates to OS X often

Your computer itself checks for the updates of the system. If you want to check more often than he does, you can check manually, and can just ask OS X to check for updates often using the terminal. Want instead of weekly checks to include daily? For this is the following command:

defaults write com.apple.SoftwareUpdate ScheduleFrequency -int 1

As you can guess, in order to return to a weekly check, use the command:

defaults write com.apple.SoftwareUpdate ScheduleFrequency -int 7

Put screen saver as Wallpaper

If you are in some weird mood and it’s so unusual that you want to use splash screen instead of Wallpaper on your Mac, try the command:

/System/Library/Frameworks/ScreenSaver.framework/Resources/ScreenSaverEngine.app/Contents/MacOS/ScreenSaverEngine -background

As soon as you close Terminal or press Ctrl+C, you will return to your usual Wallpaper.

We offer you to subscribe to our channel in “Yandex.Zen”. There you can find the exclusive materials that are not on the website.

Leave a Reply

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