aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorPapoteur <papoteur@mageia.org>2020-06-13 08:18:14 +0200
committerPapoteur <papoteur@mageia.org>2020-06-13 08:18:14 +0200
commit6851d7dfbf8f3adc914495649a4604b0850124eb (patch)
tree31c5cae04b4e8b13af7a06c2d93ac0d1a833d565 /lib
parent479794a7041895deeceddc4ac0ec75f117817e06 (diff)
downloadisodumper-6851d7dfbf8f3adc914495649a4604b0850124eb.tar
isodumper-6851d7dfbf8f3adc914495649a4604b0850124eb.tar.gz
isodumper-6851d7dfbf8f3adc914495649a4604b0850124eb.tar.bz2
isodumper-6851d7dfbf8f3adc914495649a4604b0850124eb.tar.xz
isodumper-6851d7dfbf8f3adc914495649a4604b0850124eb.zip
Suppress YUI log from console (mga#26681) also with the launcher
Move version in Makefile : use 'make version' to have it in lib/version.py
Diffstat (limited to 'lib')
-rwxr-xr-xlib/isodumper.py17
1 files changed, 8 insertions, 9 deletions
diff --git a/lib/isodumper.py b/lib/isodumper.py
index 984d037..b135a75 100755
--- a/lib/isodumper.py
+++ b/lib/isodumper.py
@@ -28,6 +28,10 @@
# ensure we're using the latest build, if called from our build environment
import sys
import importlib
+try:
+ from isodumper import version
+except:
+ import version
sys.path.insert(0,'../../../build/swig/python3')
importlib.reload(sys)
@@ -37,10 +41,6 @@ importlib.reload(sys)
import yui
import time
-#log = yui.YUILog.instance()
-#log.setLogFileName("isodumper.log")
-#log.enableDebugLogging( True )
-
import os
import re
import gettext
@@ -51,7 +51,6 @@ from gi.repository import GLib
import psutil
import manatools.args as args
-RELEASE="v1.17"
class NoUDisks2(Exception):
@@ -506,7 +505,7 @@ exFAT, NTFS or ext. You can specify a volume name and the format in a new dialog
"""
Init/Constructor for the 'widgets'
"""
- yui.YUI.app().setApplicationTitle(_("IsoDumper") + " " + RELEASE)
+ yui.YUI.app().setApplicationTitle(_("IsoDumper") + " " + version.RELEASE)
yui.YUI.app().setApplicationIcon("/usr/share/icons/isodumper.png")
self.atelier = yui.YUI.widgetFactory()
self.dialog = self.atelier.createPopupDialog()
@@ -679,7 +678,7 @@ exFAT, NTFS or ext. You can specify a volume name and the format in a new dialog
def aboutDialog(self):
yui.YUI.widgetFactory;
mgafactory = yui.YMGAWidgetFactory.getYMGAWidgetFactory(yui.YExternalWidgets.externalWidgetFactory("mga"))
- dlg = mgafactory.createAboutDialog("Isodumper", self.RELEASE, "GPLv2",
+ dlg = mgafactory.createAboutDialog("Isodumper", version.RELEASE, "GPLv2",
_("Oliver Grawert<BR />Papoteur<BR />Pictures : Timothée Giet"), _("A tool for writing ISO images to a device")+"<BR />http://gitweb.mageia.org/software/isodumper", "")
dlg.show();
@@ -772,10 +771,10 @@ exFAT, NTFS or ext. You can specify a volume name and the format in a new dialog
if __name__ == "__main__":
# Send the yui logging outside of the console
- yui.YUILog.setLogFileName("/dev/null")
+ log = yui.YUILog.setLogFileName("/dev/null")
parser = ParseCLI('isodumper')
if parser.args.version:
- print(RELEASE)
+ print(version.RELEASE)
else:
app = IsoDumper()
app.run()