public inbox for cluster-cvs@sourceware.org help / color / mirror / Atom feed
From: "Fabio M. Di Nitto" <fabbione@fedoraproject.org> To: cluster-cvs-relay@redhat.com Subject: cluster: STABLE3 - config validation: clean up last bits Date: Fri, 11 Sep 2009 07:22:00 -0000 [thread overview] Message-ID: <20090911072158.87034120377@lists.fedorahosted.org> (raw) Gitweb: http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=b25166629f95f0e3a4e0cd527fb17f25e8ca1699 Commit: b25166629f95f0e3a4e0cd527fb17f25e8ca1699 Parent: d4610c81e3550332b0a5b64d819b458d9e2e4eb4 Author: Fabio M. Di Nitto <fdinitto@redhat.com> AuthorDate: Fri Sep 11 09:20:50 2009 +0200 Committer: Fabio M. Di Nitto <fdinitto@redhat.com> CommitterDate: Fri Sep 11 09:20:50 2009 +0200 config validation: clean up last bits allow load and no load tests for XML config files. sort a few options into Advanced and kill Debugging options. Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com> --- config/tools/xml/ccs_config_validate.in | 38 +++++++++++++++--------------- 1 files changed, 19 insertions(+), 19 deletions(-) diff --git a/config/tools/xml/ccs_config_validate.in b/config/tools/xml/ccs_config_validate.in index 9ac98f7..af2d186 100644 --- a/config/tools/xml/ccs_config_validate.in +++ b/config/tools/xml/ccs_config_validate.in @@ -25,14 +25,13 @@ print_usage() { echo " -V Print program version information, then exit" echo " -v Produce verbose output" echo "" - echo " -r Force validation of runtime config" - echo " -C config_loader Override config plugin loader" - echo "" echo "Validating XML configuraton files:" echo " -f configfile Validate an alternate config file" - echo " -l Do not perform load test (requires -f)" + echo " -l configfile Validate an alternate config file (load test)" echo "" - echo "Debugging options:" + echo "Advanced options:" + echo " -r Force validation of runtime config" + echo " -C config_loader Override config plugin loader" echo " -t tempfile Force temporay file to tempfile" echo " -n Do not remove temporary file" echo " -o Overwrite temporary file (dangerous)" @@ -70,19 +69,29 @@ check_opts() { exit 255 fi ;; - -f) + -l) shift COROSYNC_CLUSTER_CONFIG_FILE=$1 COROSYNC_DEFAULT_CONFIG_IFACE=xmlconfig:cmanpreconfig filetest=1 if [ -n "$loaderoverride" ] || \ - [ -n "$runtimetest" ]; then - echo "Error: invalid options. -f can not be set together with -r or -C" >&2 + [ -n "$runtimetest" ] || \ + [ -n "$noloadtest" ]; then + echo "Error: invalid options. -l can not be set together with -r or -C or -f" >&2 exit 255 fi ;; - -l) + -f) + shift + COROSYNC_CLUSTER_CONFIG_FILE=$1 + unset COROSYNC_DEFAULT_CONFIG_IFACE noloadtest=1 + if [ -n "$loaderoverride" ] || \ + [ -n "$runtimetest" ] || \ + [ -n "$filetest" ]; then + echo "Error: invalid options. -f can not be set together with -r or -C or -l" >&2 + exit 255 + fi ;; -r) unset COROSYNC_DEFAULT_CONFIG_IFACE @@ -100,12 +109,6 @@ check_opts() { esac shift done - - if [ -n "$noloadtest" ] && [ -z "$COROSYNC_CLUSTER_CONFIG_FILE" ]; then - echo "Error: -l requires -f option" >&2 - exit 255 - fi - } lecho() @@ -114,10 +117,7 @@ lecho() return 0 } -export COROSYNC_DEFAULT_CONFIG_IFACE -export COROSYNC_CLUSTER_CONFIG_FILE - -opts=$(getopt t:hVnC:f:lrov $@) +opts=$(getopt t:hVnC:f:l:rov $@) if [ "$?" != 0 ]; then print_usage >&2 exit 255
reply other threads:[~2009-09-11 7:22 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20090911072158.87034120377@lists.fedorahosted.org \ --to=fabbione@fedoraproject.org \ --cc=cluster-cvs-relay@redhat.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).