Book on Terminal

Discussion in 'Mac Programming' started by Ayrehead, May 14, 2019.

  1. Ayrehead macrumors newbie

    Joined:
    May 14, 2019
    #1
    I want to learn how to use Terminal and its access to iMac features. I want to buy a book that goes into some depth on Terminal but most were written several years ago, say 2012. Would a book that old still be valid and match the way Terminal works nowadays? (I'm not a developer, I'm an advanced user.)
     
  2. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    Location:
    betwixt
    #2
    Which book on Terminal from 2012 were you looking at?
    Please be specific. Post a URL, or the title, author, and date.

    Other than getting tabbed windows some years ago, I don't think Terminal.app has changed much recently.

    The important parts of Terminal windows have nothing to do with the Terminal app itself. The important part is the shell, or command-line interpreter. That's the program that takes what you type in a Terminal window and runs commands.

    The default shell is 'bash', and you could easily use any book on bash with any version of Terminal.app, and learn all about bash and the other commands.
     
  3. Ayrehead, May 14, 2019
    Last edited: May 14, 2019

    Ayrehead thread starter macrumors newbie

    Joined:
    May 14, 2019
    #3
    My question was not about any particular book, I was just asking if Terminal and the related software had evolved significantly since 2012. Including bash and Apple-specific commands such as "defaults" etc.

    Possible books:
    Macintosh Terminal Pocket Guide: Take Command of Your Mac
    by Daniel J. Barrett (Author)
    July 5, 2012

    Learning Unix for OS X: Going Deep With the Terminal and Shell
    by Dave Taylor (Author)
    October 8, 2012
     
  4. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    Location:
    betwixt
    #4
    Terminal.app hasn't changed all that much since 2012. At least not in any way that would be a major impediment for using a book from 2012. See details below.

    Some of the commands have more options or more features, but you can always find out the details of the current command by using the 'man' command to show its man page. For example, the 'ls' command's '-@' option was pretty new in 2012, so it might or might not be covered in the same detail by a book published in that year. The '-@' option is for listing extended-attributes (xattrs). The scope of xattrs has expanded since then, notably they're used to store the tags that you add to files in the Finder.

    Individual commands may have later versions now than they did in 2012, for example, ruby or python. Sometimes the older version, such as the earlier 'python', remains available as 'python' for compatibility reasons, while newer versions are available as number-suffixed commands, such as 'python2.5'. Again, the man page will generally tell you this, or you can simply apply the 'ls' command to the dirs where commands reside, as listed in the PATH variable.

    The 'defaults' command is essentially unchanged, although the list of names used by other apps has definitely changed. Many names that were used then are no longer used, so setting their values has no effect. A website is the best way to stay on top of those:
    https://www.defaults-write.com/


    Learning Unix for OS X: Going Deep With the Terminal and Shell
    by Dave Taylor (Author)

    I looked at its TOC on the OReilly website, and only X11 strikes me as potentially problematic. It was an app residing at /Applications/Utilities/X11.app in the 2011-2012 era, but I think it was removed or made optional in a later Mac OS version, but I don't recall which one.

    There's this, found by googling macos x11 :
    https://support.apple.com/en-us/HT201341


    Macintosh Terminal Pocket Guide: Take Command of Your Mac
    by Daniel J. Barrett (Author)

    Again, the TOC on the OReilly website doesn't list anything I would say is significantly different. I didn't go through every command, though, just the topics listed.
     
  5. Mikael H macrumors 6502a

    Joined:
    Sep 3, 2014
    #5
    The shell you most likely access using the Terminal app is called Bash. That name may give you some better search results. Unfortunately I have no book recommendations.
    My way of learning such things is by trying to solve a specific problem I'm having, say a requirement to bulk rename files; creating an entire directory structure multiple times; bulk replacing content in text files, etc. After solving enough problems, you've built knowledge and experience of a wide array of the tools available to you in the environment.
     
  6. guzhogi macrumors 68030

    guzhogi

    Joined:
    Aug 31, 2003
    Location:
    Wherever my feet take me…
    #6
    You may also want to Google something along the lines of "Mac "command line,"" possibly with something like "learn" or "book." There's plenty of websites available, too.
     
  7. axrst macrumors newbie

    axrst

    Joined:
    Apr 6, 2019
    Location:
    Greece
    #7

Share This Page

6 May 14, 2019