summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorSimon MacMullen <simon@rabbitmq.com>2014-09-16 14:32:37 +0100
committerSimon MacMullen <simon@rabbitmq.com>2014-09-16 14:32:37 +0100
commita6c97140182effe407e483ff1287225d26058b36 (patch)
tree5438df3055ccef340ac95c2bfa76997fd2e30790 /include
parentf76526252d8908cb5c00cb328f00cc27e1358508 (diff)
downloadrabbitmq-server-git-a6c97140182effe407e483ff1287225d26058b36.tar.gz
Extract commonality between rabbit_control_main and rabbit_plugins_main.
Diffstat (limited to 'include')
-rw-r--r--include/rabbit_cli.hrl48
1 files changed, 48 insertions, 0 deletions
diff --git a/include/rabbit_cli.hrl b/include/rabbit_cli.hrl
new file mode 100644
index 0000000000..ddb4f4d05d
--- /dev/null
+++ b/include/rabbit_cli.hrl
@@ -0,0 +1,48 @@
+%% The contents of this file are subject to the Mozilla Public License
+%% Version 1.1 (the "License"); you may not use this file except in
+%% compliance with the License. You may obtain a copy of the License
+%% at http://www.mozilla.org/MPL/
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and
+%% limitations under the License.
+%%
+%% The Original Code is RabbitMQ.
+%%
+%% The Initial Developer of the Original Code is GoPivotal, Inc.
+%% Copyright (c) 2007-2014 GoPivotal, Inc. All rights reserved.
+%%
+
+-define(NODE_OPT, "-n").
+-define(QUIET_OPT, "-q").
+-define(VHOST_OPT, "-p").
+
+-define(VERBOSE_OPT, "-v").
+-define(MINIMAL_OPT, "-m").
+-define(ENABLED_OPT, "-E").
+-define(ENABLED_ALL_OPT, "-e").
+
+-define(PRIORITY_OPT, "--priority").
+-define(APPLY_TO_OPT, "--apply-to").
+-define(RAM_OPT, "--ram").
+-define(OFFLINE_OPT, "--offline").
+-define(ONLINE_OPT, "--online").
+
+
+-define(NODE_DEF(Node), {?NODE_OPT, {option, Node}}).
+-define(QUIET_DEF, {?QUIET_OPT, flag}).
+-define(VHOST_DEF, {?VHOST_OPT, {option, "/"}}).
+
+-define(VERBOSE_DEF, {?VERBOSE_OPT, flag}).
+-define(MINIMAL_DEF, {?MINIMAL_OPT, flag}).
+-define(ENABLED_DEF, {?ENABLED_OPT, flag}).
+-define(ENABLED_ALL_DEF, {?ENABLED_ALL_OPT, flag}).
+
+-define(PRIORITY_DEF, {?PRIORITY_OPT, {option, "0"}}).
+-define(APPLY_TO_DEF, {?APPLY_TO_OPT, {option, "all"}}).
+-define(RAM_DEF, {?RAM_OPT, flag}).
+-define(OFFLINE_DEF, {?OFFLINE_OPT, flag}).
+-define(ONLINE_DEF, {?ONLINE_OPT, flag}).
+
+-define(RPC_TIMEOUT, infinity).