]> git.armaanb.net Git - chorizo.git/commitdiff
Remove $LARIZA_WEB_EXTENSIONS_DIR
authorPeter Hofmann <scm@uninformativ.de>
Sat, 28 Nov 2015 18:58:47 +0000 (19:58 +0100)
committerPeter Hofmann <scm@uninformativ.de>
Sat, 28 Nov 2015 19:03:29 +0000 (20:03 +0100)
For the sake of consistency. There is no reason why this particular
directory can be configured at runtime.

browser.c
man1/lariza.1

index f4afc45e150be6df18e38578cb8cd063d723cee2..427424951457d385915fb84223cf9cc08172f5fa 100644 (file)
--- a/browser.c
+++ b/browser.c
@@ -79,7 +79,6 @@ static GHashTable *keywords = NULL;
 static gchar *search_text = NULL;
 static gboolean tabbed_automagic = TRUE;
 static gchar *user_agent = NULL;
-static gchar *web_extensions_dir = NULL;
 
 
 void
@@ -526,13 +525,6 @@ grab_environment_configuration(void)
     if (e != NULL)
         user_agent = g_strdup(e);
 
-    e = g_getenv(__NAME_UPPERCASE__"_WEB_EXTENSIONS_DIR");
-    if (e != NULL)
-        web_extensions_dir = g_strdup(e);
-    else
-        web_extensions_dir = g_build_filename(g_get_user_data_dir(), __NAME__,
-                                              "web_extensions", NULL);
-
     e = g_getenv(__NAME_UPPERCASE__"_ZOOM");
     if (e != NULL)
         global_zoom = atof(e);
@@ -920,6 +912,7 @@ trust_user_certs(WebKitWebContext *wc)
 int
 main(int argc, char **argv)
 {
+    gchar *c;
     int opt, i;
 
     gtk_init(&argc, &argv);
@@ -955,8 +948,13 @@ main(int argc, char **argv)
         embed = tabbed_launch();
 
     if (!cooperative_instances || cooperative_alone)
-        webkit_web_context_set_web_extensions_directory(webkit_web_context_get_default(),
-                                                        web_extensions_dir);
+    {
+        c = g_build_filename(g_get_user_data_dir(), __NAME__, "web_extensions",
+                             NULL);
+        webkit_web_context_set_web_extensions_directory(
+            webkit_web_context_get_default(), c
+        );
+    }
 
     if (optind >= argc)
         client_new(home_uri);
index a8f504eaf752ea3c238d8fe1fd1a3b7a5514b5a3..2440d0eda61801a62808b9bf5e457b618845e2bc 100644 (file)
@@ -82,10 +82,6 @@ the command line. Defaults to \fBabout:blank\fP.
 \fBlariza\fP will identify itself with this string. Uses WebKit's
 default value if unset.
 .TP
-\fBLARIZA_WEB_EXTENSIONS_DIR\fP
-Sets the directory where WebKit will look for \fBweb extensions\fP.
-Defaults to \fI~/.local\:/share\:/lariza\:/web_extensions\fP.
-.TP
 \fBLARIZA_ZOOM
 Zoom level for WebKit viewports. Defaults to \fB1.0\fP.
 .\" --------------------------------------------------------------------
@@ -101,6 +97,10 @@ Directory where trusted certificates are stored. See
 \fI~/.config\:/lariza\:/keywordsearch\fP
 Configuration file for keyword base searching. See
 \fBlariza.usage\fP(1).
+.TP
+\fI~/.local\:/share\:/lariza\:/web_extensions\fP
+Sets the directory where WebKit will look for web extensions. See
+\fBlariza.usage\fP(1).
 .\" --------------------------------------------------------------------
 .SH LICENSE
 \fBlariza\fP is released as \(lqPIZZA-WARE\(rq. See the accompanying