I have two computers, a desktop and a laptop. Now I have set up my ENV to sync with the help of a dropbox link.
Is there a way to sync my Sublime Text 3 settings between these two computers including all my plugins, preference files, etc... and, if so, how can I set things up to sync properly?
I am assuming you are using Package Control for managing your plugins.
What to Sync
Both a list of your packages as well as all of your settings files are all contained within your Packages/User/
folder and that is what you want to keep synced. Assuming that folder is synced, then all you have to do is make sure Package Control is installed and it will automatically install the correct packages based on the packages list you synced.
How to Sync
See this page on the Package Control website for instructions on syncing your settings.
The techniques listed there essentially are either using Git directly in your Packages/User/
folder or are using Dropbox (although the same concept would apply to any cloud service) in combination with symbolic links (since your Dropbox directory and your Sublime Text install are probably not in the same place on your hard drive).
Despite DropBox, you can simply use Git to sync Sublime Text settings and Package Control Packages:
- Create a repository (e.g. on GitHub)
Create a gitignore file with the following content:
# Ignore everything...
*
# ... except preferences and package list
!.gitignore
!Preferences.sublime-settings
!Package Control.sublime-settings
Set up the created repository in the user directory (Windows 10: ~/AppData/Roaming/Sublime\ Text\ 3/Packages/User
, Ubuntu: ~/.config/sublime-text-3/Packages/User
) of the first computer with the following Git commands:
$ git init
$ git remote add origin <repository url>
$ git fetch
$ git commit -am "added: settings and packages"
$ git push
Set up the repository on all other computers (the last line overwrites the current settings with those from the repository):
$ git init
$ git remote add origin <repository url>
$ git fetch
$ git reset --hard origin/master
Now you just have to pull/push changes from the repository to have your settings and packages synchronized. In addition you can sync the settings with the Git Package for Sublime Text. Here you don’t have to switch to a Git Shell to pull or push the changes but you can do it right in Sublime Text.
See this article on Medium for further information.
Use the SyncSettings package. Takes like 30 seconds to set up