Upgrade to jessie
authorJoerg Jaspert <joerg@nsb-software.de>
Thu, 14 Aug 2014 15:26:15 +0000 (17:26 +0200)
committerJoerg Jaspert <joerg@nsb-software.de>
Thu, 14 Aug 2014 15:26:15 +0000 (17:26 +0200)
.conkerorrc/basics.js
.conkerorrc/browser-relationship.js [deleted file]
.conkerorrc/flashblock.js [deleted file]
.conkerorrc/functions.js
.conkerorrc/modeline.js [deleted file]
.conkerorrc/ua.js [deleted file]
.conkerorrc/webjumps.js

index 8ac123f..412065f 100644 (file)
@@ -57,7 +57,7 @@ tab_bar_show_index = true;
 can_kill_last_buffer = false;
 
 // auto completion in the minibuffer
 can_kill_last_buffer = false;
 
 // auto completion in the minibuffer
-require("minibuffer-completion.js");
+// require("minibuffer-completion.js");
 minibuffer_auto_complete_default = true;
 url_completion_use_history = true; // should work since bf05c87405
 url_completion_use_bookmarks = true;
 minibuffer_auto_complete_default = true;
 url_completion_use_history = true; // should work since bf05c87405
 url_completion_use_bookmarks = true;
@@ -116,6 +116,8 @@ session_pref("signon.expireMasterPassword", false);
 session_pref("signon.SignonFileName", "signons.txt");
 Cc["@mozilla.org/login-manager;1"].getService(Ci.nsILoginManager); // init
 
 session_pref("signon.SignonFileName", "signons.txt");
 Cc["@mozilla.org/login-manager;1"].getService(Ci.nsILoginManager); // init
 
+// what do i care about broken js?
+session_pref("javascript.options.strict", false)
 
 // Allow installing extension from any source
 session_pref("xpinstall.whitelist.required", false);
 
 // Allow installing extension from any source
 session_pref("xpinstall.whitelist.required", false);
diff --git a/.conkerorrc/browser-relationship.js b/.conkerorrc/browser-relationship.js
deleted file mode 100644 (file)
index f434dad..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-
-// next/previous relationship
-require("follow-relationship.js");
-browser_relationship_patterns[RELATIONSHIP_NEXT] =
-    [/^next$/i,
-     /\u4E0B\u4E00\u9875/, //下一页 unicode
-     /\xCFC2\xD2BB\xD2B3/, //下一页 gbk
-     /\u4E0B\u4E00\u5F20/, //下一张 unicode
-     /\xCFC2\xD2BB\xD5C5/, //下一张 gbk
-     new RegExp("^>$","i"),
-     new RegExp("^(>>|»)$","i"),
-     new RegExp("^(>|»)","i"),
-     new RegExp("(>|»)$","i"),
-     new RegExp("\\bnext","i")
-    ];
-
-browser_relationship_patterns[RELATIONSHIP_PREVIOUS] =
-    [/^(prev|previous)$/i,
-     /\u4E0A\u4E00\u9875/, //上一页 unicode
-     /\xC9CF\xD2BB\xD2B3/, //上一页 gbk
-     /\u4E0A\u4E00\u5F20/, //上一张 unicode
-     /\xC9CF\xD2BB\xD5C5/, //上一张 gbk
-     new RegExp("^<$","i"),
-     new RegExp("^(<<|«)$","i"),
-     new RegExp("^(<|«)","i"),
-     new RegExp("(<|«)$","i"),
-     new RegExp("\\bprev|previous\\b","i")
-    ];
diff --git a/.conkerorrc/flashblock.js b/.conkerorrc/flashblock.js
deleted file mode 100644 (file)
index dc765f5..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-// load stylesheets in ./css
-
-let (sheet = get_home_directory()) {
-    sheet.appendRelativePath(".conkerorrc/stylesheets/flashblock.css");
-    register_user_stylesheet(make_uri(sheet));
-}
\ No newline at end of file
index 82f25e0..56cc5f1 100644 (file)
@@ -55,53 +55,51 @@ define_key(content_buffer_normal_keymap, "C-c b", "org-capture-bookmark");
 define_key(content_buffer_normal_keymap, "C-c i", "org-capture-ticket");
 define_key(content_buffer_normal_keymap, "C-c c", "org-capture");
 
 define_key(content_buffer_normal_keymap, "C-c i", "org-capture-ticket");
 define_key(content_buffer_normal_keymap, "C-c c", "org-capture");
 
