I got Macbook Air M1 this month. So I set it up for personal project development. This is my current setup.

Clean Slate

Because I like to start from clean, so I remove the previous installation:

  • Prepare Monterey USB Bootable with InstallAssistant.pkg and follow this instruction.
  • Erase Volume Group because the new macOS created System Volume and Data Volume separately.
  • Need to connect to the internet to activate the device.
  • Install the macOS and follow the instruction on the screen.
  • Log in to iCloud account.
  • Disable “Ask Siri”.

First Thing After Install

Change default macOS setting:

  • Finder

    • General:
      • Uncheck all checkbox
      • New Finder windows show: “Home” directory
    • Sidebar:
      • Show Home Icon
      • Uncheck Tags
    • Advanced:
      • Show all filename extensions
      • Show warning before changing an extension
      • Show warning before removing from iCloud Drive
      • Show warning before emptying the Trash
      • Remove items from the Trash after 30 days
      • Keep folders on top:
        • In windows when sorting by name
        • On Desktop
      • When performing a search: Search the Current Folder
  • System Preferences

    • Trackpad
      • Trackpad natural off
      • Trackpad tap to click
      • Look up & data detectors off
    • Accessibility
      • Pointer Control -> Enable dragging: three finger drag
    • Keyboard
      • Remap “caps lock” to “esc”
      • Use F1-12 keys as standard function keys
      • Turn Keyboard backlight off after 10 secs
      • Turn off spotlight shortcut, replace it with Raycast
      • Enable key repeat for all app defaults write -g ApplePressAndHoldEnabled -bool false
      • Key Repeat: fast
      • Delay until repeat: short
    • General
      • Appearance: Dark
      • Show scroll bars: Always
      • Default web browser: Google Chrome
    • Dock
      • Remove all Icon exept Finder, Calendar, App Store, System Preferences, Downloads, and Trash
  • Install Chrome, set it as default, and log in to the main account so all my extensions are synced.

  • Setup SSH Keys

    • Signin to github and add new ssh key.

Preparation

  • Do this before anything else
    xcode-select install
    
    • Make coffee or tea, it took a while if your internet connection is slow
  • Install Brew
  • Update Git
    brew install git
    

Start with CLI

  • Install common cli apps
    brew install htop tree tmux git-extras git-delta bat ripgrep aria2
    
  • Install hugo extended for building this blog.
    • Somehow it showing error:

      hugo can’t be opened because Apple cannot check for malicious software

    • The solution:
      xattr -d com.apple.quarantine <path-to-hugo>
      
  • Install zsh dependencies:
    brew install fzf fasd zsh-autosuggestions
    
  • Setup dotfiles with chezmoi from my repo. It is private for now I’ll make it public later.
  • Install Oh My ZSH
  • Install kitty because it easier to setup the color theme. 😄
    brew install --cask kitty
    

Setup Code Editor

  • Editor Fonts

    brew tap homebrew/cask-fonts # You only need to do this once!
    brew install font-iosevka font-fira-code font-hack-nerd-font
    
  • Install Neovim, because it has lua 😄

    brew install lua-language-server # for sumneko_lua
    brew install neovim
    
  • Visual Studio Code

    • Login to Github for syncing extensions
    • Setup Dendron, pull the vault from github.
  • Setup Obsidian and sync the vault.

    brew install --cask obsidian
    

Install Supporting Application

brew install --cask raycast # I was using alfred before it nice alternative and set cmd+space as shortcut
brew install --cask spotify # Listen music
brew install --cask mongodb-compass # Sometimes it is useful
brew install --cask toggl-track # Track worktime
brew install --cask postman # HTTP client, a lot of another alternative, but it is easier for syncing multiple devices
brew install --cask sublime-merge # GUI for git diff and commit history
brew install --cask brave-browser # Alternative to Chrome
brew install --cask firefox # Another alternative to Chrome
brew install --cask libreoffice # For editing big CSV files
brew install --cask private-internet-access # VPN for security when connecting to public wifi
brew install --cask dropbox # I have a lot of space because of referral :D
brew install --cask telegram # Telegram for macOS
brew install --cask whatsapp # Another chat app
brew install --cask zoom # Another meeting tools :D

Setup Setapp

I have a subscription to SetApp (referral link), these are some useful apps I commonly use:

Development Tools

NodeJS

  • Install fnm, they say it faster than nvm
  • Install global package
    npm i -g commitizen cz-conventional-changelog nodemon typescript ts-node serve
    

Go

Flutter


This article was inspired by swyx - My 2022 New Mac Setup