diff --git a/gitso/trunk/ArgsParser.py b/gitso/trunk/ArgsParser.py index 85b65d1..3c6f648 100644 --- a/gitso/trunk/ArgsParser.py +++ b/gitso/trunk/ArgsParser.py @@ -23,12 +23,11 @@ You should have received a copy of the GNU General Public License along with Gitso. If not, see . """ -# import os, sys, signal, os.path, urllib import os import sys import signal import os.path -#import urllib +import urllib class ArgsParser: def __init__(self): @@ -54,7 +53,12 @@ class ArgsParser: #for i in range(1, len(sys.argv)): i = 1 while i < len(sys.argv): - if sys.argv[i] == '--dev': # --dev + if sys.argv[i] == '--help': # --help + self.HelpMenu() + elif sys.argv[i] == '--version': # --version + print "Gitso 0.6 -- Copyright 2007 - 2009 Aaron Gerber and Derek Buranen." + exit(0) + elif sys.argv[i] == '--dev': # --dev print "Running in 'Development Mode'" self.paths['mode'] = 'dev' if sys.platform == "darwin": @@ -129,11 +133,12 @@ class ArgsParser: print "Usage: " + os.path.basename(sys.argv[0]) + " [OPTION]" print " OPTIONS" print " --dev\t\tSet self.paths for development." - print " --listen\t\tlisten for incoming connections." + print " --listen\t\tListen for incoming connections." print " --connect {IP|DN}\tConnects to host (support giver)." print " --list {URL|FILE}\tAlternative Support list." + print " --version\t\tThe current Gitso version." print " --help\t\tThis Menu." - exit(0) + exit(1) def GetPaths(self): return self.paths diff --git a/gitso/trunk/arch/linux/gitso.1 b/gitso/trunk/arch/linux/gitso.1 index ce144bd..4fcc719 100644 --- a/gitso/trunk/arch/linux/gitso.1 +++ b/gitso/trunk/arch/linux/gitso.1 @@ -14,6 +14,8 @@ gitso - Gitso is to support others .B --list .I list | +.B --version +| .B --help ] .SH DESCRIPTION @@ -36,6 +38,9 @@ Alternative support list, where .I list is either a URL of a remote file or path to local file. .TP +.B --version +The current Gitso version. +.TP .B --help Display the help menu. @@ -45,7 +50,7 @@ Display the help menu. .SH EXAMPLES .TP -gitso --list support.mydomain.com/techs.txt +gitso --list http://support.mydomain.com/techs.txt Gets the list of technician IP's or DN's from techs.txt .TP gitso --list sanda.mydomain.com,aicha.mydomain.com