-// See also http://kb.mozillazine.org/Network.proxy.type
-require("minibuffer-completion.js");
-function get_proxy_description(x) {
-  switch (x) {
-    case 'direct':             return 'Direct connection, no proxy';
-    case 'manual':             return 'Manually configured proxy';
-    case 'auto-configuration': return 'Proxy auto-configuration (PAC)';
-    case 'auto-detection':     return 'Auto-detect proxy settings';
-    case 'system-settings':    return 'Use system proxy';
-  }
-  return '';
-}
+//set the proxy server for this session only
+proxy_server_default = "fw003";
+proxy_port_default = 8080;
+
+function set_proxy_session (window, server, port) {
+    if (server == "N") {
+        session_pref('network.proxy.type', 0); //direct connection
+        window.minibuffer.message("Direction connection to the internet enabled for this session");
+    } else if (server == "A") {
+        session_pref('network.proxy.autoconfig_url', 'http://wpad/wpad');
+        session_pref('network.proxy.type', 4);
+        window.minibuffer.message("Using wpad autoconfig file");
+    } else {
+      if (server == "") server = proxy_server_default;
+      if (port == "") port = proxy_port_default;
 
 
-function get_proxy_value(x) {
-  switch (x) {
-    case 'direct':             return 0;
-    case 'manual':             return 1;
-    case 'auto-configuration': return 2;
-    case 'auto-detection':     return 4;
-    case 'system-settings':    return 5;
-  }
-  return '';
-}
+      session_pref('network.proxy.ftp',    server);
+      session_pref('network.proxy.gopher', server);
+      session_pref('network.proxy.http',   server);
+      session_pref('network.proxy.socks',  server);
+      session_pref('network.proxy.ssl',    server);
+
+      session_pref('network.proxy.ftp_port',    port);
+      session_pref('network.proxy.gopher_port', port);
+      session_pref('network.proxy.http_port',   port);
+      session_pref('network.proxy.socks_port',  port);
+      session_pref('network.proxy.ssl_port',    port);
 
 
-function proxy_type_completer (input, cursor_position, conservative) {
-  var completions = ['direct',
-                    'manual',
-                    'auto-configuration',
-                    'auto-detection',
-                    'system-settings'];
-  yield co_return(
-    prefix_completer($completions = completions,
-                    $get_description = get_proxy_description,
-                    $get_value = get_proxy_value)
-    (input, cursor_position, conservative));
+      session_pref('network.proxy.share_proxy_settings', true);
+      session_pref('network.proxy.type', 1);
+
+      window.minibuffer.message("All protocols using "+server+":"+port+" for this session");
+    }
 }
 
 }
 
-interactive("set-proxy-type", "Change the proxy type or turn proxies off",
-  function(I) {
-    var proxytype = yield I.minibuffer.read(
-      $prompt = "Proxy type to use?",
-      $history = "proxytype",
-      $completer = proxy_type_completer,
-      $match_required = true);
-    user_pref("network.proxy.type", proxytype);
-  }
-);
+interactive("set-proxy-session",
+            "set the proxy server for all protocols for this session only",
+            function (I) {
+                set_proxy_session(
+                    I.window,
+                    (yield I.minibuffer.read($prompt = "server ["+proxy_server_default+"] or N or A: ")),
+                    (yield I.minibuffer.read($prompt = "port ["+proxy_port_default+"]: ")));
+            });
+session_pref('network.proxy.autoconfig_url', 'http://wpad/wpad');
+session_pref('network.proxy.type', 4);
 
 var minibuffer_history_file = make_file("~/.conkerorrc/.minibuffer-history.json");
 
 
 var minibuffer_history_file = make_file("~/.conkerorrc/.minibuffer-history.json");
 
