Skip to content

gianpaj/mac-setup-script

 
 

Repository files navigation

Gian's current macOS setup

as of Sept 2021, Big Sur

Initial setup

Dead simple script to setup my new Mac:

cd ~/Downloads
curl -sL https://raw.githubusercontent.com/gianpaj/mac-setup-script/master/defaults.sh | bash
curl -O https://raw.githubusercontent.com/gianpaj/mac-setup-script/master/install.sh
chmod +x install.sh
./install.sh
./install.sh >> install_log.txt

Taken from https://github.com/pathikrit/mac-setup-script

  1. Install brew

  2. Clone repo

    git clone git@github.com:gianpaj/mac-setup-script.git
  3. Set macOS settings

    cd mac-setup-script
    bash defaults.sh
  4. Install apps

    bash install.sh
  5. Reboot

Applications

Hardware

  • Karabiner Elements

    • to fix the back tick character ` when pressing §
    • non_us_backslash to grave_accent_and_tilde
  • Alfred workflows

    • SwitchAudioSource (to switch between audio devices)

      Alfred Switch AudioSource wo

    • Switch Appearance – Change between Light and Dark Mode

      Alfred-Switch Appearance Workflow

Work desktop apps

  • Linear - Ruler app with web-development in mind

    My bug fix

    git clone git@github.com:gianpaj/linear.git
    git checkout -b upgrade-electron-package origin/upgrade-electron-package
    npm install
    npm run package

    Disable Gatekeeper:

    sudo spctl --master-disable

Productivity apps

  • NightOwl - Toggle the Dark mode via the Menu Bar
  • Horo (timer/pomorodo menu app)

Software development apps

  • VSCode

  • Android Studio

    • Android SDK path
  • Xcode

    • Command-line tools
  • asdf (Manage multiple runtime versions - Node.js, Python, etc.)

  • iTerm2

    • Zsh (Guide)

    • oh-my-zsh

      sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
      • zsh-syntax-highlighting

        git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
      • zsh-autosuggestions

        git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
      • zsh-completions

        git clone https://github.com/zsh-users/zsh-completions ${ZSH_CUSTOM:=~/.oh-my-zsh/custom}/plugins/zsh-completions
      • pure - Pretty, minimal and fast ZSH prompt

        (already installed in install.sh)

      • Update .zshrc

    • Load .zshrc from Dropbox

      cd ~
      ln -s ~/Dropbox/Mac/.zshrc .zshrc
      
      # results in
      $ l .zshrc
      lrwxr-xr-x - gianpaj 30 Aug  2022 .zshrc -> /Users/gianpaj/Dropbox/Mac/.zshrc
    • Load .aliases from Git repo

      cd ~
      ln -s ~/github/gianpaj/mac-setup-script/bash/.aliases .aliases
      
      # results in
      $ l .aliases
      lrwxr-xr-x - gianpaj 29 Nov 12:11 -M .aliases -> /Users/gianpaj/github/gianpaj/mac-setup-script/bash/.aliases
  • asdf

    asdf plugin-add python
    asdf install python latest
  • zed config

    ln -s ~/github/gianpaj/mac-setup-script/apps/zed/settings.json ~/.config/zed/settings.json
    ln -s ~/github/gianpaj/mac-setup-script/apps/zed/keymap.json ~/.config/zed/keymap.json
    ln -s ~/github/gianpaj/mac-setup-script/apps/zed/snippets.json ~/.config/zed/snippets.json

Clean merged branches

git branch --merged | egrep -v "(^\*|master|dev)" | xargs git branch -d

Ubuntu linux useful commands

Upgrade all security packages

sudo apt-get -s dist-upgrade | grep "^Inst" | grep -i securi | awk -F " " {'print $2'}
sudo apt-get -s dist-upgrade | grep "^Inst" | grep -i securi | awk -F " " {'print $2'} | xargs sudo apt-get install -y

VSCode extensions

General apps

Firefox Settings

about:config

Firefox Extensions

Chrome Extensions

Web development

uBlock filters

ublock-filters

Desktop apps

  • Giphy Capture

  • or kap

    brew install kap --cask

Resources

About

script to set up my mac

Topics

Resources

Stars

Watchers

Forks

Languages

  • Shell 99.5%
  • Ruby 0.5%