guillermotti / dotfiles

Guillermotti's dotfiles and macOS customizations

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Guillermotti's macOS Setup

Before formatting

  • Upload to drive existing files
  • Sync VSCode settings
  • Update important files to a new private gist (.npmrc, .yarnrc, .aws/config, .zsh_history, .kube/config)

Package manager

  • Install Homebrew:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
  • Run which brew to confirm the one in home directory is picked up.
  • Run brew analytics off.

GitHub SSH key

  • Generate key with a password:
ssh-keygen -f $HOME/.ssh/github_rsa
  • Add key to the keychain:
ssh-add $HOME/.ssh/github_rsa # company-installed
/usr/bin/ssh-add $HOME/.ssh/github_rsa # system
cat ~/.ssh/github_rsa.pub| pbcopy
  • Test connection:
ssh -T git@github.com -i ~/.ssh/github_rsa
  • Clone this repo:
git clone git@github.com:guillermotti/dotfiles.git

OS Settings

  • Run mac_setup.sh script.
  • Modify git config --global user.signingkey value with the public SSH key and run git_setup.sh script.
  • Restart the laptop to apply changes.

Set symlink to dotfiles

  • Run symlinks.sh script.

Installing software via Homebrew

All software installed on the system must be listed in .Brewfile. This is symlinked at ~/.Brewfile and used by brew bundle.

To install all the software, add it to .Brewfile and run:

brew bundle --global

Shell

  • iTerm2->Profiles->Open Profiles->Edit Profiles...->Add iterm.json.
    • Restart iTerm2.
  • Install oh-my-zsh, powerlevel10k theme and plugins:
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" # install oh-my-zsh https://ohmyz.sh/
git clone --depth=1 https://github.com/romkatv/powerlevel10k.git ~/powerlevel10k
echo 'source ~/powerlevel10k/powerlevel10k.zsh-theme' >>~/.zshrc
p10k configure # configure powerlevel10k
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
git clone https://github.com/zsh-users/zsh-autosuggestions.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions

Installing software manually

curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.0/install.sh | bash

Post installation configuration

  • Raycast
    • Import config from *.rayconfig
    • Set directory to script commands
  • VSCode
    • Turn Settings Sync on.

Pass Configuration

  1. Import GPG key from the repository:
gpg --import private.asc
  1. Run the following commands:
pass init guillermotti
pass git init
pass git remote add origin <REPO>
pass git reset --hard origin/main
  1. Use the tool and check everything is working.

Troubleshooting

which pinentry-mac
vim ~/.gnupg/gpg-agent.conf # set the path to pinentry-mac binary at the end of the file
gpgconf --kill gpg-agent

Copy files from Gist

  • .zsh_history
  • .npmrc
  • .yarnrc
  • .aws/config
  • .kube/config

About

Guillermotti's dotfiles and macOS customizations


Languages

Language:Shell 92.3%Language:Swift 4.1%Language:Vim Script 3.6%