about summary refs log tree commit diff stats
path: root/src
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2012-11-11 19:32:42 +0000
committerJames Booth <boothj5@gmail.com>2012-11-11 19:32:42 +0000
commit07d624c51309f8a1fc7551f98f501852336541da (patch)
tree2113f743ba63c7286a019ccc077b1ba0752d0425 /src
parenta5983cacb0234b300bbf5c69684d08de36b306c1 (diff)
downloadprofani-tty-07d624c51309f8a1fc7551f98f501852336541da.tar.gz
Shortened /sub "request" parameter to "req", and formatted help
Diffstat (limited to 'src')
-rw-r--r--src/command.c22
-rw-r--r--src/windows.c2
2 files changed, 12 insertions, 12 deletions
diff --git a/src/command.c b/src/command.c
index 3f2f2e10..89e8645e 100644
--- a/src/command.c
+++ b/src/command.c
@@ -201,14 +201,14 @@ static struct cmd_t main_commands[] =
 
     { "/sub",
         _cmd_sub,
-        { "/sub <add|del|request|show> [jid]", "Manage subscriptions.",
-        { "/sub <add|del|request|show> [jid]",
-          "------------------",
-          "add     : Approve subscription to a contact.",
-          "del     : Remove subscription for a contact.",
-          "request : Send a subscription request to the user to be informed of their",
-          "        : presence.",
-          "show    : Show subscriprion status for a contact.",
+        { "/sub <add|del|req|show> [jid]", "Manage subscriptions.",
+        { "/sub <add|del|req|show> [jid]",
+          "-----------------------------",
+          "add  : Approve subscription to a contact.",
+          "del  : Remove subscription for a contact.",
+          "req  : Send a subscription request to the user to be informed of their",
+          "     : presence.",
+          "show : Show subscriprion status for a contact.",
           "",
           "If optional parameter 'jid' isn't set command belongs to the current window.",
           "",
@@ -393,7 +393,7 @@ static struct cmd_t setting_commands[] =
         _cmd_set_history,
         { "/history on|off", "Chat history in message windows.",
         { "/history on|off",
-          "-------------",
+          "---------------",
           "Switch chat history on or off, requires chlog to be enabled.",
           "When history is enabled, previous messages are shown in chat windows.",
           "The last day of messages are shown, or if you have had profanity open",
@@ -497,7 +497,7 @@ cmd_init(void)
     sub_ac = p_autocomplete_new();
     p_autocomplete_add(sub_ac, strdup("add"));
     p_autocomplete_add(sub_ac, strdup("del"));
-    p_autocomplete_add(sub_ac, strdup("request"));
+    p_autocomplete_add(sub_ac, strdup("req"));
     p_autocomplete_add(sub_ac, strdup("show"));
 
     unsigned int i;
@@ -829,7 +829,7 @@ _cmd_sub(const char * const inp, struct cmd_help_t help)
             jabber_subscription(bare_jid, PRESENCE_UNSUBSCRIBED);
             cons_show("Deleted subscription for %s", bare_jid);
             log_info("Deleted subscription for %s", bare_jid);
-        } else if (strcmp(subcmd, "request") == 0) {
+        } else if (strcmp(subcmd, "req") == 0) {
             jabber_subscription(bare_jid, PRESENCE_SUBSCRIBE);
             cons_show("Sent subscription request to %s.", bare_jid);
             log_info("Sent subscription request to %s.", bare_jid);
diff --git a/src/windows.c b/src/windows.c
index c608e0ca..7b6d7267 100644
--- a/src/windows.c
+++ b/src/windows.c
@@ -926,7 +926,7 @@ _cons_show_basic_help(void)
     GSList *basic_helpers = cmd_get_basic_help();
     while (basic_helpers != NULL) {
         struct cmd_help_t *help = (struct cmd_help_t *)basic_helpers->data;
-        cons_show("%-25s: %s", help->usage, help->short_help);
+        cons_show("%-30s: %s", help->usage, help->short_help);
         basic_helpers = g_slist_next(basic_helpers);
     }