File: avoid_gitarchive.patch

package info (click to toggle)
pyobjcryst 2024.2.1-3
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 8,016 kB
  • sloc: cpp: 5,824; python: 3,423; makefile: 17; sh: 6
file content (33 lines) | stat: -rw-r--r-- 1,035 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
From: "codehelp@debian.org" <codehelp@debian.org>
Date: Wed, 26 Jan 2022 14:05:39 +0000
Subject: Allow version to be retrieved inside the packaging

 gitarchive is confused by this .git not being the upstream
 repository.
---
 setup.py | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/setup.py b/setup.py
index f5fd19e..3aaea3e 100644
--- a/setup.py
+++ b/setup.py
@@ -127,12 +127,12 @@ def getversioncfg():
         if mx:
             g['version'] = mx.group(1)
     # then try to obtain version data from git.
-    gitdir = os.path.join(MYDIR, '.git')
-    if os.path.exists(gitdir) or 'GIT_DIR' in os.environ:
-        try:
-            g = gitinfo()
-        except OSError:
-            pass
+#    gitdir = os.path.join(MYDIR, '.git')
+#    if os.path.exists(gitdir) or 'GIT_DIR' in os.environ:
+#        try:
+#            g = gitinfo()
+#        except OSError:
+#            pass
     # finally, check and update the active version file
     cp = RawConfigParser()
     cp.read(versioncfgfile)