/todo-cli-ruby

πŸ“ CLI to manage todo.

Primary LanguageRubyMIT LicenseMIT

Todo

Command Line Interface for simple todo management

Installation

Add this line to your application's Gemfile:

gem 'todo'

And then execute:

$ bundle

Or install it yourself as:

$ gem install todo

Usage

$ exe/todo
Commands:
  todo add             # add new todo
  todo clear           # clear all todos
  todo delete          # delete a todo
  todo done            # make a todo done
  todo help [COMMAND]  # Describe available commands or one specific command
  todo init            # initialize
  todo list            # show todo list

Examples

  • initialize at first
$ exe/todo init
# Add task
$ exe/todo add foo
  +------------------+---------+----+-------+------+
  | created_at       | done_at | id | state | task |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 1  | πŸ”₯     | foo  |
  +------------------+---------+----+-------+------+
$ exe/todo add bar
  +------------------+---------+----+-------+------+
  | created_at       | done_at | id | state | task |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 1  | πŸ”₯     | foo  |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 2  | πŸ”₯     | bar  |
  +------------------+---------+----+-------+------+
$ exe/todo add buzz
  +------------------+---------+----+-------+------+
  | created_at       | done_at | id | state | task |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 1  | πŸ”₯     | foo  |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 2  | πŸ”₯     | bar  |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 3  | πŸ”₯     | buzz |
  +------------------+---------+----+-------+------+

# Make task done
$ exe/todo done 2
  +------------------+---------+----+-------+------+
  | created_at       | done_at | id | state | task |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 1  | πŸ”₯     | foo  |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 3  | πŸ”₯     | buzz |
  +------------------+---------+----+-------+------+

# Show all tasks
$ exe/todo list --all
  +------------------+------------------+----+-------+------+
  | created_at       | done_at          | id | state | task |
  +------------------+------------------+----+-------+------+
  | 2018-01-16 13:38 |                  | 1  | πŸ”₯     | foo  |
  +------------------+------------------+----+-------+------+
  | 2018-01-16 13:38 | 2018-01-16 13:38 | 2  | πŸŽ‰     | bar  |
  +------------------+------------------+----+-------+------+
  | 2018-01-16 13:38 |                  | 3  | πŸ”₯     | buzz |
  +------------------+------------------+----+-------+------+

# Show tasks which have been not done
$ exe/todo list
  +------------------+---------+----+-------+------+
  | created_at       | done_at | id | state | task |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 1  | πŸ”₯     | foo  |
  +------------------+---------+----+-------+------+
  | 2018-01-16 13:38 |         | 3  | πŸ”₯     | buzz |
  +------------------+---------+----+-------+------+i

Development

After checking out the repo, run bin/setup to install dependencies. Then, run rake spec to run the tests. You can also run bin/console for an interactive prompt that will allow you to experiment.

To install this gem onto your local machine, run bundle exec rake install. To release a new version, update the version number in version.rb, and then run bundle exec rake release, which will create a git tag for the version, push git commits and tags, and push the .gem file to rubygems.org.

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/msroz/todo-cli-ruby. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The gem is available as open source under the terms of the MIT License.

Code of Conduct

Everyone interacting in the Todo project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.