[SCM] ci-tooling packaging branch, master, updated. daaf5d5470f4736930d98e5baf38651939392e21

Rohan Garg rohangarg-guest at moszumanska.debian.org
Fri Apr 10 14:41:45 UTC 2015


Gitweb-URL: http://git.debian.org/?p=pkg-kde/ci-tooling.git;a=commitdiff;h=daaf5d5

The following commit has been merged in the master branch:
commit daaf5d5470f4736930d98e5baf38651939392e21
Author: Rohan Garg <rohan at garg.io>
Date:   Fri Apr 10 16:41:34 2015 +0200

    Use new versioning code
---
 dci/source.rb | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/dci/source.rb b/dci/source.rb
index 33e5255..5649fee 100644
--- a/dci/source.rb
+++ b/dci/source.rb
@@ -8,6 +8,7 @@ require_relative '../lib/debian/control'
 require_relative '../lib/debian/source'
 require_relative '../lib/logger'
 require_relative '../lib/dci'
+require_relative '../lib/ci/build_version'
 
 raise "No workspace dir defined!" unless ARGV[1]
 
@@ -95,10 +96,9 @@ Dir.chdir(ARGV[1]) do
   end
 
   source_name = cl.name
-  version_suffix = "+git#{DateTime.now.strftime('%Y%m%d.%H%M')}"
-  version = "#{cl.version(Changelog::EPOCH | Changelog::BASE)}#{version_suffix}" # <-- needs git version and bzr version possibly
-  tar_version = "#{cl.version(Changelog::BASE)}#{version_suffix}"
-  version += '-1' unless s.format.type == :native
+  bv = CI::BuildVersion.new(cl)
+  version = bv.full
+  version = bv.base if s.format.type == :native
 
   Dir.chdir(source_dir) do
     FileUtils.rm_rf(Dir.glob('**/.bzr'))
@@ -107,7 +107,7 @@ Dir.chdir(ARGV[1]) do
   end
 
   # create orig tar
-  tar = "#{source_name}_#{tar_version}.orig.tar"
+  tar = "#{source_name}_#{bv.tar}.orig.tar"
   File.delete(tar) if File.exist? tar
   fail 'Failed to create a tarball' unless system("tar -cf #{tar} #{source_dir}")
   fail 'Failed to compress the tarball' unless system("xz -6 #{tar}")

-- 
ci-tooling packaging



More information about the pkg-kde-commits mailing list