-->
macossetup
Various applications and settings I use on MacOS for development, as a web developer.
October 29, 2020
This article is a living document, meaning that when I use something new or need to add something, I will update this article as well.
Last updated: December 24, 2023
When this article was first written, I didn’t know how to quickly set up the applications, configurations, and tools I often use on my MacBook for development. Several times I struggled when I had to use a fresh MacBook according to my needs. Whether it’s provided by the office, after being reset, or a new MacBook.
I even once needed a whole day to configure everything I needed, so I couldn’t be productive right away. Every time I felt everything was complete, when working, it turned out there was something missing, and eventually, my work was disrupted because I had to continue setting up again to work comfortably.
I created this article as a note to make it easier when I have to set up again later. Since I am a Web Developer, most of the applications and configurations I do here will be around JavaScript / NodeJS. So, if you have the same profession as me, I hope this article can be your note too.
Install Homebrew as a package manager on Mac. The installation method for Homebrew is quite clear on its website.
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
The applications I use are divided into two types: automatic installation via Homebrew and manual installation.
After Homebrew is installed, I can continue to install all the applications I need via Homebrew automatically:
brew install --cask docker google-chrome iterm2 imageoptim kap notion openvpn-connect postman raycast slack spotify sequel-pro visual-studio-code whatsapp
The command above will install the applications I need, namely:
Program | Function |
---|---|
Docker | Environment Tool |
Google Chrome | Web Browser |
iTerm2 | Terminal Alternative |
ImageOptim | Image Compressor |
Kap | Screen Recorder |
Notion | Note-taking Application |
OpenVPN Connect Client | For Using VPN |
Postman | API Tool |
Raycast | Launcher |
Slack | Communication |
Spotify | Music |
Sequel Pro | Database UI |
Visual Studio Code | Code Editor |
Whatsapp Desktop |
Because not all applications are available in Homebrew Cask by default, they have to be installed manually.
Program | Function |
---|---|
Codewhisperer | Terminal auto-completion |
Focus To-Do | Pomodoro & Todo App |
LogiOptions+ | Logitech Mouse App |
ObinsKit | Anne Pro 2 Keyboard App |
XAMPP 7.3.33.0 | PHP 7.3 + MySQL Runner |
I use Zsh as the main shell. Fortunately, MacOS Sonoma already includes Zsh as the default shell. So, just install Oh My Zsh to get all the plugins I need right away.
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
The plugins I often use in ZSH are as follows:
Plugins that are automatically available when installing Ohmyzsh so just activate them
Plugin | Function |
---|---|
Alias Finder | To find aliases in Shell |
Autojump | Jump directories in Shell quickly |
Copydir | Copy the active directory path to clipboard |
Git | Git command shortcuts |
Yarn | Yarn command shortcuts |
ZSH Interactive CD | Easier directory navigation |
ZSH Reload | Quick way to reload ZSH configuration |
Ohmyzsh plugins that must be downloaded manually:
Plugin | Function |
---|---|
ZSH Autosuggestions | Autocomplete based on history |
ZSH Vim Mode | Vim-like Shell |
After ensuring the Built-in and External Plugins above are installed, we just need to activate the plugins in the ~/.zshrc file:
...
alias af="alias-finder -l"
plugins=( git yarn alias-finder autojump npm zsh_reload copydir zsh-interactive-cd zsh-autosuggestions zsh-vim-mode)
...
Don’t forget to reload the ~/.zshrc configuration file:
source ~/.zshrc
I have discussed the plugins above in the article More Productive Coding with Terminal Plugins
I choose to install Node.js via Node Version Manager (NVM) so I can easily switch versions, as I often need to switch to older or newer Node versions. Besides that, for the package manager, I still prefer using Yarn over NPM because it’s faster.
Install NVM
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.36.0/install.sh | bash
Install Latest Node
nvm install node
Switch Node Version
nvm install xx.xx && nvm use xx.xx
Then set the newly installed one as the default
nvm alias default xx.xx
brew install yarn
Installation and Configuration of Git
Install Git via Homebrew:
brew install git
After Git is installed, make sure to set up the profile in the global configuration
git config --global user.name "Full Name" && git config --global user.email "emailaddress@mail.com"
I also like to use Delta for syntax highlighting in Git to make it more comfortable when doing git diff
or git show
.
Install Delta:
brew install git-delta
Then edit the ~/.gitconfig file. Usually, I configure it like this.
[core] pager = delta
[interactive] diffFilter = delta --color-only
[delta] navigate = true
[merge] conflictstyle = diff3
[diff] colorMoved = default
Click here to see what configurations are available.
This section I use MacOS Sonoma and depends on personal preference…
Even though the language I use on the Mac is English, I have to make sure the following settings are off so that every time I write an Indonesian word, the Mac doesn’t try to change it to a word it thinks is correct.
In the “Input Sources” section, click “Edit” then set the following options:
Other settings
Cmd
+ Shift
+ 5
. Then click “Options” > “Other Location”Esc
to exit the screenshot settingFigure 1: Quick access to screenshots
Comments