Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Keep your @ohmyzsh ~/.zshrc in sync via dropbox
# Was asked how I keep my zshrc config sync'd between my computers with Dropbox
# Add a new directory in your Dropbox (or use an existing one)
mkdir -p ~/Dropbox/ohmyzsh
# move existing file to Dropbox
mv ~/.zshrc ~/Dropbox/ohmyzsh/zshrc
# symlink file back to your local directory
ln -s ~/Dropbox/ohmyzsh/zshrc ~/.zshrc
@mannion007

This comment has been minimized.

Copy link

mannion007 commented Aug 19, 2016

Works.

Alternatively, you could create a dotfiles github repository, check it out anywhere then link it in the same way.

Do you not have anything else to sync such as your own functions file? I'm exploring ways to sync those too, wondering if I should just whack all my functions at the bottom of .zshrc and be done with it.

@scottfister

This comment has been minimized.

Copy link

scottfister commented Jun 11, 2018

I had to change the last line to ln -s ~/Dropbox/ohmyzsh/.zshrc ~/.zshrc to get it to work.

@phillipchan1

This comment has been minimized.

Copy link

phillipchan1 commented May 16, 2019

This is great. For those with computers with different usernames, I had to change the zsh library pointing to be dynamic:

export ZSH="/Users/$USER/.oh-my-zsh"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.