[ostree] ostbuild: Change metadata keys for artifacts
- From: Colin Walters <walters src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ostree] ostbuild: Change metadata keys for artifacts
- Date: Tue, 13 Mar 2012 14:41:15 +0000 (UTC)
commit 6890444f28aedace99a58f55b02efbd5d0b6465d
Author: Colin Walters <walters verbum org>
Date: Mon Feb 27 19:29:33 2012 -0500
ostbuild: Change metadata keys for artifacts
"ostbuild-name" is important to tie back in to the snapshot.
"ostbuild-revision" is shorter than ostbuild-artifact-version.
src/ostbuild/pyostbuild/builtin_build.py | 11 +++--------
1 files changed, 3 insertions(+), 8 deletions(-)
---
diff --git a/src/ostbuild/pyostbuild/builtin_build.py b/src/ostbuild/pyostbuild/builtin_build.py
index 3497b78..de045fd 100755
--- a/src/ostbuild/pyostbuild/builtin_build.py
+++ b/src/ostbuild/pyostbuild/builtin_build.py
@@ -116,7 +116,7 @@ class OstbuildBuild(builtins.Builtin):
log("Previous build of '%s' is %s" % (buildname, previous_build_version))
previous_vcs_version = run_sync_get_output(['ostree', '--repo=' + self.repo,
- 'show', '--print-metadata-key=ostbuild-artifact-version',
+ 'show', '--print-metadata-key=ostbuild-revision',
previous_build_version])
previous_vcs_version = previous_vcs_version.strip()
@@ -167,15 +167,10 @@ class OstbuildBuild(builtins.Builtin):
else:
run_sync_monitor_log_file(chroot_args, log_path, cwd=component_src)
- # Reread metadata to get buildroot version
- f = open(metadata_path)
- artifact_meta = json.load(f)
- f.close()
-
args = ['ostree', '--repo=' + self.repo,
'commit', '-b', buildname, '-s', 'Build',
- '--add-metadata-string=ostbuild-buildroot-version=' + artifact_meta['buildroot-version'],
- '--add-metadata-string=ostbuild-artifact-version=' + artifact_meta['revision'],
+ '--add-metadata-string=ostbuild-name=' + artifact_meta['name'],
+ '--add-metadata-string=ostbuild-revision=' + artifact_meta['revision'],
'--owner-uid=0', '--owner-gid=0', '--no-xattrs',
'--skip-if-unchanged']
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]