afbobak / nopar

Node PAckage Registry
http://afbobak.github.io/nopar/
Other
42 stars 13 forks source link

support new atomic publish #14

Closed glenjamin closed 10 years ago

glenjamin commented 10 years ago

This should be quite simple, i'll add a PR when I get a chance.

On old npm clients:

PUT /packagename
409
GET /packagename
200
PUT /packagename/-rev/4
200

On new npm clients:

PUT /packagename
409
GET /packagename
200
# getReponse.merge(putRequest)
PUT /packagename
200

See https://github.com/npm/npm-registry-client/commit/e9fbeb8b67f249394f735c74ef11fe4720d46ca0#diff-162be319be481edf95e15a28cb4981f5 for more info

glenjamin commented 10 years ago

I've got this half working, in that the publish appears to work, but loses the tarball.

Next step is to incorporate the equivalent of https://github.com/npm/npmjs.org/commit/c2279447cf1e1b1a55b51f768d2bb66bb3514381 into nopar.

Progress can be seen at https://github.com/glenjamin/nopar

mantoni commented 10 years ago

I guess this one can be closed, right?

afbobak commented 10 years ago

Yup, it's fixed with version 0.3.4