Skip to content
This repository has been archived by the owner on Jun 20, 2022. It is now read-only.

Commit

Permalink
Update usage banner for CLI
Browse files Browse the repository at this point in the history
  • Loading branch information
meganemura committed Mar 17, 2015
1 parent 3238007 commit cafbb0e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,16 @@

## Usage

`sloc <target(s)>` to display SLOC (source lines of code)
`sloc [options] fil1, file2, ...` to display SLOC (source lines of code)

```
$ sloc
Usage: sloc [options] fil1, file2, ...
-h, --help Display this help message.
-o, --order Specify key to order by.
--desc Reverse order if specified.
-l, --limit Specify key to set limitation of displaying file number.
```

## Credits

Expand Down
2 changes: 2 additions & 0 deletions lib/sloc/cli.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ def setup(args)

def parse_options(args)
opts = Slop.parse!(args) do |o|
o.banner 'Usage: sloc [options] fil1, file2, ...'

o.on('-h', '--help', 'Display this help message.')
o.on('-o', '--order=', 'Specify key to order by.')
o.on('--desc', 'Reverse order if specified.')
Expand Down

0 comments on commit cafbb0e

Please sign in to comment.