Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/gajim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xlaunch.py14
1 files changed, 6 insertions, 8 deletions
diff --git a/launch.py b/launch.py
index 27558784a..e5757eace 100755
--- a/launch.py
+++ b/launch.py
@@ -2,16 +2,14 @@
import subprocess
-from gajim import gajim
+import gajim
+from gajim.gajim import main
try:
- p = subprocess.Popen('git rev-parse --short=12 HEAD', shell=True,
- stdout=subprocess.PIPE, stderr=subprocess.DEVNULL)
- node = p.communicate()[0]
- if node:
- import gajim as g
- g.__version__ += '+' + node.decode('utf-8').strip()
+ res = subprocess.check_output(
+ ['git', 'rev-parse', '--short=12', 'HEAD']) # noqa: S603, S607
+ gajim.__version__ += f'+{res.decode().strip()}'
except Exception:
pass
-gajim.main()
+main()