Skip to content

Commit

Permalink
Sort ctags output
Browse files Browse the repository at this point in the history
  • Loading branch information
timkendrick committed Oct 14, 2015
1 parent 21e1fa9 commit 4bcfb30
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions bin/jsctags
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,8 @@ if(!argv._.length) {
}, function (e, results) {
if(e) throw e
if(argv.f) {
return results.forEach(function (tags) {
jsctags.ctags(tags).forEach(function (tag) {
process.stdout.write(tag)
})
})
var ctags = Array.prototype.concat.apply([], results.map(jsctags.ctags))
console.log(ctags.sort().join(''))
} else {
var tags = Array.prototype.concat.apply([], results)
console.log(JSON.stringify(tags, null, 2))
Expand Down

0 comments on commit 4bcfb30

Please sign in to comment.