This directory contains the dotfiles for my system
Ensure you have the following installed on your system
This will install the required gnu-stow brew along with
all formulas and applications
cd mac
brew bundle install -vFirst, check out the dotfiles repo in your $HOME directory using git
git clone [email protected]:ian-vu/dot-files.git ~/dot-files
cd dot-filesthen use GNU stow to create symlinks
stow .Install deps and set up MacOs
cd mac
./setup.shcd debian
./setup.sh
#### Symbolic links
Add icloud to a better location
```bash
ln -s ~/Library/Mobile\ Documents/iCloud\~md\~obsidian/Documents/obsidian ~/obsidian- Clone TPM (Tmux Plugin Manager) into
git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm- Install plugins from tmux
<prefix> + I
<Ctr+Space> + <S-i>
Ruby environment
For the ruby LSP to work, the Mason dependency of solargraph is required.
For this to successfully be install a version of ruby > 2.7 is required.
Using asdf:
asdf plugin add ruby
asdf install ruby 3.3.0
asdf global ruby 3.3.0This plugin requires an API key to be read on setup.
The cli tool age is used to descrypt a file containing the key.
The encrpytion key is required to be found on path ~/.age/secret-key.txt.
Currently the key is stored in 1Password. To set up the age encryption key run the following command.
op read "op://kt76oi5s3tqjg54lvlolplvvaq/Age CLI Identity/password" > ~/.age/secret-key.txtMaple Mono Nerd Font
Download release and install by double clicking the font file.
Add a new row with one of the following lines to the brewfile
brew <formula_name>
tap <tap_name>
cask <cask_name>Then run the following commands
cd mac
brew bundle cleanup -v
brew bundle install --cleanup -vNote: to avoid upgrades use --no-upgrade flag
Age is used to encrypt and decrypt files. Encrypted files are suffixed with .age.
cat <PATH_TO_FILE> | age --encrypt --identity ~/.age/secret-key.txt > <ENCRYPTED_FILE_PATH>or
age --encrypt --identity ~/.age/secret-key.txt <PATH_TO_FILE> <ENCRYPTED_FILE_PATH>age --decrypt --identity ~/.age/secret-key.txt <ENCRYPTED_FILE_PATH>This repository uses a conditional Git configuration setup to automatically switch between personal and work identities based on the directory structure.
- Default (Personal): All repositories default to personal email (
[email protected]) - Work Override: Repositories in
~/dev/work/**automatically use work email ([email protected])
~/dev/
├── work/ # All work repositories go here
│ ├── company-project/ # Current company repositories
│ ├── company-api/
│ └── company-docs/
├── personal/ # Personal repositories
└── [other]/ # Any other repositories (use personal config)
.gitconfig- Main config with personal email as default + conditional include~/.gitconfig-work- Work-specific overrides (email, name, SSH keys, etc.)
When switching companies or setting up on a new work laptop:
- Move work repositories: Place all work repos under
~/dev/work/ - Update work config: Edit
~/.gitconfig-workwith new work email/settings - No changes needed: The main
.gitconfigremains unchanged
[user]
name = Your Name
email = [email protected]
[core]
sshCommand = ssh -i ~/.ssh/work_keyTest the setup in any repository:
# In work repo
cd ~/dev/work/some-project
git config user.email # Should show work email
# In personal repo
cd ~/dev/personal/some-project
git config user.email # Should show personal emailSee this video on how stow works: https://www.youtube.com/watch?v=y6XCebnB9gs