mirror of
https://github.com/jashkenas/coffeescript.git
synced 2026-05-03 03:00:14 -04:00
add proper spacing to optparse by default
This commit is contained in:
@@ -51,7 +51,7 @@ exports.run: ->
|
||||
|
||||
# The "--help" usage message.
|
||||
usage: ->
|
||||
puts '\n' + option_parser.help() + '\n'
|
||||
puts option_parser.help()
|
||||
process.exit 0
|
||||
|
||||
# The "--version" message.
|
||||
|
||||
@@ -34,7 +34,7 @@ exports.OptionParser: class OptionParser
|
||||
spaces: if spaces > 0 then (' ' for i in [0..spaces]).join('') else ''
|
||||
let_part: if rule.letter then rule.letter + ', ' else ' '
|
||||
lines.push ' ' + let_part + rule.flag + spaces + rule.description
|
||||
lines.join('\n')
|
||||
'\n' + lines.join('\n') + '\n'
|
||||
|
||||
# Regex matchers for option flags.
|
||||
LONG_FLAG: /^(--\w[\w\-]+)/
|
||||
|
||||
Reference in New Issue
Block a user