So for example there is a new versions for the atom/autosave package but I have an older one installed and I can’t find a way to update it…
You can use the
apm upgrade command to show and update all your packages.
You can upgrade to a specific version.
apm install email@example.com
The problem was that the
autosave wasn’t in the packages as it was there from the beginning… so
$ apm upgrade Package Updates Available (0) └── (empty)
So after the
apm install all good
Sorry for bumping an old topic, but I wanted to see if there is a better way.
apm upgrade only upgrades packages installed in your
~/.atom/packages/ directory. Core packages are installed somewhere else (for OSX:
/Applications/Atom.app/Contents/Resources/app/node_modules/). In addition, you can’t update (or uninstall) the package with the
settings-view, probably because it would require
sudo on Linux/BSD. So to update core packages, do I install the package into my home folder with
apm install [package-name]?
This is kind of a hassle since you have to do each package individually Also, you have to check atom.io/packages to see if there is an update. Since
apm outdated will not show outdated core packages. More over, I have found this causes editor confusion when updating Atom.
Don’t worry about reviving old topics, so long as you’re actually talking about the same thing. I feel like keeping the discussion all in one place gives people a sense of the whole conversation and how it shifts over time instead of the same conversation happening every month
To answer your question though …
All good answers to good questions start with “it depends”. In this case, it depends on what you mean by “the latest versions”.
To me, if the core editor is on version X and you update a core package to some other version that did not come with version X … then you’re not on version X anymore. And if you came and reported a bug and we asked what version you’re on and you said version X … then everyone would get confused because your version of Atom would not act like version X, perhaps in very drastic ways. So, unless and until Atom’s versioning system takes into account the versions of all installed core packages … I would strongly recommend against updating core packages separately from Atom Core itself.
Now, often Atom Core is at version X officially but the master branch is at Y-[some SHA] which will become just Y if and when it is officially released. Very often, when a core package is updated, after it has been tested thoroughly … the updated core package is rolled into the definition of Y-[some other SHA]. You can then, easily and safely check out master, build and you’ll have the “latest” version of that core package. And if you run into a problem and you come here and say you’re on version Y-[some other SHA] we can sync to [some other SHA] and our system will behave (in theory) exactly like yours. Smileys all around!
So, what you’re running into is kind of “by design”. It should be hard to update core packages separately from core … because unless you really know what you’re doing, you shouldn’t need to do that. And if you really know what you’re doing … well … then you can easily write a script to automate it. And you’ll probably also remember to say when you report a bug, “I’m on version X, but I separately updated package Y to version Z and package A to version B.”
Then we’ll tell you to write some tests to figure out why everything’s broken
Oh and I just get done writing up this long-winded answer and I realize that your question may be all due to a misunderstanding …
When you update to the latest version of Atom using a supported method (like installing from a pre-built version or checking out the code and building using the standard build instructions), it updates all the core packages with it (at least to the versions that were meant to be in that version). You don’t need to do anything special.
Thanks for explaining why it is hard to update core packages. If the package requires code from Atom HEAD, the package probably wouldn’t work with the latest release of Atom.
So it might be best to update one by one, before checking the repo to see what the changes were.
Atom Core has a reference of which core packages (and their versions) it is meant to be installed with. For example:
So when you update to Atom HEAD and build Atom, it will update all the packages to exactly these versions automatically as part of the build process. You don’t need to do anything special … and in my opinion, shouldn’t.
@leedohm Do you think this will be the case after the API freeze? (This being core packages are only upgraded when a new Atom is released.) I believe I have gotten updates from core packages in between releases, so I think updates can be pushed out individually.
I would be very surprised if this happened.
It depends on what you mean by “core packages”. By my definition, a “core package” is one that is packaged with atom in the
package.json that I linked. There are Atom-published non-core packages (like sort-lines) that are updated in between Atom releases. Also, updates to core packages are checked into master “between” releases. But that isn’t what I’m talking about either.
Ok, I guess I meant your definition of core packages. But, was confusing the two. Thanks for clarifying.
This is because I installed language-ruby to my home folder. I guess I got confused.
I seem to remember reading that it ins’t good to install built-in packages in our home folders. I don’t remember why.
Because you can install a version of the built-in package that is incompatible with the version of Atom you have installed. Pretty much the reasons I mentioned in my long-winded (and possibly unnecessary ) post above.