isaacs/npm — pull request #4390 by kilianc (2013-12-27 19:33:37+00:00)
Title: sort deps with --save

This will keep deps ordered in a nice way, from this:

```
"dependencies": {
"koa": "~0.1.2",
"koa-router": "~1.6.1",
"co": "~3.0.1",
"request": "~2.30.0",
"colors": "~0.6.2",
"async": "~0.2.9",
"JSONStream": "~0.7.1",
"qs": "~0.6.6",
"event-stream": "~3.0.20",
"json-array-stream": "~0.1.2",
"koa-jsonp": "~0.0.3",
"koa-mount": "~1.2.2",
"koa-compress": "~1.0.0",
"koa-favicon": "~1.0.1",
"koa-response-time": "~1.0.1",
"debug": "~0.7.4",
"co-body": "0.0.1",
"nano": "~4.2.1"
},
```

to
```
"dependencies": {
"async": "~0.2.9",
"co": "~3.0.1",
"colors": "~0.6.2",
"co-body": "0.0.1",
"debug": "~0.7.4",
"json-array-stream": "~0.1.2",
"JSONStream": "~0.7.1",
"koa": "~0.1.2",
"koa-jsonp": "~0.0.3",
"koa-mount": "~1.2.2",
"koa-router": "~1.6.1",
"koa-favicon": "~1.0.1",
"koa-compress": "~1.0.0",
"koa-response-time": "~1.0.1",
"nano": "~4.2.1",
"request": "~2.30.0"
}
```

I think that a `--save --sort` or a `--save-sort` is necessary, but before go any further I wanted to check if this is something that could be potentially merged.

P.S. test are passing even though we need the test for this feature.