CLI Option Parsers

highline

A high-level IO library that provides validation, type conversion, and more for command-line interfaces. HighLine also includes a complete menu system that can crank out anything from simple list selection to complete shells with just minutes of work.

Rubygem highline

Total Downloads
21623080
Releases
46
Current Version
1.7.3
Released
2015-08-01 00:00:00 UTC
First Release
2005-04-29 04:00:00 UTC
Depends on following gems
Depending Gems
947

Github JEG2/highline

Watchers
637
Forks
75
Development activity
Less active
Last commit
2015-07-23 04:58:36 UTC
First commit

Slop

A DSL for gathering options and parsing command line flags

Rubygem slop

Total Downloads
17815839
Releases
65
Current Version
4.2.0
Released
2015-06-18 00:00:00 UTC
First Release
2010-11-26 00:00:00 UTC
Depends on following gems
Depending Gems
227

Github injekt/slop

Watchers
486
Forks
22
Development activity
Less active
Last commit
2013-07-25 09:44:36 UTC
Contributors
21
Issues

cocaine

A small library for doing (command) lines

Rubygem cocaine

Total Downloads
7484575
Releases
19
Current Version
0.5.6
Released
2015-03-02 00:00:00 UTC
First Release
2011-05-18 04:00:00 UTC

Github thoughtbot/cocaine

Watchers
617
Forks
45
Development activity
Less active
Last commit
2015-09-01 16:13:58 UTC
Contributors
30
Issues

Trollop

Trollop is a commandline option parser for Ruby that just gets out of your way. One line of code per option is all you need to write. For that, you get a nice automatically-generated help page, robust option parsing, command subcompletion, and sensible defaults for everything you don't specify.

Rubygem trollop

Total Downloads
3669454
Releases
29
Current Version
2.1.2
Released
2015-03-11 00:00:00 UTC
First Release
2007-01-29 08:00:00 UTC

mixlib-cli

A simple mixin for CLI interfaces, including option parsing

Rubygem mixlib-cli

Total Downloads
6736083
Releases
8
Current Version
1.5.0
Released
2014-04-25 00:00:00 UTC
First Release
2009-05-11 15:00:00 UTC
Depends on following gems
Depending Gems
86

Github opscode/mixlib-cli

Watchers
100
Forks
33
Development activity
Inactive
Last commit
2014-07-08 21:57:50 UTC
First commit

commander

The complete solution for Ruby command-line executables. Commander bridges the gap between other terminal related libraries you know and love (OptionParser, HighLine), while providing many new features, and an elegant API.

Rubygem commander

Total Downloads
1230975
Releases
23
Current Version
4.3.4
Released
2015-05-04 00:00:00 UTC
First Release
2009-10-08 10:00:00 UTC
Depends on following gems
Depending Gems
294

Github visionmedia/commander

Watchers
780
Forks
58
Development activity
Less active
Last commit
2014-07-01 02:41:45 UTC

gli

Build command-suite CLI apps that are awesome. Bootstrap your app, add commands, options and documentation while maintaining a well-tested idiomatic command-line app

Rubygem gli

Total Downloads
1222722
Releases
64
Current Version
2.13.2
Released
2015-08-28 00:00:00 UTC
First Release
2009-04-19 04:00:00 UTC
Depends on following gems
Depending Gems
277

Github davetron5000/gli

Watchers
575
Forks
61
Development activity
Less active
Last commit
2014-06-09 16:25:40 UTC

clamp

Clamp provides an object-model for command-line utilities. It handles parsing of command-line options, and generation of usage help.

Rubygem clamp

Total Downloads
1304061
Releases
28
Current Version
1.0.0
Released
2015-06-08 00:00:00 UTC
First Release
2010-11-01 13:00:00 UTC
Depends on following gems
Depending Gems
108

Github mdub/clamp

Watchers
203
Forks
24
Development activity
Inactive
Last commit
2014-03-10 09:22:11 UTC
First commit
Contributors
9
Issues

Choice

Choice is a simple little gem for easily defining and parsing command line options with a friendly DSL.

Rubygem choice

Total Downloads
1277783
Releases
9
Current Version
0.2.0
Released
2014-12-31 00:00:00 UTC
First Release
2006-04-30 07:00:00 UTC
Depends on following gems
Depending Gems
82

Github defunkt/choice

Watchers
163
Forks
20
Development activity
Less active
Last commit
2015-02-01 14:55:26 UTC
Top contributors
Contributors
4

methadone

Methadone provides a lot of small but useful features for developing a command-line app, including an opinionated bootstrapping process, some helpful cucumber steps, and some classes to bridge logging and output into a simple, unified, interface

Rubygem methadone

Total Downloads
115399
Releases
38
Current Version
1.9.1
Released
2015-06-07 00:00:00 UTC
First Release
2011-09-12 00:00:00 UTC

Github davetron5000/methadone

Watchers
450
Forks
42
Development activity
Less active
Last commit
2015-06-23 07:25:13 UTC

docopt

Isn't it awesome how `optparse` and other option parsers generate help and usage-messages based on your code?! Hell no! You know what's awesome? It's when the option parser *is* generated based on the help and usage-message that you write in a docstring! That's what docopt does!

Rubygem docopt

Total Downloads
216563
Releases
5
Current Version
0.5.0
Released
2012-09-01 00:00:00 UTC
First Release
2012-06-03 00:00:00 UTC
Depends on following gems
Depending Gems
42

Github docopt/docopt.rb

Watchers
366
Forks
25
Development activity
Inactive
Last commit
2012-09-25 06:03:21 UTC
First commit
Top contributors
Contributors
4
Issues

cmdparse

cmdparse provides classes for parsing (possibly nested) commands on the command line; command line options themselves are parsed using optparse.

