Project

cliutils

0.01
No release in over 3 years
Low commit activity in last 3 years
A library of functionality designed to alleviate common tasks and headaches when developing command-line (CLI) apps in Ruby.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.5
~> 0
= 2.14.1
= 0.8.7.4

Runtime

= 2.4.2
 Project Readme

CLIUtils

Build Status Gem Version Coverage Status

CLIUtils is a library of functionality designed to alleviate common tasks and headaches when developing command-line (CLI) apps in Ruby.

Updating from 1.x.x to 2.0.0?

The big difference is schema changes for Validators, Behaviors, and Pre-Post Actions. Make sure you read the wiki.

Why?

It's fairly simple:

  1. I love developing Ruby-based CLI apps.
  2. I found myself copy/pasting common code from one to another.
  3. I decided to do something about it.

Libraries

CLIUtils offers:

  • PrettyIO: some basic CLI sugar
  • Messaging: a system to display nicely-formatted messages to one or more tagets
  • Configuration: a app configuration manager
  • Prefs: a preferences prompter and manager

...along with plenty of documentation:

Compatibility

CLIUtils is certified against the following:

  • Ruby 2.1.1
  • Ruby 2.1.0
  • Ruby 2.0.0
  • Ruby 1.9.3

Installation

Add this line to your application's Gemfile:

$ gem 'cliutils'

And then execute:

$ bundle

Or install it yourself:

$ gem install cliutils

Usage

require 'cliutils'

If you want to mix in everything that CLIUtils has to offer:

include CLIUtils

Can I use it with...?

I often get asked how nicely CLIUtils plays with other Ruby-based CLI libraries (like Dave Copeland's excellent Methadone and GLI). Answer: they play very nicely. I use CLIUtils in Sifttter Redux (which is built on GLI) and ExpandSync (which is built on Methadone).

Bugs and Feature Requests

To view my current roadmap and objectives, check out the Trello board.

To report bugs with or suggest features/changes for CLIUtils, please use the Issues Page.

Contributing

Contributions are welcome and encouraged. To contribute:

  1. Fork it (http://github.com/bachya/cliutils/fork)
  2. Create your feature branch (git checkout -b my-new-feature)
  • Make sure you add tests!
  1. Commit your changes (git commit -am 'Add some feature')
  2. Push to the branch (git push origin my-new-feature)
  3. Create new Pull Request

License

(The MIT License)

Copyright © 2014 Aaron Bach bachya1208@gmail.com

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.