diff options
author | Mark Ferrell <major@homeonderanged.org> | 2014-04-08 08:50:31 -0700 |
---|---|---|
committer | Mark Ferrell <major@homeonderanged.org> | 2014-04-08 08:51:32 -0700 |
commit | f101ae8e29a6af278210e081b047412a19cb66f9 (patch) | |
tree | 3775f57aff94f9565a2016ca4f85a8c665215869 /libexec | |
parent | cb63919358fd9f0f2f0274a92329743ace0cbcee (diff) |
Cleanup help/usage information for some commands
Diffstat (limited to 'libexec')
-rwxr-xr-x | libexec/build-help | 2 | ||||
-rwxr-xr-x | libexec/build-make-install | 22 | ||||
-rwxr-xr-x | libexec/build-query | 2 |
3 files changed, 24 insertions, 2 deletions
diff --git a/libexec/build-help b/libexec/build-help index d1eefdf..00941e7 100755 --- a/libexec/build-help +++ b/libexec/build-help @@ -15,7 +15,7 @@ done # Simply display the builder usage. Though it would be nice if some of this # information was pushed down into the sub-commands. cat<<EOF -usage: ${0##*/} [options] <command> [command-opts] [all|<category>/<package|all> ...] +usage: build [options] <command> [command-opts] [all|<category>/<package|all> ...] Options ------- diff --git a/libexec/build-make-install b/libexec/build-make-install index 7a2c121..08dd4db 100755 --- a/libexec/build-make-install +++ b/libexec/build-make-install @@ -1,5 +1,27 @@ #!/usr/bin/env build +usage() +{ +cat<<END_OF_USAGE +END_OF_USAGE +} + +for arg; do + case "${arg}" in + (-h|-help|--help) usage; exit 0;; + esac +done + +while test "$#" -gt '0'; do + case "$1" in + (-*) error "unknown argument '${1}'" + echo "try 'build help install'" >&2 + exit 1;; + (--) shift; break;; + (*) break;; + esac +done + echo "installing: ${1}" eval $(build-query --environ "${1}") diff --git a/libexec/build-query b/libexec/build-query index c866453..d500840 100755 --- a/libexec/build-query +++ b/libexec/build-query @@ -3,7 +3,7 @@ usage() { cat<<END_OF_HELP -usage: ${0##*/} [options] <arg> +usage: build-query [options] <arg> options: --topdir Builder topdir |