- 1 Introduction
- 2 Software
- 3 Trackpad Gestures
- 4 Keyboard Shortcuts
- 5 Command Line
- 6 System Settings
In October 2015, I had the opportunity to experience the Apple Mac OS X platform on a 13″ Macbook Pro Retina as my “daily driver.” I’ve been using the Macbook Pro, instead of my Dell Latitude E6430, on a daily basis, and wanted to share my findings with the world. To offer you some background, I’ve been working in the Microsoft-centric enterprise IT field since 2004. I work heavily with technologies such as Windows Server, PowerShell, Amazon Web Services (AWS), Azure cloud, and System Center.
Under this section, we’ll talk about some of the essential software packages that you should have for your Mac. You might find that some of these tools are useful for you, while other tools may not be applicable to you. Since I work heavily with enterprise cloud and automation, some of these software packages will be specific to software developers.
Disk Inventory X
Is your disk getting full on your Mac? Check out the Disk Inventory X utility, similar to the WinDirStat application for Windows. This utility will help you identify applications and files that are using up a large portion of your disk space, so that you can delete them and free up some storage space for new files. Boxes, shaded with different colors, represent individual files on the filesystem, and will draw your visual attention to them. Larger boxes indicate larger files, while small boxes indicates smaller file sizes.
A company called Zeit has create an alternate terminal interface for Mac OS X named Hyper. Hyper is based on GitHub’s Electron user interface API and is built on web standards. The source code for the Hyper project is available on GitHub.
If you’re working with the Microsoft Windows platform, you’ll frequently need to use Remote Desktop Protocol (RDP) to connect to remote systems. The same thing applies if you are managing Linux systems remotely, where you’ll typically use SSH to connect to them. The software package called Royal TSX provides a plugin-based architecture, whereby you can perform many different types of remote management tasks from a centralized interface.
If you’re a heavy command line user, iTerm2 is an essential package. While Mac OS X has a built-in terminal application, it leaves a lot to be desired.
Another great feature of the Atom Editor, if nothing else, is that it has built-in Markdown rendering. If you’re looking for a simple, free tool to view and edit your Markdown, Atom might be just the tool you need!
Microsoft Remote Desktop Client
The Microsoft Remote Desktop Client for Mac enables you to access your Windows systems remotely. For those who are unfamiliar with RDP (Remote Desktop Protocol), it essentially allows you to remotely connect to your Windows computer and treat it as if it were running locally. If you’re using a Mac, and need access to a Windows-specific application, such as PowerShell, this quickly becomes extremely useful.
You can connect to Windows virtual machines that are running in the Microsoft Azure public cloud, which allows you to rapidly spin up, or spin down, Windows-based virtual machines on-demand. You only pay for what you use, and as long as you shutdown (deallocate) your VMs when you’re not using them, you’ll keep your monthly bill pretty small!
Although Apple includes their own document editor, spreadsheet program, and presentation software, if you’re already familiar with Microsoft Office, then you’ll probably want to keep using it. The Mac version of Microsoft Office has some shortcomings, that the Windows version doesn’t have, but for the most part, it is going to get done about 90% of what you’re looking for.
As a heavy user of Microsoft PowerPoint, one of the things that I noticed was missing out of the Mac version is the Selection Pane. On a Windows system, with Microsoft Office, the PowerPoint Selection Pane allowed you to quickly rename objects on your slides, and toggle their visibility. For me, this was a great workflow enhancement, but I’ve been able to get by without it. I’m hopeful that Microsoft will add this back in a future version.
There isn’t a lot to say here, for users who are already familiar with Google Chrome. However, if you haven’t heard about Google Chrome yet, it is pretty much the best web browser in existence. Tight integration with your Google accounts, high performance, and. This browser is well-known for using a lot of memory, but that’s actually a good thing. Barring any major software bugs / memory leaks, the more memory a program uses is a reasonably good indication that it will be able to more quickly respond to user input.
On Mac OS X, there are a variety of virtualization solutions that can help you run Linux or Windows on a localized Virtual Machine. Although you can easily deploy virtual machines in cloud platforms, such as Microsoft Azure or Amazon Web Services (AWS), in situations where you aren’t connected to the Internet, you might need to run a Virtual Machine locally on your Mac. That’s where Oracle’s VirtualBox solution comes into play. VirtualBox is a free and open source (FOSS) software package that enables you to create virtual machines in a matter of seconds.
I was able to successfully use VirtualBox to install a Windows 10 Enterprise Build 1152 using the ISO file from MSDN. I plan on using this VM for software testing, particularly with PowerShell.
Visual Studio Code
Although I’ve mentioned the Atom Editor, another project you’ll want to keep an eye on is Visual Studio Code. Although Microsoft’s premier software development tool, the full version of Visual Studio, only runs on the Windows platform, Microsoft is making a huge investment into cross-platform software. The Visual Studio Code editor provides revision control integration with Git, syntax highlighting, and it even supports debugging through a debug adapter.
Projects in VS Code can be simply opened as folders on the filesystem, so there’s no need to go through the process of creating a project in the same way you’re used to in the full version of Visual Studio.
For those of you who are new to Sonos, you have to buy Sonos proprietary hardware. Essentially, they’re an intelligent, wireless (proprietary, not WiFi) speaker system that enables you to play audio from nearly any source, including Pandora and online radio stations. I’ve owned two of the Sonos Play:5 speakers, and a Sonos Bridge since about 2012, and absolutely love the audio quality, and flexibility that this system offers. One of the things I really love about the Sonos audio system is that it provides perfectly synchronized audio within a group of units, so when you walk from one room to another, there is no difference in what’s playing.
There’s a Sonos “controller” application that you can install on any platform (Android, iOS, Mac OS X, Windows), that allows you to group units together, and play different audio sources on different groups of speakers. The Sonos application for Mac OS X looks really great, and is a consistent look and feel with the Windows and Android versions of the app. If you’re an owner of Sonos devices, then I’d strongly encourage you to check out the Mac OS X version of the app.
One of the great things about the Mac OS X platform is the ability to use gestures on the built-in trackpad, or if you’re on a desktop, the external Magic Trackpad 2.
Three Fingers Swipe Up
If you swipe up with three fingers, on the trackpad, you can easily access Mission Control, which gives you an overview of all the windows that are currently open on your computer.
Three Finger + Thumb Swipe Out
If you take three or four fingers, and place them onto the trackpad, and then swipe your thumb towards them, or away from them, you can reveal the desktop or open Launchpad.
Invoke Mac OS X Spotlight
The most commonly used keyboard shortcut in my Mac OS X experience is the COMMAND + SPACE shortcut. This shortcut launches Spotlight, which helps you find pretty much anything on your Mac, including applications, files, folders, websites, preferences, and so on. I use this shortcut primarily to: launch applications, switch between running applications, and find files. There are some useful filters, such as the “kind” filter, which allows you to search for a specific type of item in Spotlight.
If you’re diligent about tagging your files, you can use the tag:<tagname> filter to find relevant files! Using this technique can really help you filter down to exactly what you’re looking for.
Spotlight’s other supported “kinds” are:
Menu Option Search
One of the most useful keyboard shortcuts I have come across in Mac OS X is the COMMAND + ? shortcut. You really have to press COMMAND + SHIFT + ? in order to invoke it, since the forward slash key requires the SHIFT key to activate the question mark. What this shortcut does is awesome though. It immediately jumps you to the Help menu in the current application. You can simply start typing a menu option in any of the menus, and when you use the arrow keys to navigate to the one you want, it shows you: 1) where in the menu the option is, 2) the keyboard shortcut for the menu option (if applicable), and 3) an arrow that points to the menu option. How freaking awesome is that?
Check out the following example of how this shortcut works. In the screenshot below, I’m currently using Google Chrome. I want to know how to open the Google Chrome Bookmark Manager using a keyboard shortcut. So I resort to my trusty COMMAND + ? shortcut, start typing a few letters of the menu option I’m looking for, use the down arrow key a few times, to find the correct one, and voila! Mac OS X points me to the menu option that I want.
The key thing to remember about this keyboard shortcut is the element of discoverability. I know what I want, but I don’t know where it is. This shortcut avoids the need to “hunt and peck” through the menus until you find what you want. It doesn’t matter how obscure the menu option is, or how deep it is buried in the menu system. All you need to remember is a few, key letters of the option that you’re looking for!
If you want to truly harness the power of your system, regardless of whether it’s Windows, Mac, or Linux, you will need to learn the command line. On the Windows platform, PowerShell is the go-to automation language, but on Mac, the Bourne Again SHell (Bash) is the default shell. Unlike PowerShell’s integration with .NET and ability to expose modules, Bash relies on external utilities to gain its power.
Command Line Utilities
The Homebrew project is a Mac OS X command line tool that enables you to easily install command line utilities. It is an essential tool to enable rapid installation of other common tools. Each application package is called a formula which is essentially a wrapper around a Ruby script that automates the installation of the package. There are a few thousand packages available in the repository currently. If you want to browse the repository via a graphical interface, you can visit the website Braumeister.org.
To search for packages, simply type brew search <searchterm>.
Although the ScreenResolution project doesn’t have a fancy name, it is certainly self-descriptive. This utility enables you to manipulate your Mac’s screen configuration from the command line. Best of all, this project is easily available via Homebrew. Once you’ve got Homebrew installed, simply type brew install screenresolution to grab it!
This utility has three, simple commands: get, list, and set.
Bash > screenresolution get 2015-11-17 15:33:18.944 screenresolution[59547:6981524] starting screenresolution argv=screenresolution get 2015-11-17 15:33:18.947 screenresolution[59547:6981524] Display 0: 1680x1050x32@0 Bash > screenresolution list 2015-11-17 15:35:26.428 screenresolution[59548:6982614] starting screenresolution argv=screenresolution list Available Modes on Display 0 2560x1600x32@0 1280x800x32@0 2048x1280x32@0 1650x1050x32@0 1440x900x32@0 1152x720x32@0 840x524x32@0 1024x768x32@0 800x600x32@0 640x480x32@0 Bash > screenresolution set 2560x1600x32@0 2015-11-17 15:38:24.391 screenresolution[59561:6985101] starting screenresolution argv=screenresolution set 2560x1600x32@0 2015-11-17 15:38:24.394 screenresolution[59561:6985101] set mode on display 0 to 2560x1600x32@0
If you need to automate switching between screen resolutions, this tool might just help you out!
Autojump keeps a history of your most commonly used directory paths, and allows you to rapidly jump between them, without having to type the full path to them. That last bit is absolutely golden. Making human-computer interaction simple and friction-free is essential to enabling productivity.
As long as you can remember a small, unique part of a directory path that you want to navigate to, Autojump will find it for you, and navigate to it in your terminal session. Another great feature of Autojump is that you can open a Mac OS X Finder window, with the specified path open, instead of jumping to the path in your terminal. To do this, use the jo <partialpath> shortcut.
If you’re accustomed to working with JSON data, you might want to take a look at Underscore.
Yes, although it has a generic name, defaults is actually a Mac OS X command line utility. This utility allows you to read and change settings within Mac OS X that are sometimes hidden from obvious end user view, which is especially very helpful for configuration automation.
Inside the defaults system, there are domains. Each domain corresponds to an application, more or less, and contains a series of keys and their corresponding values. The key-value pairs are read and updated by Mac OS X applications, as you use them. That’s pretty much all there is to it, from an architectural perspective.
That’s all great, but how do you know what domains and keys to use? You can use the defaults domains command, to enumerate a list of all the supported domains on your system. This list could change as you install and remove applications from your Mac. If you want to parse the output and get one domain / application per line, then you can use this command:
IFS=', '; for domain in `defaults domains`; do echo $domain; done
Once you’ve found a domain that you want to read or write a setting (key) to, you can use the defaults read <domain> command to read the entire list of settings. For example, run this command to view the stored settings for the build-in PhotoBooth application.
defaults read com.apple.PhotoBooth
Although the output might look a bit cryptic, try to ignore the syntactical details, and focus on the key-value pairs. There is a setting called NSNavLastRootDirectory, which stores the last location that the filesystem browser was in. Now, open up Photo Booth, take a photo, then export it to a different directory, and then re-run the above command. You’ll notice that the value of the NSNavLastRootDirectory has changed. Armed with this knowledge, we now understand that we can change the default directory that the PhotoBooth application points to, when you export a file. Although this may not seem very useful initially, just think about all the different settings in your other programs that you might want to update, using this simple defaults command.
Sometimes your computer will have more than one program installed on it, that can interpret a particular type of file. For example, an image file (JPEG, PNG, etc.) might open with both Photos and Photoscape. If you want to change the default program that a file opens with, you can follow these steps:
- Locate the file in Finder.
- Select the file by clicking on it.
- Press COMMAND + I to invoke Get Info.
- Find and expand the Open With section.
- Select a different app from the drop-down combo box.
- Click the Change All button.
Security – Firewall
In today’s day and age, information security is critical to keeping your personal information safe and away from malicious attackers. There have been many notable hacks on large companies, reported in the news, who have dedicated security teams. Individuals are no exception to the rule. If you haven’t properly secured your systems, then you are at risk for data leakage, which could be catastrophic on your finances, your relationships, and much more.
Mac OS X has a built-in software firewall that, for me, was disabled out of the box. You can easily enable the software firewall using these steps:
- Open Spotlight by pressing COMMAND + SPACEBAR.
- Type “security” and launch the Security & Privacy application.
- Click on the Firewall tab.
- Click the Lock icon on the lower-left, and type your password.
- Click the Turn On Firewall button.
Once you’ve switched on the Mac OS X Firewall, you can click the Firewall Options button and enable connectivity for each application that’s installed on your system. Check out the screenshot below for details. If you want to disable other people from “pinging” your system, you can check the box called Enable Stealth Mode.
Security – Disk Encryption
Mac OS X supports native disk encryption, so you don’t need to necessarily purchase a third-party solution for this! Essentially what this means is that, if someone steals your Macbook Pro, they won’t be able to detach the internal disk, connect it to their system, and read the data off of it.