Skip to content
Snippets Groups Projects
Commit e6efcebf authored by Yann Leboulanger's avatar Yann Leboulanger
Browse files

add -c option to history_manager. Fixes #5058

parent 5a72c9b3
No related branches found
No related tags found
No related merge requests found
......@@ -53,9 +53,34 @@ import gobject
import time
import locale
import getopt
from common import i18n
def parseOpts():
config_path = None
try:
shortargs = 'hc:'
longargs = 'help config_path='
opts = getopt.getopt(sys.argv[1:], shortargs, longargs.split())[0]
except getopt.error, msg:
print str(msg)
print 'for help use --help'
sys.exit(2)
for o, a in opts:
if o in ('-h', '--help'):
print 'history_manager [--help] [--config-path]'
sys.exit()
elif o in ('-c', '--config-path'):
config_path = a
return config_path
config_path = parseOpts()
del parseOpts
import common.configpaths
common.configpaths.gajimpaths.init()
common.configpaths.gajimpaths.init(config_path)
del config_path
common.configpaths.gajimpaths.init_profile()
from common import exceptions
import dialogs
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment