From 3e5347be1e67a018db0a936dd297be6aa0b603c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mislav=20Marohni=C4=87?= Date: Sun, 9 Oct 2022 14:49:15 +0200 Subject: [PATCH] Make the usage syntax for arbitrary args consistent (#1447) --- libexec/rbenv-completions | 2 +- libexec/rbenv-help | 2 +- test/help.bats | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/libexec/rbenv-completions b/libexec/rbenv-completions index 19551c2..a219b7b 100755 --- a/libexec/rbenv-completions +++ b/libexec/rbenv-completions @@ -1,5 +1,5 @@ #!/usr/bin/env bash -# Usage: rbenv completions [arg1 arg2...] +# Usage: rbenv completions [...] set -e [ -n "$RBENV_DEBUG" ] && set -x diff --git a/libexec/rbenv-help b/libexec/rbenv-help index 481ea34..f7d26d4 100755 --- a/libexec/rbenv-help +++ b/libexec/rbenv-help @@ -157,7 +157,7 @@ if [ -z "$1" ] || [ "$1" == "rbenv" ]; then if [ -z "$usage" ] && [ -t 1 ] && type -P man >/dev/null; then MANPATH="${BASH_SOURCE%/*}/../share/man:$MANPATH" exec man rbenv fi - echo "Usage: rbenv []" + echo "Usage: rbenv [...]" [ -n "$usage" ] && exit echo echo "Some useful rbenv commands are:" diff --git a/test/help.bats b/test/help.bats index fddaafc..256549e 100644 --- a/test/help.bats +++ b/test/help.bats @@ -5,14 +5,14 @@ load test_helper @test "without args shows summary of common commands" { run rbenv-help assert_success - assert_line "Usage: rbenv []" + assert_line "Usage: rbenv [...]" assert_line "Some useful rbenv commands are:" } @test "usage flag" { run rbenv-help --usage assert_success - assert_output "Usage: rbenv []" + assert_output "Usage: rbenv [...]" } @test "invalid command" {