[polari/wip/dmoelgaard/initial-setup: 4/4] app: Add a way to force running initial setup



commit 99dd24b05a2ee1efea40e0bb2dd5f7aa49c24a6c
Author: Florian Müllner <fmuellner gnome org>
Date:   Fri Aug 11 00:20:47 2017 +0200

    app: Add a way to force running initial setup
    
    We only run initial setup once, and only for new users that haven't set
    up any channels before. As recreating those conditions for testing is
    quite tedious, allow to force running setup via an environment variable.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=772458

 src/application.js |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/application.js b/src/application.js
index e2bc207..354db90 100644
--- a/src/application.js
+++ b/src/application.js
@@ -430,6 +430,11 @@ var Application = new Lang.Class({
     },
 
     _needsInitialSetup: function() {
+        if (GLib.getenv('POLARI_FORCE_INITIAL_SETUP')) {
+            GLib.unsetenv('POLARI_FORCE_INITIAL_SETUP');
+            return true;
+        }
+
         let f = Gio.File.new_for_path(GLib.get_user_cache_dir() +
                                       '/polari/initial-setup-completed');
         try {


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