I completely reformatted the hard drives of a couple of Mac laptops a few months ago and did all the installation to make either one useful as my day-to-day machine. There are enough steps (and enough things that I forgot and then later had to interrupt my work to do) that I made a handy reference list for the next time I need to set up a new machine from scratch.

Obviously “useful as a day-to-day machine” is very specific to my needs: my main work involves writing papers and presentations with LaTeX, giving presentations and reading papers with Skim, programming in Java, C++, Python, and Haskell, and of course heavy email and web use.

Here is how I set up a new machine:

  1. Install Mac OS X from DVD.
  2. Create an administrator account and log into it:
    1. Turn off Safari’s “Open safe files after downloading” setting (in the General pane of Safari’s preferences).
    2. Install SSHKeychain
    3. Set time zone in the “Date & Time” preference panel.
    4. Set date format to YYYY-MM-DD in the “International” preference panel.
    5. Install developer tools.
    6. Run Software Update and install all updates.
    7. Change computer name in the “Sharing” preference panel.
    8. Create (non-administrator) user account.
  3. Reboot to finish all updates, and log in under normal user account.
  4. Set date and time formats in the “International” preference panel.
  5. Set Energy Saver, Desktop, and Screen Saver preferences.
  6. Set Dock preferences to automatically hide the dock.
  7. Turn off auto-play of CDs and DVDs in the “CDs & DVDs” preference panel.
  8. Connect to external monitor and adjust settings in “Displays” preference panel.
  9. Pair bluetooth keyboard/mouse, adjust key repeat rate and delay, and set mouse button preferences and speed in “Keyboard & Mouse” preference panel.
  10. Set up printer.
  11. Turn off menubar volume control in “Sound” preference panel.
  12. Remove unwanted cruft from Dock.
  13. Create “Media” directory under /Users/Shared.
  14. Copy films/music to shared media directory. (This can take a long time.)
    • Point iTunes at this shared media directory when all the copying is finished
  15. Change Safari preferences:
    1. Turn off the “Open safe files after downloading” setting.
    2. Start at a blank page
    3. No bookmark bar
    4. Show status bar
  16. Install TeX tools:
    1. Install TeX using installer.
    2. Install Skim.
      • Set Skim to check for file changes.
  17. Install TextMate
    1. Set license code.
    2. Change filter list.
    3. Set wrap column to 78.
    4. Don’t re-indent.
    5. Set latex bundle to use Skim and LatexMk.pl.
  18. Set Finder to open all text files with TextMate and all PDF files with Skim.
  19. Set up Mail:
    1. Create IMAP accounts.
    2. Delete Apple RSS feed.
    3. Map “Sent” mailboxes.
    4. Show X-Envelope-To header.
    5. Don’t display remote images.
    6. Don’t use smart addresses.
    7. Make default message format plain text.
    8. Display plain text mails in fixed-width font.
    9. Remove the Apple rule from the ruleset.
    10. Install self-signed certificates if your mail servers use them.
    11. Install SpamSieve.
      • Stop Spamsieve from appearing in the doc by setting LSUIElement to 0 in SpamSieve/Contents/Info.plist.
    12. Install Mail Act-On.
      • Set up act-on rules. (I use a different “archive” rule for each account, all assigned to the same key.)
  20. Set up shell:
    1. Generate SSH keypair with ssh-keygen.
    2. Upload new public key to commonly-used servers.
    3. Create local bin and man directories, and any other directories for local tools.
    4. Add the following to .profile:

       export PATH=$HOME/bin:$HOME/local/bin:$PATH
       export MANPATH=$HOME/man:$HOME/local/man:$MANPATH
       export EDITOR='mate -w'
      
    5. Add the following to .bashrc:

       set -o noclobber
       shopt -s histappend
       shopt -s histverify
       shopt -s nocaseglob
       shopt -s no_empty_cmd_completion
       shopt -s nocaseglob
       shopt -s nocasematch
       shopt -s nullglob
       set -o ignoreeof
       FIGNORE=.svn:.DS_Store
       HISTSIZE=10000
       HISTCONTROL=ignoreboth
      
    6. Add the following to .inputrc:

       set show-all-if-ambiguous on
       set visible-stats on
       set completion-ignore-case
       set bell-style none
       "\e[B": history-search-forward
       "\e[A": history-search-backward
       $if Bash
         "\e[21~": "mc\C-M"
         Space: magic-space
       $endif
      
    7. Install new version of rsync (if that tool will be used).
  21. Install VPNClient
  22. Install Git and the git TextMate bundle.
  23. Install workaround for FileVault Launch Services bug if necessary.
  24. Install iStat.
  25. Make the Help Viewer less obnoxious with the following command:

    defaults write com.apple.helpviewer NormalWindow -bool true
    i=/System/Library/CoreServices/Help\ Viewer.app/Contents/Info.plist
    sudo defaults write "${i%.plist}" LSUIElement 0
    sudo chmod 644 "$i"
    
  26. Make the Dock less ugly with the following command:

    defaults write com.apple.dock no-glass -boolean YES
    
  27. Install ColorXML for Quick Look previews of XML files.
  28. Export UTI definitions for less common file types; I usually put this stuff into TextMate’s Info.plist:

    <key>UTExportedTypeDeclarations</key>
      <array>
        <dict>
          <key>UTTypeIdentifier</key>
          <string>org.tug.tex</string>
          <key>UTTypeDescription</key>
          <string>TeX (or LaTeX) source code</string>
          <key>UTTypeConformsTo</key>
          <array>
            <string>public.text</string>
            <string>public.plain-text</string>
          </array>
          <key>UTTypeTagSpecification</key>
          <dict>
            <key>com.apple.ostype</key>
            <string>TEXT</string>
            <key>public.filename-extension</key>
            <array>
              <string>tex</string>
              <string>latex</string>
              <string>ltx</string>
              <string>texi</string>
              <string>ctx</string>
            </array>
          </dict>
        </dict>
        <dict>
          <key>UTTypeIdentifier</key>
          <string>org.obofoundry.obo</string>
          <key>UTTypeDescription</key>
          <string>Open Biologicial Ontologies format</string>
          <key>UTTypeConformsTo</key>
          <array>
            <string>public.text</string>
          </array>
          <key>UTTypeTagSpecification</key>
          <dict>
            <key>com.apple.ostype</key>
            <string>TEXT</string>
            <key>public.filename-extension</key>
            <array>
              <string>obo</string>
            </array>
          </dict>
        </dict>
        <dict>
          <key>UTTypeIdentifier</key>
          <string>org.w3.rdf.xml</string>
          <key>UTTypeDescription</key>
          <string>RDF data in XML serialization</string>
          <key>UTTypeConformsTo</key>
          <array>
            <string>public.xml</string>
          </array>
          <key>UTTypeTagSpecification</key>
          <dict>
            <key>public.mime-type</key>
            <string>application/rdf+xml</string>
            <key>public.filename-extension</key>
            <array>
              <string>rdf</string>
            </array>
          </dict>
        </dict>
        <dict>
          <key>UTTypeIdentifier</key>
          <string>org.w3.owl.rdf</string>
          <key>UTTypeDescription</key>
          <string>OWL ontology in RDF/XML serialization</string>
          <key>UTTypeConformsTo</key>
          <array>
            <string>org.w3.rdf.xml</string>
          </array>
          <key>UTTypeTagSpecification</key>
          <dict>
            <key>public.mime-type</key>
            <string>application/rdf+xml</string>
            <key>public.filename-extension</key>
            <array>
              <string>owl</string>
            </array>
          </dict>
        </dict>
        <dict>
          <key>UTTypeIdentifier</key>
          <string>org.daml.damloil.rdf</string>
          <key>UTTypeDescription</key>
          <string>DAML+OIL ontology in RDF/XML serialization</string>
          <key>UTTypeConformsTo</key>
          <array>
            <string>org.w3.rdf.xml</string>
          </array>
          <key>UTTypeTagSpecification</key>
          <dict>
            <key>public.mime-type</key>
            <string>application/rdf+xml</string>
            <key>public.filename-extension</key>
            <array>
              <string>daml</string>
            </array>
          </dict>
        </dict>
      </array>
    
  29. Install Python 3.0 and the Glasgow Haskell Compiler.
  30. Install Skype.
  31. Install NetNewsWire.
  32. Install Things.
  33. Install Perian.
  34. Install Firefox, Vidalia, and TorButton for private browsing.
  35. Install iLife and iWork if necessary.
  36. Install Graphviz and the AT&T finite state machine library.
  37. Install other applications, such as OmniGraffle, VLC, VisualHub, Transmission, and Handbrake.
  38. Finally, copy across all the old documents into home directory. (For me this is only a few gigs of files, so all this “personal” data can just be archived on a memory stick.)

I’m sure the next time I do a fresh install this list will be revised, but this checklist should make a good starting point.