[SCM] ci-tooling packaging branch, master, updated. 460147c822261dc410d8f147c575ae9ef8d838de
Harald Sitter
apachelogger-guest at moszumanska.debian.org
Wed Oct 28 11:47:24 UTC 2015
Gitweb-URL: http://git.debian.org/?p=pkg-kde/ci-tooling.git;a=commitdiff;h=cdeb4d8
The following commit has been merged in the master branch:
commit cdeb4d8a56f08d316ffdfa81efbd1c4eb8922a08
Author: Harald Sitter <sitter at kde.org>
Date: Wed Oct 28 12:42:20 2015 +0100
add project attr packaging_scm_scm which is to replace packaging_scm
it's an SCM instance rather than just the url of the scm
---
lib/projects.rb | 9 ++++++++-
test/test_projects.rb | 4 ++++
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/lib/projects.rb b/lib/projects.rb
index 7ea4ddd..3245b6a 100644
--- a/lib/projects.rb
+++ b/lib/projects.rb
@@ -36,7 +36,13 @@ class Project
# Bool whether this project uses autopkgtest
attr_reader :autopkgtest
# String of the SCM uri
- attr_reader :packaging_scm
+ def packaging_scm
+ @packaging_scm_scm.url
+ end
+ # FIXME: deprecate, then bring back _scm_scm as _scm and deprecate _scm_scm
+ deprecate :packaging_scm, :packaging_scm_scm, 2015, 12
+ # Packaging SCM SCM instance
+ attr_reader :packaging_scm_scm
# Init
# @param name name of the project (this is equal to the name of the packaging
@@ -64,6 +70,7 @@ class Project
@autopkgtest = false
# Clean up path to remove useless slashes and colons.
@packaging_scm = Project.cleanup_uri("#{url_base}/#{component}/#{name}")
+ @packaging_scm_scm = CI::SCM.new('git', @packaging_scm, branch)
# FIXME: git dir needs to be set somewhere, somehow, somewhat, lol, kittens?
FileUtils.mkdir_p("git/#{component}") unless Dir.exist?("git/#{component}")
diff --git a/test/test_projects.rb b/test/test_projects.rb
index e7a0bf9..95095dd 100644
--- a/test/test_projects.rb
+++ b/test/test_projects.rb
@@ -79,6 +79,10 @@ class ProjectTest < TestCase
assert_equal(false, project.autopkgtest)
# FIXME: this is totally inconsistent with upstream_scm
assert_equal("#{gitrepo}/#{component}/#{name}", project.packaging_scm)
+
+ assert_equal('git', project.packaging_scm_scm.type)
+ assert_equal("#{gitrepo}/#{component}/#{name}", project.packaging_scm_scm.url)
+ assert_equal("kubuntu_#{stability}", project.packaging_scm_scm.branch)
end
ensure
FileUtils.rm_rf(tmpdir) unless tmpdir.nil?
--
ci-tooling packaging
More information about the pkg-kde-commits
mailing list