0

How to save/restore Sublime Text 2 configs/plugins to migrate to another computer? states that, to backup a Sublime Text 2 installation, a user should preserve the ~/Packages/User directory (from the user's local data folder on whatever OS they're using).

However, http://andrew.hedges.name/blog/2012/01/19/sublime-text-2-more-sublime-with-a-drop-of-dropbox and most other walkthroughs for using Dropbox to sync Sublime's settings specify three directories: ~/Packages, ~/Installed Packages and ~/Pristine Packages.

What is the functional difference between backing up just ~/Packages/User, and the other 3 directories?

Community
  • 1
  • 1
KatieK
  • 13,586
  • 17
  • 76
  • 90

2 Answers2

1

I think that Packages/User is the one in which you are supposed to put settings (according to Sublime's official and unofficial documentation). However, some people put them in the other folders from time to time.

The Dropbox advice may be a hedge against poor practice.

dbn
  • 13,144
  • 3
  • 60
  • 86
1

From here:

Installed Packages is:

You will find this directory in the data directory. It contains a copy of every sublime-package installed. Used to restore Packages.

These are the packages installed as sublime-packages. I don't think package control uses this, but if you install something as a sublime-package maybe you want to keep it?

Pristine Packages is:

You will find this directoy in the data directory. It contains a copy of every shipped and core package. Used to restore Packages.

So essentially a list of .sublime-package files used to restore if you break something.

Packages is:

The packages used by Sublime Text, either installed as part of sublime, or the plugins.

User is:

The user directory is your personal directory, containing configurations, additional snippets, etc.

Below are my personal views on what to save, so feel free to ignore it if you would like.

I would have to agree with the post saying just save the User directory, as Package Control will grab all of the plugins in the list if they aren't already installed. I didn't see this mentioned in that post, but you can also add repositories (by specifying a URL) to Package Control, which allows you to install Packages outside of those submitted to Package Control, but still hosted somewhere. One of the arguments I can see to saving the Packages directory completely is if you are using plugins that aren't hosted anywhere (though these could probably be moved to the Packages directory without any problems).

The Installed Packages and Pristine Packages are used to restore packages, so I wouldn't think these would be needed, but I'm sure there is some use case where it is.

Anyways, realize I got off topic a bit at the end there, but hope everything before that helps clarify.

skuroda
  • 19,514
  • 4
  • 50
  • 34