Skip to content
This repository was archived by the owner on May 18, 2021. It is now read-only.

Commit fed3409

Browse files
committed
Remove "-option" suffix from --ssh-option and --rsync-option
This way it's much easier to type.
1 parent a9af70a commit fed3409

File tree

4 files changed

+13
-14
lines changed

4 files changed

+13
-14
lines changed

CHANGELOG.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,11 @@
33
FEATURES:
44

55
* Allow to specify one or more custom OpenSSH options on the command line, e.g.
6-
`chef-runner --ssh-option LogLevel=debug --ssh-option "ProxyCommand ..."`. See
6+
`chef-runner --ssh LogLevel=debug --ssh "ProxyCommand ..."`. See
77
`ssh_config(5)` for a list of available options and their format. (Thanks to
88
@berniedurfee who requested this feature.)
99
* Allow to specify one or more custom Rsync options on the command line, e.g.
10-
`chef-runner --rsync-option --progress`. See `rsync(1)` for a list of
11-
available options.
10+
`chef-runner --rsync --progress`. See `rsync(1)` for a list of available
1211
* Add `--color=false` option to disable colorized output.
1312

1413
IMPROVEMENTS:
@@ -31,7 +30,7 @@ BREAKING CHANGES:
3130
instead. This change also simplifies run list composition when multiple
3231
cookbooks are involved, e.g. `chef-runner apt postgresql::client nginx`.
3332
* No longer run Rsync in verbose mode by default. To get back the old output,
34-
you need to use `--rsync-option --verbose` now.
33+
you need to use `--rsync --verbose` now.
3534

3635
[omnibus package]: https://godoc.org/github.com/mlafeldt/chef-runner/chef/omnibus
3736

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -137,8 +137,8 @@ Usage: chef-runner [options] [--] [<recipe>...]
137137
-M, --machine <name> Name or UUID of Vagrant virtual machine
138138
-K, --kitchen <name> Name of Test Kitchen instance
139139
140-
--ssh-option <option> Add OpenSSH option as specified in ssh_config(5)
141-
--rsync-option <option> Add Rsync option as listed in rsync(1)
140+
--ssh <option> Add OpenSSH option as specified in ssh_config(5)
141+
--rsync <option> Add Rsync option as listed in rsync(1)
142142
143143
-i, --install-chef <version> Install Chef (x.y.z, latest, true, false)
144144
default: false
@@ -257,15 +257,15 @@ any system reachable over SSH.
257257
Use the `-H` option (or `--host`) to specify the name of a host that was
258258
configured for direct SSH access. The argument passed to `-H` has the format
259259
`[user@]hostname[:port]`, allowing you to optionally change SSH user and port.
260-
If you need to change other SSH settings, either use `--ssh-option` or add a
260+
If you need to change other SSH settings, either use `--ssh` or add a
261261
host-specific configuration section to your `~/.ssh/config`.
262262

263263
Examples:
264264

265265
$ chef-runner -H example.local
266266
$ chef-runner -H user@example.local
267267
$ chef-runner -H example.local:1234
268-
$ chef-runner -H example.local --ssh-option LogLevel=debug --ssh-option "ProxyCommand ..."
268+
$ chef-runner -H example.local --ssh LogLevel=debug --ssh "ProxyCommand ..."
269269

270270
### Installing Chef
271271

cli/cli.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ var usage = `Usage: chef-runner [options] [--] [<recipe>...]
1818
-M, --machine <name> Name or UUID of Vagrant virtual machine
1919
-K, --kitchen <name> Name of Test Kitchen instance
2020
21-
--ssh-option <option> Add OpenSSH option as specified in ssh_config(5)
22-
--rsync-option <option> Add Rsync option as listed in rsync(1)
21+
--ssh <option> Add OpenSSH option as specified in ssh_config(5)
22+
--rsync <option> Add Rsync option as listed in rsync(1)
2323
2424
-i, --install-chef <version> Install Chef (x.y.z, latest, true, false)
2525
default: false
@@ -82,9 +82,9 @@ func ParseFlags(args []string) (*Flags, error) {
8282
f.StringVar(&flags.Kitchen, "K", "", "")
8383
f.StringVar(&flags.Kitchen, "kitchen", "", "")
8484

85-
f.Var(&flags.SSHOptions, "ssh-option", "")
85+
f.Var(&flags.SSHOptions, "ssh", "")
8686

87-
f.Var(&flags.RsyncOptions, "rsync-option", "")
87+
f.Var(&flags.RsyncOptions, "rsync", "")
8888

8989
f.StringVar(&flags.ChefVersion, "i", "", "")
9090
f.StringVar(&flags.ChefVersion, "install-chef", "", "")

cli/cli_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,11 @@ func TestParseFlags(t *testing.T) {
4444
flags: &Flags{Kitchen: "some-instance", Color: true},
4545
},
4646
{
47-
args: []string{"--ssh-option", "x=1", "--ssh-option", "y 2 3"},
47+
args: []string{"--ssh", "x=1", "--ssh", "y 2 3"},
4848
flags: &Flags{SSHOptions: []string{"x=1", "y 2 3"}, Color: true},
4949
},
5050
{
51-
args: []string{"--rsync-option", "-x", "--rsync-option", "--y"},
51+
args: []string{"--rsync", "-x", "--rsync", "--y"},
5252
flags: &Flags{RsyncOptions: []string{"-x", "--y"}, Color: true},
5353
},
5454
{

0 commit comments

Comments
 (0)