[gnome-ostree] builddisks: Add http://ostree.gnome.org as a remote repository by default



commit 508c1ee79c939118d07fc9babd62d3f15d563dbf
Author: Colin Walters <walters verbum org>
Date:   Wed Feb 27 10:03:53 2013 -0500

    builddisks: Add http://ostree.gnome.org as a remote repository by default
    
    That way it can be easily upgraded, etc.

 manifest.json                   |    1 +
 src/js/tasks/task-builddisks.js |    5 +++++
 2 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/manifest.json b/manifest.json
index b2ee491..13d0f40 100644
--- a/manifest.json
+++ b/manifest.json
@@ -2,6 +2,7 @@
   "00ostbuild-manifest-version": 0,
 
   "osname": "gnome-ostree",
+  "repo": "http://ostree.gnome.org/repo";,
   "prefix": "gnomeos-3.8",
   "architectures": ["x86_64"],
   "base": {
diff --git a/src/js/tasks/task-builddisks.js b/src/js/tasks/task-builddisks.js
index 950a901..0206505 100644
--- a/src/js/tasks/task-builddisks.js
+++ b/src/js/tasks/task-builddisks.js
@@ -72,6 +72,7 @@ const TaskBuildDisks = new Lang.Class({
              let targets = buildData['targets'];
 
         let osname = buildData['snapshot']['osname'];
+        let repo = buildData['snapshot']['repo'];
 
         for (let targetName in targets) {
             let targetRevision = buildData['targets'][targetName];
@@ -93,6 +94,10 @@ const TaskBuildDisks = new Lang.Class({
             try {
                 LibQA.pullDeploy(mntdir, this.repo, osname, targetName, targetRevision,
                                  cancellable);
+                if (repo)
+                    ProcUtil.runSync(['ostree', '--repo=' + 
mntdir.resolve_relative_path('ostree/repo').get_path(),
+                                      'remote', 'add', osname, repo, targetName],
+                                     cancellable, { logInitiation: true });
             } finally {
                 gfmnt.umount(cancellable);
             }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]