[gnome-ostree] ostbuild: pick manifest from config if not specified on the command line



commit 08059e4f47b9b977b76580ac584411d624c56908
Author: Giovanni Campagna <gcampagna src gnome org>
Date:   Sun Dec 30 17:30:48 2012 +0100

    ostbuild: pick manifest from config if not specified on the command line
    
    It is convenient when using ostbuild resolve manually instead of using
    the autobuilder.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=690960

 src/ostbuild/js/resolve.js |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/ostbuild/js/resolve.js b/src/ostbuild/js/resolve.js
index 2ae890d..294ad30 100644
--- a/src/ostbuild/js/resolve.js
+++ b/src/ostbuild/js/resolve.js
@@ -43,8 +43,7 @@ const Resolve = new Lang.Class({
     execute: function(argv) {
 	let cancellable = null;
         let parser = new ArgParse.ArgumentParser("Expand git revisions in source to exact targets");
-        parser.addArgument('--manifest', {required:true,
-					  help:"Path to manifest file"});
+        parser.addArgument('--manifest', {help:"Path to manifest file"});
         parser.addArgument('--fetch', {action:'storeTrue',
 					help:"Also perform a git fetch"});
         parser.addArgument('--fetch-keep-going', {action:'storeTrue',
@@ -64,6 +63,7 @@ const Resolve = new Lang.Class({
 	}
 
 	this.config = Config.get();
+        args.manifest = args.manifest || this.config.getGlobal('manifest');
 	this.workdir = Gio.File.new_for_path(this.config.getGlobal('workdir'));
         this._snapshot = JsonUtil.loadJson(Gio.File.new_for_path(args.manifest), cancellable);
 	this._mirrordir = Gio.File.new_for_path(this.config.getGlobal('mirrordir'));



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