From 720c685868e8f76ccdf86685a0239267faa0bfbd Mon Sep 17 00:00:00 2001 From: Marcus Huewe Date: Thu, 6 Mar 2014 10:24:49 +0100 Subject: [PATCH] - core.Package.commit: make sure a _meta is created for newly added packages Fixed typo (introduced in commit 6469efb9eded4d378fa9282dd9cc447f11bf2b97). --- osc/core.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/osc/core.py b/osc/core.py index a35e713a..c70f171c 100644 --- a/osc/core.py +++ b/osc/core.py @@ -1453,6 +1453,10 @@ class Package: print('') rev = self.latest_rev() self.update(rev=rev) + elif self.get_local_meta() is None: + # if this was a newly added package there is no _meta + # file + self.update_local_pacmeta() def __write_storelist(self, name, data): if len(data) == 0: @@ -1565,7 +1569,7 @@ class Package: # that the origin project is equal to the wc's project meta = self.get_local_meta() if meta is None: - return self.project + return self.prjname root = ET.fromstring(meta) return root.get('project')