[med-svn] [Git][med-team/bcbio][master] 2 commits: Avoid calling Git - use Debian version to specify the code version

Andreas Tille gitlab at salsa.debian.org
Fri Nov 6 10:23:01 GMT 2020



Andreas Tille pushed to branch master at Debian Med / bcbio


Commits:
6425cf52 by Andreas Tille at 2020-11-06T11:15:37+01:00
Avoid calling Git - use Debian version to specify the code version

- - - - -
af46d814 by Andreas Tille at 2020-11-06T11:19:55+01:00
routine-update: Ready to upload to unstable

- - - - -


3 changed files:

- debian/changelog
- + debian/patches/do_not_use_git.patch
- debian/patches/series


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,11 @@
+bcbio (1.2.4-2) unstable; urgency=medium
+
+  * Team upload.
+  * Avoid calling Git - use Debian version to specify the code version
+    Closes: #973804
+
+ -- Andreas Tille <tille at debian.org>  Fri, 06 Nov 2020 11:16:33 +0100
+
 bcbio (1.2.4-1) unstable; urgency=medium
 
   * New upstream version


=====================================
debian/patches/do_not_use_git.patch
=====================================
@@ -0,0 +1,39 @@
+Author: Andreas Tille <tille at debian.org>
+Last-Update: Fri, 06 Nov 2020 11:09:40 +0100
+Bug-Debian: https://bugs.debian.org/973804
+Description: Avoid calling Git - use Debian version to specify the code version
+Bug-Debian: https://bugs.debian.org/973804
+
+--- a/setup.py
++++ b/setup.py
+@@ -11,7 +11,7 @@ VERSION = '1.2.4'
+ 
+ # add bcbio version number and git commit hash of the current revision to version.py
+ try:
+-    git_run = subprocess.run(['git', 'rev-parse', '--short', 'HEAD'], stdout=subprocess.PIPE)
++    git_run = subprocess.run(['dpkg-parsechangelog', '-SVersion'], stdout=subprocess.PIPE)
+     git_run.check_returncode()
+ except subprocess.SubprocessError:
+     commit_hash = ''
+@@ -21,7 +21,7 @@ else:
+ here = os.path.dirname(os.path.abspath(__file__))
+ with open(os.path.join(here, 'bcbio', 'pipeline', 'version.py'), 'w') as version_file:
+     version_file.writelines([f'__version__ = "{VERSION}"\n',
+-                             f'__git_revision__ = "{commit_hash}"\n'])
++                             f'__debian_revision__ = "{commit_hash}"\n'])
+ 
+ # dependencies are installed via Conda from
+ # https://github.com/chapmanb/cloudbiolinux/blob/master/contrib/flavor/ngs_pipeline_minimal/packages-conda.yaml
+--- a/bcbio/provenance/programs.py
++++ b/bcbio/provenance/programs.py
+@@ -147,8 +147,8 @@ def _get_versions(config=None):
+     try:
+         from bcbio.pipeline import version
+         if hasattr(version, "__version__"):
+-            bcbio_version = ("%s-%s" % (version.__version__, version.__git_revision__)
+-                             if version.__git_revision__ else version.__version__)
++            bcbio_version = ("%s-%s" % (version.__version__, version.__debian_revision__)
++                             if version.__debian_revision__ else version.__version__)
+         else:
+             bcbio_version = ""
+     except ImportError:


=====================================
debian/patches/series
=====================================
@@ -1,3 +1,4 @@
 #spelling
 include_tests
 #add_installed_dir_paths.patch
+do_not_use_git.patch



View it on GitLab: https://salsa.debian.org/med-team/bcbio/-/compare/83db5e8f405d4b774235f814a7edbd6020aa15aa...af46d81468e074a16cc2d7124a6bdea9bbb19067

-- 
View it on GitLab: https://salsa.debian.org/med-team/bcbio/-/compare/83db5e8f405d4b774235f814a7edbd6020aa15aa...af46d81468e074a16cc2d7124a6bdea9bbb19067
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20201106/99b97475/attachment-0001.html>


More information about the debian-med-commit mailing list