DEVELOPMENT STOPPED. EOL.
Tiny test tool.
For 1.* versions of cigarette, please read this README.
You need rubygems installed.
Tested with Ruby:
- 1.8.7
- 1.9.2
- 1.9.3
- 2.0.0-preview1
$ gem install cigarette
or, for development:
$ git clone https://github.com/TibshoOT/cigarette.git
$ gem build cigarette.gemspec
$ gem install ./cigarette
In order to smoke or run cigarette, you need to create a .cigarette file binary call directory.
For example, you need to test your app in /home/lucky/app:
$ cd /home/lucky/app
$ touch .cigarette
[fill needed options]
$ cigarette
That's it.
At the moment, there is only two options:
Attribute | Argument | Explanation |
---|---|---|
each | Period between run | Time between command run (in second) |
command | a command to execute | This command will be exectued each :each configuration |
rvm | List of rubies | Each ruby will be tested with its own status |
Example:
$ cat .cigarette
You could see:
each: 75
command: 'rake test'
rvm:
- 1.8.7
- 1.9.3
Or:
each: 10
command: rake test
'rake test' will be executed each 75 seconds with ruby 1.8.7 and ruby 1.9.3 int the first example.
In the second example, if you don't specify rvm attribute, 'rake test' will be executed with your running ruby (system installed ruby if rvm is not setup or configured or rvm current ruby) only. :)
To use rvm: attribute, you have to setup RVM.
Please, follow RVM man instructions here.
For each attribute, you can use period helper.
Helper | Example | Equivalent without helper |
---|---|---|
second | 2.second | 2 |
minute | 5.minute | 300 |
hour | 1.hour | 3600 |
Example:
$ cat .cigarette
You should see:
each: 2.minute
command: 'rake test'
You can pluralize these helpers (seconds, minutes, hours).
each: 5.hours
You have some shortcuts:
Shortcut | Binded key | Explanation |
---|---|---|
Rebuild | r | Useful to run command again between to run time |
Quit | q | Quit cigarette |
Left | Left arrow | Switch to the left (when you have some rubies) |
Right | Right arrow | Switch to the right (when you have some rubies) |
Go to containing .cigarette file directory and run cigarette:
$ cd your/directory
$ cigarette
Enjoy.
Open an issue ;)