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
18510179
Releases
44
Current Version
1.7.1
Released
2015-02-25 00:00:00 UTC
First Release
2005-04-29 04:00:00 UTC
Depends on following gems
Depending Gems
942

Github JEG2/highline

Watchers
562
Forks
69
Development activity
Less active
Last commit
2015-04-19 03:45:03 UTC
First commit

Slop

A DSL for gathering options and parsing command line flags

Rubygem slop

Total Downloads
14028383
Releases
64
Current Version
4.1.0
Released
2015-04-18 00:00:00 UTC
First Release
2010-11-26 00:00:00 UTC
Depends on following gems
Depending Gems
226

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
7013137
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
570
Forks
43
Development activity
Less active
Last commit
2015-03-13 15:33:10 UTC
Contributors
29
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
3376636
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
5822165
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
1148277
Releases
21
Current Version
4.3.2
Released
2015-04-01 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
627438
Releases
62
Current Version
2.13.0
Released
2015-03-03 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

Choice

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

Rubygem choice

Total Downloads
1111845
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
158
Forks
19
Development activity
Less active
Last commit
2015-02-01 14:55:26 UTC
Top contributors
Contributors
4

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
998852
Releases
26
Current Version
0.6.4
Released
2015-02-26 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

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
96315
Releases
37
Current Version
1.9.0
Released
2015-02-21 00:00:00 UTC
First Release
2011-09-12 00:00:00 UTC

Github davetron5000/methadone

Watchers
445
Forks
40
Development activity
Less active
Last commit
2015-02-21 18:03:20 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
148453
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
40

Github docopt/docopt.rb

Watchers
334
Forks
22
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
401070
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
260846
Releases
19
Current Version
2.6.1
Released
2014-05-27 00:00:00 UTC
First Release
2009-11-01 01:00:00 UTC
Depends on following gems
Depending Gems
21

Github ddfreyne/cri

Watchers
44
Forks
7
Development activity
Less active
Last commit
2015-01-22 13:27:11 UTC
First commit
Top contributors
Contributors
7
Issues

acclaim

Command-line option parser and command interface.

Rubygem acclaim

Total Downloads
114083
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
13503
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
44087
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
67567
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
17264
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
31
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
27865
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
50
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
20408
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
16390
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
3713
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.