Terminal Commands

Discussion in 'Mac Basics and Help' started by Big Ron, Aug 25, 2015.

  1. Big Ron macrumors 6502

    Big Ron

    Joined:
    Dec 7, 2012
    Location:
    United Kingdom
    #1
    Whenever I read posts I am always impressed when someone offers a terminal command that fixes a problem. Cudos to those who know such commands. What I was wondering was: Are these commands learned over many years of Mac ownership? Are they only available to a select few who dare to envoke them OR is there a central repository, where they are all listed, that I could explore for myself.

    Ideally could anyone suggested a TRUSTED link where these commands are listed, preferably with examples of their correct usage?

    Thnaks in advance
     
  2. simonsi macrumors 601

    simonsi

    Joined:
    Jan 3, 2014
    Location:
    Auckland
    #2
    Sure. Open Terminal. Type "help" and a list of commands will be presented. Type man -k <command> (eg "man -k mkdir"), and help for that command and its options will be displayed. You could also look here on this site: http://guides.macrumors.com/Terminal

    Personally I use and document a few terminal commands for specific purposes, those that use it daily and/or professionally will learn it much as any other language.
     
  3. Big Ron thread starter macrumors 6502

    Big Ron

    Joined:
    Dec 7, 2012
    Location:
    United Kingdom
    #3
    Thanks simonsi for a speedy reply. I am happy to 'dip my toe in the water' as they say on a 'need to' basis but a central TRUSTED 'go to' reference is perfect.
     
  4. lowendlinux Contributor

    lowendlinux

    Joined:
    Sep 24, 2014
    Location:
    North Country (way upstate NY)
    #4
    Just google unix commands there are a few sheets out there that list a vast majority. The terminal is the best place to be if you want to just get administrative stuff done. I have total terminal installed on the various Macs I use set it to drop down and close with opt-space it's handy. The best way IMHO to start leaning the command line is to do simple things with it first like updating (sudo softwareupdate -i -a) get used to that then expand out.
     
  5. Taz Mangus macrumors 68040

    Taz Mangus

    Joined:
    Mar 10, 2011
    #5
  6. Zedsdead185 macrumors 6502

    Joined:
    Sep 14, 2006
    Location:
    UK
    #6
  7. Big Ron thread starter macrumors 6502

    Big Ron

    Joined:
    Dec 7, 2012
    Location:
    United Kingdom
    #7
    Thanks to all the replies, this is a good starting point.
     
  8. eyoungren macrumors P6

    eyoungren

    Joined:
    Aug 31, 2011
    Location:
    Phoenix • 85037
    #8
    Others have provided links so I will just state the following here. OS X is based on UNIX. Apple just provides a slick, proprietary GUI that sits on top of UNIX (with some of it's own modifications).

    UNIX has been around since the early 1970s.

    Think of it in the same way as Windows 95/98/2000 sat on top of MS-DOS.

    Terminal commands are simply UNIX commands. If we stripped out the OS X GUI, Terminal would be how you would interact with the computer.
     
  9. MacUser2525 macrumors 68000

    MacUser2525

    Joined:
    Mar 17, 2007
    Location:
    Canada
    #9
    I always have a Terminal open and the command + tab keys at the same time brings up the application switcher so you can quickly use another command still held down then tab to move to the desired application. If mouse is in my hand then the thumb button I have mapped to it brings it up for a quick switch to a running app. To the OP a quick Google search on what you want to do plus command line OSX on the end will usually bring up more than a few hits on how to get done what you need.
     
  10. Big Ron thread starter macrumors 6502

    Big Ron

    Joined:
    Dec 7, 2012
    Location:
    United Kingdom
    #10
    Thanks to all - Although not a 'Mac newbee' I have deliberately stayed away from Terminal commands because I'm not 100% sure. As lowendlinux suggested: I will start small.
     
  11. MacUser2525 macrumors 68000

    MacUser2525

    Joined:
    Mar 17, 2007
    Location:
    Canada
    #11
    Definitely start small and if you are going to be playing around with files do your commands on copied to another location ones. This way if you mess it up at least you still have the originals to fall back on.
     
  12. LOLobo macrumors member

    Joined:
    Nov 20, 2014
    #12
    I use Windows at work and OS X at home.
    On both I have a Terminal window up always (Command Prompt & Terminal, respectively).

    It's a matter of deciding you're going to do something with Terminal instead.
    Daily, I mostly commonly use lftp for file transfers, wget for downloading from web sites, screen to shove things in the background, rtorrent for bittorrent, cd, mv, cp, mkdir: all for file/directory managment, ln to create symbolic links, ffmpeg for video encoding, as well as a bunch of alias' that allow me to unrar files and connect (ssh) to other Apple device Terminals.

    (Think of approaching keyboard shortcuts the same way, which are so much more productive than the mouse)
     
  13. jerwin macrumors 65816

    Joined:
    Jun 13, 2015
    #13
  14. Weaselboy Moderator

    Weaselboy

    Staff Member

    Joined:
    Jan 23, 2005
    Location:
    California
    #14
    Here are the official "man" pages for each command available. If you click each command it will explain what it does and the options available for each, along with examples.

    Much of what I have learned has been on forums like this. Some was self taught from just wondering if a certain task could be performed, then doing the research to answer my own question.
     
  15. ocabj macrumors 6502a

    ocabj

    Joined:
    Jul 2, 2009
    #15
    The O'Reilly Unix for OS X book is decent since it covers a lot of Mac OS X specific CLI commands.

    But OS X shell is a lot easier to understand if you have a foundation in *nix to begin with.

    I recommend the following two O'Reilly books:

    Essential System Administration by AEleen Frisch
    Learning the bash Shell by Cameron Newham
     
  16. old-wiz macrumors G3

    Joined:
    Mar 26, 2008
    Location:
    West Suburban Boston Ma
    #16
    And be absolutely sure you have a backup of your disk BEFORE you try playing around with terminal commands. It is very very easy to get a parameter wrong and wind up with a disk that will not boot, especially if you try changing permissions. When I was working with *NIX, I remember newbies just out of college with CS degrees who would come in and say "I know a better way to do this" and proceed to wreck things. Since I had backups, I let them go ahead and learn the hard way.
     
  17. Big Ron thread starter macrumors 6502

    Big Ron

    Joined:
    Dec 7, 2012
    Location:
    United Kingdom
    #17
    Wise words from everyone, thanks again
     

Share This Page