10 Cool things to do in OSX Terminal

The thing that made me buy mac is that it has a OS based on Unix, and programs like Photoshop and Microsoft Office (not a big OpenOffice fan yet). Like a good nerd, I can’t live without my beloved terminal, which makes my life easier. In this post I will show some commands so you can have fun on mac’s terminal. Hope you like it, and if you have any other ideas, please comment on the post!

1. Twitter Update

    Nothing more geek than updating your twitter from terminal. Just change the user e pass from the pre. Way cool.

    curl -u user:pass -d status="Tweeting from the shell" http://twitter.com/statuses/update.xml

2. Sing songs

    Release your creativity, sing along.

    sudo osascript -e 'say "Dum dum dum dum dum dum dum he he he ho ho ho fa lah lah lah lah lah lah fa lah full hoo hoo hoo" using "Cellos"'

3. Download from a unstable server

    You know, sometimes you are downloading a big file, but it keeps failing, and you always have to hit RESUME. Your problems are over, with this pre, if the download stops suddenly, it will automatically restart. This pre have a 15kbps speed limit, delete –limit-rate 15k to remove the speed limit.

     while ! curl -C - -O --limit-rate 15k file-address-goes-here; do sleep 10; done

4. Secure SSH Tunnel

    This is very important if you are using a public/open wireless connection. If you want to access your bank information or online shopping, making sure no one is stealing your information, then SSH Tunneling is the solution. You can find more information HERE.

    ssh -D 8080 -f -C -q -N myuser@myserver.com

    From: Stammy

5. Real-time view of a running processes

    To know what is running on your computer, how much memory and processing, just hit:

    top

6. Resize pictures

    One quick way to resize pictures in a batch is using a simple program called SIPS. In this example, I’m resizing all pictures .JPG to a 500 pixels width. For more information, type on terminal man sips

    sips --resampleWidth 500 *.JPG

7. Build a fast and simple HTTPD server

    If you want to start a simple HTTPD server on the 8080 port, go to the folder you want to show and use the command:

    python -m SimpleHTTPServer 8080

8. Kill a process

    When using top, you have access to the processes ID, and if they are using too much RAM (for example), you can kill it.

    killall firefox
    kill 234

9. Watch Star Wars Episode IV

    No comments on this one 🙂

    telnet towel.blinkenlights.nl

10. Show hidden files (those with . in front of the name) in Finder

    defaults write com.apple.finder AppleShowAllFiles TRUE

Thanks for readying.

Comments

    1. Hey, they are all cool, but you have to do this for the Star Wars.
      1.Go to Run
      2.Type in telnet
      3.Press Enter
      4. When telnet opens press the letter o, then press enter.
      5. type in towel.blinkenlights.nl

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.