From e5344317d3b69475239c4793463dceb30cbc6433 Mon Sep 17 00:00:00 2001 From: Patrick Totzke Date: Tue, 13 Dec 2011 20:18:58 +0000 Subject: added --version switch to commandline arguments --- alot/init.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'alot') diff --git a/alot/init.py b/alot/init.py index 9627370f..362fb49c 100755 --- a/alot/init.py +++ b/alot/init.py @@ -11,6 +11,7 @@ from ui import UI import alot.commands as commands from commands import * from alot.commands import CommandParseError +import alot def parse_args(): @@ -40,6 +41,8 @@ def parse_args(): parser.add_argument('command', nargs='?', default='', help='initial command') + parser.add_argument('-v', '--version', action='version', + version='%(prog)s ' + alot.__version__) return parser.parse_args() -- cgit v1.2.3