|
1 | | -# Argonaut |
| 1 | +# Argonaut CLI |
2 | 2 |
|
3 | | -Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/argonaut`. To experiment with that code, run `bin/console` for an interactive prompt. |
4 | | - |
5 | | -TODO: Delete this and the text above, and describe your gem |
| 3 | +Use Argonaut from your command line! |
6 | 4 |
|
7 | 5 | ## Installation |
8 | 6 |
|
9 | | -Add this line to your application's Gemfile: |
10 | | - |
11 | 7 | ```ruby |
12 | | -gem 'argonaut' |
| 8 | +gem install argonaut-cli |
13 | 9 | ``` |
14 | 10 |
|
15 | | -And then execute: |
| 11 | +Create the config file `~/.argonaut.yml` and populate it with the sample config below: |
| 12 | + |
| 13 | +```yaml |
| 14 | +# The only required fields for the gem to run are api_token and url_root |
16 | 15 |
|
17 | | - $ bundle |
| 16 | +api_token: YOUR_TOKEN |
| 17 | +url_root: https://theargonaut-api.herokuapp.com |
18 | 18 |
|
19 | | -Or install it yourself as: |
| 19 | +# Below are the optional settings to customize output |
| 20 | + |
| 21 | +options: |
| 22 | + colorize_rows: true |
| 23 | + time_format: '%d %b %Y %l:%M %p' |
| 24 | + high_contrast_colors: true |
| 25 | +``` |
20 | 26 |
|
21 | | - $ gem install argonaut |
| 27 | +Replace `YOUR_TOKEN` in the sample config above with your own token that can be found in the Profile page in the web app. |
| 28 | + |
| 29 | +You can also export environment variables `ARGONAUT_API_TOKEN` and `ARGONAUT_URL_ROOT` with the correct values without needing a config file. |
22 | 30 |
|
23 | 31 | ## Usage |
24 | 32 |
|
25 | | -TODO: Write usage instructions here |
| 33 | +By default, invoking `argonaut` lists all your environment reservations. |
| 34 | + |
| 35 | +**View all registered teams:** |
| 36 | + |
| 37 | +``` |
| 38 | +argonaut -T |
| 39 | +``` |
| 40 | +
|
| 41 | +**View reservations table on a particular team's environments:** |
| 42 | +
|
| 43 | +Using team id |
| 44 | +``` |
| 45 | +argonaut -t 1 |
| 46 | +``` |
| 47 | +
|
| 48 | +Using team name |
| 49 | +``` |
| 50 | +argonaut -t EPA |
| 51 | +``` |
| 52 | +
|
| 53 | +**Make a reservation:** |
| 54 | +
|
| 55 | +``` |
| 56 | +argonaut -r pbm1:epamotron |
| 57 | +``` |
| 58 | +
|
| 59 | +**Release when you are done testing in that environment:** |
| 60 | +
|
| 61 | +``` |
| 62 | +argonaut -r pbm1:epamotron |
| 63 | +``` |
| 64 | +**Clear all your reservations at once** |
| 65 | +
|
| 66 | +``` |
| 67 | +argonaut -c |
| 68 | +``` |
| 69 | +
|
| 70 | +Full list of options can be viewed by running `argonaut -h`. If you are using zsh, you can generate shell completion and add it to your `~/.zshrc` like so: |
| 71 | +
|
| 72 | +``` |
| 73 | +echo compdef _gnu_generic argonaut >> ~/.zshrc |
| 74 | +``` |
26 | 75 |
|
27 | 76 | ## Development |
28 | 77 |
|
29 | 78 | 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. |
30 | 79 |
|
31 | | -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](https://rubygems.org). |
32 | | - |
33 | 80 | ## Contributing |
34 | 81 |
|
35 | | -Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/argonaut. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct. |
| 82 | +Bug reports and pull requests are welcome on GitHub at https://github.com/qubbit/argonaut-cli/issues. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct. |
36 | 83 |
|
37 | 84 |
|
38 | 85 | ## License |
|
0 commit comments