Tag Archives: utilities

Setting Up a Mac

Fixing mouse scroll direction, key bindings, setting up Exposé spaces, etc.

Installing Keynote, Numbers, and Pages plus any software previously purchased from the App Store.

Installing replacement browsers: Chrome, Firefox, and Brave, along with Xee and iTerm2 and Skim.

Installing MacPorts, then software starting with ImageMagick. Imagemagick because it’s a good test of everything working properly.

$ sudo port install imagemagick +graphviz -x11

Then adding some of my favorite utilities

$ sudo port install antiword bat colordiff exiftool jhead lame sox tree xz

$ sudo port install ffmpeg -x11

$ sudo port install nnn ranger

Then install software development languages: go, rust, and ruby. Follow them with some CLI utilities written in those languages:

$ cargo install broot cw du-dust dutree exa fd hexyl \
just lsd pastel ripgrep sd

$ go get -u github.com/gokcehan/lf

Setting Up Homebrew on my New Old Mac

I set up Homebrew on my iMac. (If you go to their site, the Homebrew project has documentation there, which explains the whole not-use-sudo philosophy and using /usr/local now that Apple makes it hard not to, but I don’t understand it, so it seems like an invitation to having your machine rooted. But I’m a greybeard and I quit understanding internet security back when we used uucp because we didn’t have a real internet. Hopefully someone has thought it through.)

Because I’m too lazy and ignorant (and possibly stupid) to RTFM, I found a set of color-by-number instructions handy, although I didn’t use anything after XCode (a mere 4GB download) and Homebrew.

$ brew doctor
$ brew update
$ brew doctor
$ brew install {lots of good stuff}

At some point I ran into keg-only and Cellar jabber jabber messages, but (see above) I don’t understand any of that. I just take whatever advice brew doctor gives me and move on from there.

Some of the things I always want on a new Mac (or even one that’s 10 years old) include:

$ brew install imagemagick --with-fontconfig
$ brew install colordiff pwgen tree wdiff pstree
$ brew install pngquant
$ brew install jhead antiword poppler
$ brew install sox lame eye-D3
$ brew install gnupg
$ brew install sqlite

MacPorts tip

I started getting messages when I tried to update my MacPorts tools. I can’t say when it started, because I don’t do it very often. (Like maybe once a month. Bad me.) But it would bomb out, telling me

Error: checksum (md5/sha1/rmd160) mismatch for port.

Then it sent me down a wrong path, suggesting it was because my ISP’s DNS was serving ads or something. But it turns out the why isn’t important, because the what to do about it was right there in the FAQ:

$ sudo port selfupdate
$ sudo port clean --dist {portname}
$ sudo port install {portname}

All I had to do was clean out the bad portfile and try again.

Diff Tools

My favorite diff tool is FileMerge, one of Apple’s developer tools, which can be accessed from the command line as opendiff.

But from the command line, my (next most) favorite diff tool is colordiff. It’s called that because it color-codes the output when it’s used interactively, making it IMHO easier to see what’s changed. Actually, colordiff is just a wrapper around the real diff tool.

Another nice tool is dwdiff, which is compares two documents and highlights the different words rather than the different lines. So does wdiff.

(Back to my list of Unixy tools for the Mac.)