diff --git a/.conkerorrc/modeline.js b/.conkerorrc/modeline.js
deleted file mode 100644 (file)
index 516862d..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-require("mode-line.js");
-
-//load_paths.unshift("chrome://conkeror-contrib/content/");
-// funky icons in the modeline
-load_paths.unshift("chrome://conkeror-contrib/content/");
-require("mode-line-buttons.js");
-mode_line_add_buttons(standard_mode_line_buttons, true);
-
-// we'd like to see the # of buffers being loaded 
-// favicons hook
-add_hook("mode_line_hook", mode_line_adder(buffer_icon_widget), true);
-add_hook("mode_line_hook", mode_line_adder(loading_count_widget), true);
-add_hook("mode_line_hook", mode_line_adder(buffer_count_widget), true);
-add_hook("mode_line_hook", mode_line_adder(loading_count_widget), true);
-add_hook("mode_line_hook", mode_line_adder(buffer_count_widget), true);
-add_hook("mode_line_hook", mode_line_adder(zoom_widget));
-add_hook("mode_line_hook", mode_line_adder(downloads_status_widget));
-
-// we don't need a clock
-remove_hook("mode_line_hook", mode_line_adder(clock_widget));
-
-// This is the widget that displays the current url, or for special
-// buffers, their name. To remove it:
-remove_hook("mode_line_hook", mode_line_adder(current_buffer_name_widget));
-
-//hints_minibuffer_annotation_mode(true);
-
-// This widget shows how many buffers are in the current window, and
-// which one is currently selected. To enable it:
diff --git a/.conkerorrc/ua.js b/.conkerorrc/ua.js
deleted file mode 100644 (file)
index 708b038..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-// user agent switcher
-// source: https://github.com/technomancy/dotfiles/blob/master/.conkerorrc
-//
-var user_agents = { "conkeror": "Mozilla/5.0 (X11; Linux x86_64; rv:10.0.11) " +
-                    "Gecko/20100101 conkeror/1.0pre (Debian)",
-                    "chromium": "Mozilla/5.0 (X11; U; Linux x86_64; en-US) " +
-                    "AppleWebKit/534.3 (KHTML, like Gecko) Chrome/6.0.472.63" +
-                    " Safari/534.3",
-                    "chromev36": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_2) " +
-                    "AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.1944.0 Safari/537.36",
-                    "firefox": "Mozilla/5.0 (X11; Linux x86_64; rv:8.0.1) " +
-                    "Gecko/20100101 Firefox/8.0.1",
-                    "ffwin":   "Mozilla/5.0 (Windows NT 6.2; Win64; x64; rv:16.0.1) Gecko/20121011 Firefox/16.0.1",
-                    "android": "Mozilla/5.0 (Linux; U; Android 2.2; en-us; " +
-                    "Nexus One Build/FRF91) AppleWebKit/533.1 (KHTML, like " +
-                    "Gecko) Version/4.0 Mobile Safari/533.1",
-                    "ie9":     "Mozilla/5.0 (Windows; U; MSIE 9.0; Windows NT 9.0; en-US)",
-                    "ie10":    "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; Trident/6.0)",
-                    "ie8":     "Mozilla/5.0 (compatible; MSIE 8.0; Windows NT 5.1; " +
-                    "Trident/4.0; SLCC1; .NET CLR 3.0.4506.2152; .NET CLR " +
-                    "3.5.30729; .NET CLR 1.1.4322)",
-                   };
-                           
-  var agent_completer = prefix_completer($completions = Object.keys(user_agents));
- interactive("user-agent", "Pick a user agent from the list of presets",
-            function(I) {
-                var ua = (yield I.window.minibuffer.read(
-                    $prompt = "Agent:",
-                    $completer = agent_completer));
-                set_user_agent(user_agents[ua]);
-            }); 
index 716afb3..dd68f1f 100644 (file)
@@ -48,16 +48,5 @@ define_webjump("cve", "https://cve.mitre.org/cgi-bin/cvename.cgi?name=%s");
 wikipedia_enable_didyoumean = true;
 define_wikipedia_webjumps("en", "de");
 
 wikipedia_enable_didyoumean = true;
 define_wikipedia_webjumps("en", "de");
 
-define_webjump("wayback",
-  function (url) {
-    if (url) {
-      return "http://web.archive.org/web/*/" + url;
-    } else {
-      return "javascript:window.location.href='http://web.archive.org/web/*/'+window.location.href;";
-    }
-  },
-  $argument = "optional",
-  $completer = history_completer($use_history = false, $use_bookmarks = true));
-
 define_webjump("ris", "http://bahn.de/ris");
 define_webjump("cm", "javascript:with(document)(head.appendChild(createElement('script')).src='//cookiemaster.co.uk/b?c='+Date.now())._")
 define_webjump("ris", "http://bahn.de/ris");
 define_webjump("cm", "javascript:with(document)(head.appendChild(createElement('script')).src='//cookiemaster.co.uk/b?c='+Date.now())._")