changeset 18136:00cec200ec58

1. Show the usage of -m in the help message. 2. Show a helpful message if no argument is given to startup.py.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Sun, 17 Jun 2007 00:19:12 +0000
parents 5114739a4169
children 323272a9bb65 833f7cbe4f12
files libpurple/plugins/startup.py pidgin/gtkmain.c
diffstat 2 files changed, 9 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/plugins/startup.py	Sun Jun 17 00:08:13 2007 +0000
+++ b/libpurple/plugins/startup.py	Sun Jun 17 00:19:12 2007 +0000
@@ -25,6 +25,13 @@
 import dbus
 import os
 
+if len(sys.argv) == 1:
+	print "Usage:", sys.argv[0], """<purple-client> [arguments]
+
+Example:
+	""", sys.argv[0], "pidgin -d -c /my/home"
+	sys.exit(1)
+
 home = os.path.expanduser('~/.purple/')
 for arg in range(1, len(sys.argv[1:])):
 	if sys.argv[arg] == "-c":
--- a/pidgin/gtkmain.c	Sun Jun 17 00:08:13 2007 +0000
+++ b/pidgin/gtkmain.c	Sun Jun 17 00:19:12 2007 +0000
@@ -372,6 +372,7 @@
 		       "  -c, --config=DIR    use DIR for config files\n"
 		       "  -d, --debug         print debugging messages to stdout\n"
 		       "  -h, --help          display this help and exit\n"
+		       "  -m, --multiple      do not ensure single instance\n"
 		       "  -n, --nologin       don't automatically login\n"
 		       "  -l, --login[=NAME]  automatically login (optional argument NAME specifies\n"
 		       "                      account(s) to use, separated by commas)\n"
@@ -458,6 +459,7 @@
 		{"debug",    no_argument,       NULL, 'd'},
 		{"help",     no_argument,       NULL, 'h'},
 		{"login",    optional_argument, NULL, 'l'},
+		{"multiple", no_argument,       NULL, 'm'},
 		{"nologin",  no_argument,       NULL, 'n'},
 		{"session",  required_argument, NULL, 's'},
 		{"version",  no_argument,       NULL, 'v'},