wzrd.in icon indicating copy to clipboard operation
wzrd.in copied to clipboard

Handle @latest as `dist-tag`

Open thom4parisot opened this issue 11 years ago • 4 comments

At the moment, only @latest is considered as being a valid dist-tag.

Although it is pretty handy to do a npm publish --tag blah to then npm install package@blah to alias a version and keep it moving.

Any plan to support that explicitly match the npm tag thing?

Thanks :-)

thom4parisot avatar Jul 10 '14 17:07 thom4parisot

I've never used tags, and have no idea how they work. So, no, I didn't have plans for this.

jfhbrook avatar Jul 10 '14 18:07 jfhbrook

It is one of those hidden gems of npm ;-)

$ npm show peaks.js | head
npm http GET http://registry.nodejitsu.com/peaks.js
npm http 304 http://registry.nodejitsu.com/peaks.js

{ name: 'peaks.js',
  description: 'Frontend app for displaying audio waveforms',
  'dist-tags': { latest: '0.2.1', beta: '0.3.0-beta.5' },
  versions:
   [ '0.0.1',
     '0.0.2',
     '0.0.3',
     '0.0.4',
     '0.0.5',

Every time npm publish is done, the latest dist-tag is updated with the version mentioned in the package.json, unless --tag is specified. In the latest case, the latest dist-tag is not updated.

Super handy to push things in beta or CI.

thom4parisot avatar Jul 10 '14 18:07 thom4parisot

I'll take a PR for this. Unfortunately, I don't have the bandwidth to attack too many wzrd.in issues right now.

jfhbrook avatar Jul 10 '14 18:07 jfhbrook

Okay I will try to give a go next week or so :-)

thom4parisot avatar Jul 11 '14 09:07 thom4parisot