README.md in rcmd-1.5.7 vs README.md in rcmd-1.5.8

- old
+ new

@@ -19,18 +19,19 @@ # Usage Examples ## Help Screen ```bash -daibhidh@darkstar:~/$ rcmd --help Usage: rcmd [options] -u, --username username Username for SSH connections -n, --nodes x,y,z Comma seperated list of nodes. use '-' for a space seperated list piped from another command + -r, --regexp regex Use Regex to build host list (ruby regexp) -t, --threads threads Number of threads to run -c, --command <command> Quoted string containing the command to be run -q, --quiet Suppress stdout of commands. stderr will still be displayed - -v, --version Print what version of the command is in use + -v, --version Print what version of the command is in use + -D, --debug Print debug information ``` ## Specifying nodes manually Specifying a comma seperated list of hosts and timing the total execution time. ```bash @@ -54,11 +55,24 @@ node3.example.com :: Red Hat Enterprise Linux ComputeNode release 6.9 (Santiago) node2.example.com :: Red Hat Enterprise Linux ComputeNode release 6.8 (Santiago) node4.example.com :: Red Hat Enterprise Linux ComputeNode release 6.9 (Santiago) ``` -## Using a database for obtaining nodes -TODO +## Using regex to build node list +```bash +daibhidh@darkstar:~/$ rcmd -r 'node([1-9]|1[1-2])$' -c 'hostname -f' +node2 :: node2.example.com +node1 :: node1.example.com +node4 :: node4.example.com +node3 :: node3.example.com +node5 :: node5.example.com +node6 :: node6.example.com +node8 :: node8.example.com +node7 :: node7.example.com +node11 :: CONNECT ERROR :: Unable to connect to host! +node9 :: node9.example.com +node12 :: node12.example.com +``` # Development If you are wanting to modify the code by all means do so. If you clone this repository you can then run `bundle install` to install the dependencies needed. Tests are performed with *rspec* and can be run with *rake*.