August 03, 2012
Updated: 21 January 2013
Saving all three directories under the Sublime Text 2 entry in
~/Library Application Supportis overkill. You really only need to keep the
~/Library/Application Support/Sublime Text 2/Packages/Userdirectory. Read Sublime Text 2 Dotfiles Simplified for a more complete explanation and write up.
After reading more and more about Sublime Text 2 I decided to give it a try. The first thing you do with any new software is tweak the preferences and settings to suit your needs and aesthetics. Sublime Text 2 stores settings, themes, and plugins in the
~/Library/Application Support/Sublime Text 2 directory in three separate folders:
First close Sublime Text 2.
Next add a directory called
Sublime Text 2 to the working copy of your dotfiles repository
$ cd ~/.dotfiles $ mkdir Sublime\ Text\ 2
Move these folders from
~/Library/Application Support/Sublime Text 2 to the
Sublime Text 2 directory in
$ cd ~/.dotfiles/Sublime\ Text\ 2 $ mv ~/Library/Application\ Support/Sublime\ Text\ 2/Installed\ Packages . $ mv ~/Library/Application\ Support/Sublime\ Text\ 2/Packages . $ mv ~/Library/Application\ Support/Sublime\ Text\ 2/Pristine\ Packages .
Next create symbolic links in the
~/LibraryApplication Support/Sublime\ Text\ 2 directory to the new location of the settings directories.
$ cd ~/Library/Application\ Support/Sublime\ Text\ 2 $ ln -s ~/.dotfiles/Sublime\ Text\ 2/Installed\ Packages ./Installed\ Packages $ ln -s ~/.dotfiles/Sublime\ Text\ 2/Packages ./Packages $ ln -s ~/.dotfiles/Sublime\ Text\ 2/Pristine\ Packages ./Pristine\ Packages
For each added machine where you install Sublime Text you will need to remove the three settings directories from their default location and replace them with links to the set in your
Finally update the README for your
.dotfiles repository with enough of these instructions to remind you what you did six months from now when you stumble upon it again.