From: Serge Hallyn Date: Sat, 25 Jun 2011 13:17:47 +0000 (+0200) Subject: Clarify the template-specific options a bit in lxc-create's help X-Git-Tag: lxc-0.7.5~23 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7c3ab01ffd3f59786fef85a5cbb1718659630f4d;p=thirdparty%2Flxc.git Clarify the template-specific options a bit in lxc-create's help This does not supplant the need for a manpage, but it's a start. Signed-off-by: Serge Hallyn Signed-off-by: Daniel Lezcano --- diff --git a/src/lxc/lxc-create.in b/src/lxc/lxc-create.in index 00e6b21ed..63750e9b8 100644 --- a/src/lxc/lxc-create.in +++ b/src/lxc/lxc-create.in @@ -21,7 +21,7 @@ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA usage() { - echo "usage: lxc-create -n [-f configuration] [-t template] [-h]" + echo "usage: lxc-create -n [-f configuration] [-t template] [-h] -- [template_options]" } help() { @@ -33,6 +33,17 @@ help() { echo "name : name of the container" echo "configuration: lxc configuration" echo "template : lxc-template is an accessible template script" + if [ -z $lxc_template ]; then + echo "for template-specific help, specify a template, for instance:" + echo "lxc-create -t ubuntu -h" + exit 0 + fi + type ${templatedir}/lxc-$lxc_template >/dev/null + echo + echo "template-specific help follows: (these options follow '--')" + if [ $? -eq 0 ]; then + ${templatedir}/lxc-$lxc_template -h + fi } shortoptions='hn:f:t:'