Skip to content

nicolas-cusan/dotfiles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

61 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

.dotfiles

This repo does not really contain my dotfiles (at least for now). It rather helps to setup a new macOS box step by step. These scripts are optimized for my own system use at your own risk. They were last installed on macOS 10.15.5 (Catalina)

Setup sequence

1. Initial steps

  • Initial mac setup via system dialogs
    • Use Filevault
    • Use Locations services
  • After install check for macOS updates & install if any
  • Setup iCloud preferences
  • Setup sharing preferences
    • Change computer name
    • Make sure all file sharing is disabled
  • Setup preferences for Finder, Dock, Destop, Keyboard, Mouse & Trackpad, Spotlight, etc.

2. Install Homebrew

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

3. Setup SSH

Generate ssh-key.

mkdir ~/.ssh
ssh-keygen -t rsa -b 4096 -C "[email protected]"

Add key.

ssh-add -K ~/.ssh/id_rsa

4. Dotfiles setup scripts

Clone dotfiles repo (location matters).

git clone https://github.com/nicolas-cusan/dotfiles.git ~/.dotfiles

Run the setup script

cd ~/.dotfiles
sh install.sh

What the script will do (in execution order):

  • Install homebrew formulae
  • Install cask binaries & powerline fonts
  • Install Xcode and Active Collab Timer via mas
  • Set some macOS System defaults (see .macos)

5. oh my zsh

Install oh my zsh

sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

6. nvm & node.js

Install nvm, the latest lts node version & some global packages

curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash
nvm install --lts
npm install -g npm prettier npm-check-updates

7. Install VSCode extensions

cd ~/.dotfiles
sh .vscode

8. Configuration

Symlink configuration files stored in iCloud Drive in a folder called macOS. Perquisites before running the script:

  • Make sure that iCloud has synced all files in the macOS folder.
  • Make sure that all programs have been opened at least once so that the target locations for the symlinks exist. No checks for existing folders are performed by the script (for now).
cd ~/.dotfiles
sh .configs

The following configuration files & folders files are symlinked (destination location shown):

~/.gitconfig
~/.oh-my-zsh
~/.zshrc
~/.ssh/config
~/Library/Application Support/Code/User/keybindings.json
~/Library/Application Support/Code/User/settings.json
~/Library/Application Support/Code/User/snippets
~/Library/Application Support/Jumpcut/JCEngine.save
~/Library/Application Support/Sublime Text/Packages/User
~/Library/Preferences/net.sf.Jumpcut.plist
~/Library/Preferences/com.apple.symbolichotkeys.plist
~/Library/Preferences/com.googlecode.iterm2.plist
~/Library/Preferences/com.surteesstudios.Bartender.plist
~/Library/Preferences/com.binarynights.ForkLift-3.plist

9. Install Little Snitch

  • Execute .dmg file installed via cask located at /usr/local/Caskroom/little-snitch/ manually.
  • Restart computer (required)
  • Enter license-key.
  • On the old machine, export rules via Little Snitch backup feature and import in the fresh installation.

10. Further manual steps

  • Sing-in to Chrome
  • Sing-in to Firefox
  • Setup Mail Accounts
  • Setup Calendar https://config.infomaniak.com/
  • Setup login items:
    • Thyme
    • nextcloud
    • Dropbox
    • Rectangle
    • Bartender
    • Jumpcut
  • Activate Zooming in System preferences
  • Set Desktop Color
  • Setup nexcloud account
  • Sign in to all Slack teams
  • Setup licenses for all programs that require licenses
  • Add new ssh key to services (GitHub, GitLab)
  • Install Adobe CC Programs (Adobe Creative Cloud.app is installed via cask)
  • Transfer iTunes Music
  • Transfer relevant entries from /etc/hosts/
  • Importing old vagrant box (without existing dbs):
    • On old system export old vagrant box, useing vagrant box list to get the name, provider and ID and vagrant box repackage to package it.
    • Copy vagrant folder (e.g. php72) & fresh box export to new computer
    • install box by using vagrant box add <PATH_TO_BOX> --name <SOME_NAME>
    • cd to vagrant folder and run vagrant up
  • Move old photos
  • Copy & import old local mailboxes
  • Transfer or install digital certificate
  • Add shared ssh keys to session via ssh-add -K

Caveats

Installing VirtualBox via cask

If brew cask install virtualbox produces errors it might be due to the fact that the installer is not signed. If you are lucky a accept dialog is shown in System Preferences > Security & privacy > General. If not you need to add Oracle to the list of trusted developers:

  • Boot into recovery mode: Shut down the system and hold Cmd + R while booting.
  • Enter your password in the recover password screen (you might be able to skip this step if your drive is not encrypted).
  • Open the terminal and enter spctl kext-consent add VR5E2TV963 (allow the ID for Oracle).
  • Restart and try installation again.

Todo

  • Add global .gitignore & symlink to ~
  • Define how to update / sync with other machine / react to changes in the files
  • Check for folder existence in .config script

Links

About

My .dotfiles repo

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages