Archive

Archive for the ‘Terminal’ Category

Tip 16: Hide Desktop Clutter

October 17, 2009 Leave a comment

TerminalWant to give your Desktop a new clean look? With Terminal, you can forget about organizing all of your Desktop files and simply hide them. Enter this command in Terminal:

chflags hidden ~/Desktop/*

To Undo:

chflags nohidden ~/Desktop/*

This command is very useful, if you don’t want to deal with constantly having Desktop clutter.

– Alexander Garovi

Categories: Desktop, OS X, Terminal, Tips

Tip 15: Quick Software Update With Terminal

October 17, 2009 Leave a comment

TerminalHere’s a quick Terminal command that lets you install Apple’s available software updates. There are two sudo commands: one for installing all of Apple’s updates and one for only installing recommended software updates.

All Updates

sudo softwareupdate -i -a

Recommended Updates

sudo softwareupdate -i -r

More quick Terminal tips are on the way.

– Alexander Garovi

Categories: OS X, Terminal, Tips

Tip 07: Keeping Stickies In All Spaces At Once

October 7, 2009 1 comment

I use Stickies frequently to jot down notes, but have always been frustrated with the fact that you can’t assign Stickies to all spaces simultaneously if you have Spaces set up. With Spaces running, open stickies will either stay on their assigned space or stay on the space they were previously on if you change spaces. Not being able to always see your notes regardless of whatever space your in, pretty much defeats the purpose of running Stickies at all. Here’s a little solution I thought of that I hope helps those of you who have had the same problem. With this little Terminal tweak you can have the Stickies widget hover above all open windows, regardless of the space you’re in, without being in Dashboard. Here’s how you do it:

1. Type the following in Terminal

defaults write com.apple.dashboard devmode YES

2. Open the Stickies widget, click and hold it and press F12 to return to move the sticky to the desktop (If F12 is the volume adjustment key, press “fn-F12″)

Note: The dock must be relaunched for this command to work. Type “Killall Dock” in Terminal and the dock will restart.

3. To disable this command, while still keeping the mouse button pressed down on the sticky, press F12, and let go of the mouse. The Widget will be sent to the Dashboard.

Stickies Widget
The Firefox window is selected, but the sticky stays above it and isn’t assigned to a space.

Although I still prefer the UI of the Stickies application, along with having individual stickies, this  widget tweak is nice, because it can be seen in all spaces, over any selected windows.

– Alexander Garovi

Categories: Stickies, Terminal, Tips

Tip: 06 Playing Games In Terminal Part 2

October 6, 2009 Leave a comment

This is part two of yesterday’s Tetris in Terminal article. Here is a list of Unix based files that you can access in Terminal. Simply type the following codes into a Terminal window.

1. Open Terminal and type emacs then Esc-X
Enter any of the following words to play these games

Pong
Pong.png

Snake

Snake.png

Dunnet – An adventure text-based game

Dunnet

Doctor – Terminal becomes a Doctor you can talk to
Doctor

Life – Text screen saver

Life

Zone – Strange text manipulator

– Alexander Garovi

Categories: Terminal, Tips

Tip 05: Play Tetris In Terminal

October 4, 2009 Leave a comment

Tetris.png Oh, the endless possibilities of Terminal. Not only can you use it to manipulate your Mac, but even play Tetris in it. Here’s how you do it:

1. Open Terminal
2. Type in emacs and press enter
3. Press Esc-X and you’ll see M-x at the bottom of the screen
4. Type Tetris and press enter

And there you go – Tetris will now open in Terminal. Use the arrow keys to move the blocks around and spacebar to drop them. You can exit by pressing Control-X – Control-C, or by just quitting Terminal.

– Alexander Garovi

Categories: Terminal, Tips

Top 25 Terminal Commands To Customize Your Mac

October 3, 2009 Leave a comment

Terminal

Terminal is a great way to customize your Mac and gain access into hidden features. However, Terminal can also destroy your system, if not used responsibly. Here is a list of quite useful commands I’ve made that do some pretty cool things. These commands range from system based hacks, to appearance changing commands for your Dock and Desktop. Some of these commands require a system reboot and can be disabled. Let the fun begin.

1. Dragging Widgets Onto the Desktop
This Terminal command lets you place Dashboard widgets on your Desktop. In order to take effect the dock must be re-launched. To relaunch the Dock, type “Killall Dock” in Terminal. Click on the widget and press F12 to return to the desktop (If F12 is the volume adjustment key, press “fn-F12”).

To disable the command, keep the mouse button pressed down, press F12, and let go of the mouse. The Widget will be sent back to Dashboard.

defaults write com.apple.dashboard devmode YES

iTunes Widget.png

2. Make Hidden Applications Transparent
This command makes it easier to see which applications are hidden on your dock. You must relaunch the dock for this command to take effect: type “Killall Dock” in Terminal. Type “NO” at the end of the command to disable it.

defaults write com.apple.Dock showhidden -bool YES

Hidden Apps.png

3. Deactivate Dashboard
The Dock must be relaunched for this to work. Type in “Killall Dock” in Terminal to relaunch the Dock.

defaults write com.apple.dashboard mcx-disabled -boolean YES

4. Show Hidden Finder Files
To disable this command, replace “TRUE” at the end of the command with “FALSE”

defaults write com.apple.finder AppleShowAllFiles TRUE

5. Use The Screen Saver As The Wallpaper
Sets your selected screen saver as the Desktop background. To disable the command, press Command-Period.

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

6. 2D Dock
Changes the 3D dock to a flat 2D one. The Dock must be reset, by pressing “Killall Dock” in Terminal.

defaults write com.apple.dock no-glass -boolean YES
killall Dock

7. Increase Dock Magnification
Increases the size of magnified Dock icons. WARNING: Don’t go past 512.

defaults write com.apple.dock largesize -int 512

8. History Limit For Safari
Sets history limit to a certain amount of entries or to a certain age.

defaults write com.apple.Safari WebKitHistoryItemLimit 2000
AND / OR
defaults write com.apple.Safari WebKitHistoryAgeInDaysLimit 30

8. Removing The Spotlight Icon
To disable this command, replace the “0” in the command with “755”.

sudo chmod 0 /System/Library/CoreServices/Spotlight.app
killall Spotlight

9. Show Both Ends Of The Scrollbar
To reset, use the Appearance pane in System Preferences.

defaults write “Apple Global Domain” AppleScrollBarVariant DoubleBoth

10. All Mail Displayed As Plain Text
To disable this command, replace “TRUE” with “FALSE”

11. Path View In Finder
This hack is extremely useful, letting you view the path of the folder your looking at.

Finder Path.png

defaults write com.apple.finder _FXShowPosixPathInTitle -bool YES

12. Quit Finder

Quit Finder.png

defaults write com.apple.finder QuitMenuItem -bool YES
killall Finder

13. Have Dock On The Left
To disable this command, replace “start” with “middle”.

defaults write com.apple.dock pinning -string start

14. Have Dock On The Right

defaults write com.apple.dock pinning -string end

15. White Menu Bar
This hack requires you to type your password and a system reboot

sudo defaults write /System/Library/LaunchDaemons/com.apple.WindowServer ‘EnvironmentVariables’ -dict ‘CI_NO_BACKGROUND_IMAGE’ 1

To go back to default, use this command:

sudo defaults delete /System/Library/LaunchDaemons/com.apple.WindowServer ‘EnvironmentVariables’

16. Grey Menu Bar

sudo defaults write /System/Library/LaunchDaemons/com.apple.WindowServer ‘EnvironmentVariables’ -dict ‘CI_NO_BACKGROUND_IMAGE’ 0

To Go back to default, use this command:

sudo defaults delete /System/Library/LaunchDaemons/com.apple.WindowServer ‘EnvironmentVariables’

17. Enable Time Machine On Unsupported Drives
It is unsupported, so use with caution

defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1

18. Increase Desktop Icon sizes
This hack let’s you increase your icon size up to 512 pixels x 512 pixels.

defaults write com.apple.finder DesktopViewOptions -dict IconSize -integer 512
killall Finder

19. Bigger Dock
Don’t go any larger than 256. In System Preferences, you can reduce its size.

defaults write com.apple.dock tilesize -int 256

20. Change Time delay Of Dragging Windows Into Different Spaces
The default time delay is .75

defaults write com.apple.dock workspaces-edge-delay -float 0.5

21. Replace Safari Loading Bar With A Pie Chart (Safari 3)
This Safari hack eliminates the blue bar that is situated in the address bar. To deactivate this command, replace “TRUE” with “FALSE”

22. Force Quitting Processes Using Terminal
To quit processes using Terminal, you must know the Process ID (PID) of the app you want to quit. PIDs can be found in Activity monitor. Once you know the PID of the app, simply type “kill PID [NUMBER HERE].

kill PID 204

23. Star Wars Episode IV
This is definitely worth your time 🙂

telnet towel.blinkenlights.nl

Star Wars

24. Change The Format Of Screen Shot Images
In Terminal, replace “jpg” in the code below with whatever format you want – png, gif etc. For this change to take effect, you must log out and in again or restart your system.

25. Make Time Machine Backups More Frequent
Sometimes I want my Time Machine to do backups more frequently. With this hack, you can do so. The default time is 3600 seconds – one hour. Simply replace that amount of time with the amount of time you want in seconds.

sudo defaults write /System/Library/LaunchDaemons/com.apple.backupd-auto StartInterval -int 3600

– Alexander Garovi

Categories: Terminal, Tips