aboutsummaryrefslogtreecommitdiffstats
path: root/scudcloud-1.0/scudcloud
diff options
context:
space:
mode:
authorRael <rael.gc@gmail.com>2015-10-22 15:58:19 -0200
committerRael <rael.gc@gmail.com>2015-10-22 15:58:19 -0200
commiteabe4af0a34f5535806f0ea0dbbe04c5e53d79aa (patch)
tree8b535f26750948a226137348527312b1bbaf3e8a /scudcloud-1.0/scudcloud
parent72c66cc6cf0857eec5c63a41aff87a183c2aa938 (diff)
downloadscudcloud-eabe4af0a34f5535806f0ea0dbbe04c5e53d79aa.zip
scudcloud-eabe4af0a34f5535806f0ea0dbbe04c5e53d79aa.tar.gz
scudcloud-eabe4af0a34f5535806f0ea0dbbe04c5e53d79aa.tar.bz2
Moving version info to external file
Diffstat (limited to 'scudcloud-1.0/scudcloud')
-rwxr-xr-xscudcloud-1.0/scudcloud7
1 files changed, 3 insertions, 4 deletions
diff --git a/scudcloud-1.0/scudcloud b/scudcloud-1.0/scudcloud
index 6b7498f..734350c 100755
--- a/scudcloud-1.0/scudcloud
+++ b/scudcloud-1.0/scudcloud
@@ -14,12 +14,11 @@ from scudcloud import ScudCloud
# The ScudCloud QMainWindow
win = None
-VERSION = '1.0.85'
-
def main():
global win
Resources.INSTALL_DIR = INSTALL_DIR
signal.signal(signal.SIGINT, exit)
+ args = parse_arguments()
appKey = "scudcloud.pid"
socket = QLocalSocket()
socket.connectToServer(appKey)
@@ -31,7 +30,6 @@ def main():
app = QtGui.QApplication(sys.argv)
app.setApplicationName(Resources.APP_NAME)
app.setWindowIcon(QtGui.QIcon(Resources.get_path('scudcloud.png')))
- args = parse_arguments()
ScudCloud.debug = args.debug
ScudCloud.minimized = True if args.minimized is True else None
ScudCloud.plugins = False if args.no_plugins is True else True
@@ -79,7 +77,8 @@ def parse_arguments():
parser.add_argument('--version', action="store_true", help="print version and exit")
args = parser.parse_args()
if args.version:
- print("ScudCloud "+VERSION)
+ with open(os.path.join(Resources.INSTALL_DIR, 'VERSION'), "r") as f:
+ print("ScudCloud "+f.read())
sys.exit()
args.confdir = expanduser(args.confdir)
return args