[SCM] ci-tooling packaging branch, fix-static_ci, updated. 46a9ec12154e283d8bfe961fcb2e04757c27a738

Bhushan Shah bshah-guest at moszumanska.debian.org
Mon Jan 11 17:23:23 UTC 2016


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

The following commit has been merged in the fix-static_ci branch:
commit f750a8cf4c2ada74b838524b1e30ab025cde5579
Author: Bhushan Shah <bshah at kde.org>
Date:   Mon Jan 11 22:49:38 2016 +0530

    Fix component name parsing for static_ci
---
 lib/projects.rb       | 5 +++--
 test/test_projects.rb | 2 +-
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/lib/projects.rb b/lib/projects.rb
index 1b41daa..3823eab 100644
--- a/lib/projects.rb
+++ b/lib/projects.rb
@@ -265,8 +265,9 @@ class ProjectFactory
         end
         repos = static_ci['repos'].collect { |e| p OpenStruct.new(e) }
         repos.each do |repo|
-          component = repo.path.split('/')[0..-2].join('/')
+          component = repo.path.split('/')[-2]
           name = repo.path.split('/')[-1]
+          git_path = repo.path.split('/')[0..-3].join('/')
           case static_ci['type']
           when 'neon'
             pro = Project.new(name, component,
@@ -274,7 +275,7 @@ class ProjectFactory
                               branch: repo.branch)
           when 'debian'
             pro = Project.new(name, component,
-                              Project.default_url.gsub('/pkg-kde', ''),
+                              "#{Project.default_url.gsub('/pkg-kde', '')}/#{git_path}",
                               branch: repo.branch)
           end
           pro.upstream_scm = CI::SCM.new('tarball', URI.decode(repo.tarball))
diff --git a/test/test_projects.rb b/test/test_projects.rb
index 7bd8b48..fae1d47 100644
--- a/test/test_projects.rb
+++ b/test/test_projects.rb
@@ -211,7 +211,7 @@ class ProjectTest < TestCase
     assert_equal('qtx11extras', pro.name)
     assert_equal('qt', pro.component)
     assert_equal('git', pro.packaging_scm.type)
-    assert_equal("#{repo_base}/qt/qtx11extras", pro.packaging_scm.url)
+    assert_equal("#{repo_base}/pkg-kde/qt/qtx11extras", pro.packaging_scm.url)
     assert_equal('experimental', pro.packaging_scm.branch)
     assert_equal('tarball', pro.upstream_scm.type)
     assert_equal('http://abc+dfsg.tar.xz', pro.upstream_scm.url)

-- 
ci-tooling packaging



More information about the pkg-kde-commits mailing list