Rubygem cmdparse

Total Downloads
469974
Releases
15
Current Version
3.0.0
Released
2015-03-12 00:00:00 UTC
First Release
2004-09-27 04:00:00 UTC
Depends on following gems
Depending Gems
29

Github gettalong/cmdparse

Watchers
4
Forks
1
Development activity
Less active
Last commit
2015-03-14 18:01:05 UTC
First commit
Top contributors
Contributors
1
Issues

cri

Cri allows building easy-to-use commandline interfaces with support for subcommands.

Rubygem cri

Total Downloads
341465
Releases
20
Current Version
2.7.0
Released
2015-04-29 00:00:00 UTC
First Release
2009-11-01 01:00:00 UTC
Depends on following gems
Depending Gems
21

Github ddfreyne/cri

Watchers
45
Forks
8
Development activity
Less active
Last commit
2015-04-29 19:46:52 UTC
First commit
Top contributors
Contributors
7
Issues

acclaim

Command-line option parser and command interface.

Rubygem acclaim

Total Downloads
119000
Releases
21
Current Version
0.5.1
Released
2012-06-26 00:00:00 UTC
First Release
2011-12-16 00:00:00 UTC
Depends on following gems
Depending Gems
1

Github matheusmoreira/acclaim

Watchers
7
Forks
0
Development activity
Inactive
Last commit
2012-07-27 01:38:30 UTC
Top contributors
Contributors
1
Issues

clap

Clap is a small library that can be bundled with your command line application. It covers the simple case of executing code based on the flags or parameters passed.

Rubygem clap

Total Downloads
15896
Releases
3
Current Version
1.0.0
Released
2012-03-29 00:00:00 UTC
First Release
2010-10-10 03:00:00 UTC
Depends on following gems
Depending Gems
29

Github soveran/clap

Watchers
63
Forks
6
Development activity
Inactive
Last commit
2014-01-29 03:12:26 UTC
Top contributors
Contributors
3
Issues

Optitron

Sensible options parsing

Rubygem optitron

Total Downloads
47465
Releases
28
Current Version
0.3.3
Released
2011-07-20 07:00:00 UTC
First Release
2010-08-15 07:00:00 UTC

getopt

The getopt library provides two different command line option parsers. They are meant as easier and more convenient replacements for the command line parsers that ship as part of the Ruby standard library. Please see the README for additional comments.

Rubygem getopt

Total Downloads
75493
Releases
16
Current Version
1.4.2
Released
2014-10-13 00:00:00 UTC
First Release
2005-10-06 06:00:00 UTC

Github djberg96/getopt

Watchers
7
Forks
1
Development activity
Inactive
Last commit
2014-10-13 05:11:03 UTC
Top contributors
Contributors
2
Issues

micro-optparse

This is an lightweight option parser, which is less than 80 lines short. It has strong validations and a short, clear and easy to use syntax. Feel free to copy all 80 lines (55 lines without validations / empty lines) into your script rather installing the gem.

Rubygem micro-optparse

Total Downloads
19577
Releases
10
Current Version
1.2.0
Released
2013-12-29 00:00:00 UTC
First Release
2011-02-25 23:00:00 UTC
Depends on following gems
Depending Gems
13

Github florianpilz/micro-optparse

Watchers
33
Forks
7
Development activity
Inactive
Last commit
2013-12-29 15:13:38 UTC
Top contributors
Contributors
2
Issues

quickl

Quickl helps you creating commandline ruby programs. From simple commands with options to complex delegators with subcommands, global and local options.

Rubygem quickl

Total Downloads
30537
Releases
9
Current Version
0.4.3
Released
2012-02-16 00:00:00 UTC
First Release
2010-12-23 23:00:00 UTC
Depends on following gems
Depending Gems
11

Github blambeau/quickl

Watchers
49
Forks
0
Development activity
Inactive
Last commit
2012-02-16 15:13:10 UTC
Top contributors
Contributors
3
Issues

config_parser

Parse command-line options into a configuration hash

Rubygem config_parser

Total Downloads
21622
Releases
10
Current Version
0.5.5
Released
2011-07-18 06:00:00 UTC
First Release
2010-07-25 06:00:00 UTC
Depends on following gems
Depending Gems
2

OptionParser

A flexible command line option parser.

Rubygem OptionParser

Total Downloads
17167
Releases
2
Current Version
0.5.1
Released
2005-06-17 04:00:00 UTC
First Release
2005-06-16 04:00:00 UTC
Depends on following gems
Depending Gems
20

getoptions

Yet another command line option parser in Ruby, based on Perl's Getopt::Long module.

Rubygem getoptions

Total Downloads
9557
Releases
3
Current Version
0.3
Released
2009-04-20 07:00:00 UTC
First Release
2007-11-30 08:00:00 UTC
Depends on following gems
Depending Gems
7

arg0

It's just here to handle arguments provided to Application. Mainly optional via switches. Currently handles plain-text Console arguments.

Rubygem arg0

Total Downloads
4255
Releases
3
Current Version
0.0.3
Released
2013-03-26 00:00:00 UTC
First Release
2013-01-27 00:00:00 UTC
Depends on following gems
Depending Gems
3

Github abhishekkr/arg0

Watchers
1
Forks
0
Development activity
Inactive
Last commit
2013-03-26 19:35:30 UTC
First commit
Top contributors
Contributors
1
Issues
×

In order to continue, you must be signed in using your Github account.

If you're signing in using this account for the first time Github will ask for your permission to give access to your public user data to the Ruby Toolbox.

Although the Github Authorization page does not mention it, the request includes read-only access to your verified email address (user:email OAuth scope). This is neccessary so there's a way to notify you about comments, information about your accepted project edits and the like. You can review your notification settings on your account page once you're signed in.