[khronos-opencl-clhpp] 04/13: add script to generate upstream snapshot tarballs
Andreas Beckmann
anbe at moszumanska.debian.org
Thu Jan 25 04:35:42 UTC 2018
This is an automated email from the git hooks/post-receive script.
anbe pushed a commit to branch master
in repository khronos-opencl-clhpp.
commit 315625b1a6978b1c59c804007b9f241b48bd7c23
Author: Andreas Beckmann <anbe at debian.org>
Date: Thu Jan 25 01:01:48 2018 +0100
add script to generate upstream snapshot tarballs
---
debian/changelog | 1 +
debian/mksnapshot.sh | 18 ++++++++++++++++++
2 files changed, 19 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index e960f72..a0c6d97 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,7 @@
khronos-opencl-clhpp (2.0.10+git12-g5dd8bb9-1) UNRELEASED; urgency=medium
* New upstream snapshot. (Closes: #853474)
+ * debian/mksnapshot.sh: New script to generate upstream snapshot tarballs.
-- Andreas Beckmann <anbe at debian.org> Thu, 25 Jan 2018 00:53:08 +0100
diff --git a/debian/mksnapshot.sh b/debian/mksnapshot.sh
new file mode 100755
index 0000000..1749ca3
--- /dev/null
+++ b/debian/mksnapshot.sh
@@ -0,0 +1,18 @@
+#!/bin/sh
+set -e
+
+# creates an upstream snapshot tarball
+# run from within the upstream git repository
+
+commit=${1:-HEAD}
+describe=$(git describe --long --tags ${commit})
+ver=${describe%%-*}
+gitsuffix=${describe#*-}
+
+base=OpenCL-CLHPP-${ver#v}+git${gitsuffix}
+tarball=${base}.tar.xz
+
+git archive --prefix ${base}/ ${commit} | xz > ${tarball}
+touch -d "@$(git log -1 --format=format:%ct ${commit})" ${tarball}
+
+echo "Generated snapshot of ${commit} in ${tarball}"
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-opencl/khronos-opencl-clhpp.git
More information about the Pkg-opencl-commits
mailing list