Search code examples
jsonsublimetext2sublimetext3sublimetextpackage-control

How do you reopen messages.json in Sublime Text (3)?


I read packagecontrol.io's doc regarding messages.json, but what I'm referring to is the file tab that sublime text typically displays upon a new package install. It appears as a continuous roll of installation notes throughout multiple installations. It appears that this is a feed of the individual messages.json files displayed when the packages are downloaded. Is there a way to open the unified file that displays messages from multiple packages? Or is there a more common way to access these package files?


Solution

  • What you are asking about are the install and release messages pointed to by those keys inside messages.json. For example, from one of my packages,

    {
        "install": "messages/install.txt",
        "1.2.1": "messages/1.2.1.txt",
        "1.3.0": "messages/1.3.0.txt",
        "1.3.1": "messages/1.3.1.txt",
        "1.4.2": "messages/1.4.2.txt",
        "2.0.1": "messages/2.0.0.txt",
        "2.1.1": "messages/2.1.0.txt",
        "2.2.0": "messages/2.2.0.txt",
        "2.2.1": "messages/2.2.1.txt"
    }
    

    Whenever someone installs the package for the first time, Package Control prints the contents of messages/install.txt to that new view you mentioned. It will also print the file corresponding to the current release, which is a "release" tagged on Github. If I were to go and release 2.3.0, for example, and not update messages.json, no update message would be printed telling users I'd pushed out a new version. In some cases this is desirable, in case I had to quickly push out a point release to fix some stupid mistake I made in a major (or minor) release, not that I've ever done that before :) But, in most cases, I want to keep users up to date on development, so I'll write a message for them in a new file, and add an appropriate key and value to messages.json.

    Is there a way to open the unified file that displays messages from multiple packages? Or is there a more common way to access these package files?

    The view that opens and shows you the messages from all the newly-installed and -upgraded packages is unique to you and your particular situation - there is no way to recover it once you close the tab. However, if you're interested in a particular package's message(s), just use PackageResourceViewer (in ST3) to open the package, view the messages.json file to see which is the most recent file you want to view, then find and read that file. In ST2 all packages are already unpacked in your Packages folder.