From jjfoerch at earthlink.net Sun Feb 1 19:11:17 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sun, 01 Feb 2009 22:11:17 -0500 Subject: [Conkeror] Problems with all save commands References: <87wsd1a156.fsf@earthlink.net> Message-ID: <87d4e15y96.fsf@earthlink.net> Update on this bug.. I'm still working on the fix for this, but here is a work-around that you can put in your rc, and still run the current version of conkeror: /* * Temporary work-around for cwd bug */ default_directory = get_home_directory(); add_hook("create_buffer_hook", function (buf) { buf.configuration.cwd = null; }); Thanks for your patience, -- John Foerch From levy at msri.org Mon Feb 2 02:28:22 2009 From: levy at msri.org (Silvio Levy) Date: Mon, 02 Feb 2009 02:28:22 -0800 Subject: [Conkeror] How can I control pdf file viewing? In-Reply-To: Your message of Fri, 30 Jan 2009 15:03:29 -0500 Message-ID: <20090202102822.CBBDADFC2@xi.msri.org> Hi, I've poked around a bit but haven't found the answer: Currently, when I click a pdf link, I get an instance of acroread in the same tab as the parent page. I'd like to change this in two ways: (1) xpdf should be used instead of acroread (2) a separate window should appear, preferably an xpdf window but a conkeror window would also be ok. If either of these is not possible, I'd like to have conkeror save instead of open each pdf file (with or without asking first). Note that I have download_buffer_automatic_open_target=OPEN_NEW_BUFFER because I want download windows (for movies and other long downloads) not to clutter the screen, but I need to view pdfs on a separate window from the browser. Thanks, Silvio From artagnon at gmail.com Mon Feb 2 02:42:37 2009 From: artagnon at gmail.com (Ramkumar R) Date: Mon, 2 Feb 2009 16:12:37 +0530 Subject: [Conkeror] Feature request: Undo Message-ID: Vimperator implements a very useful feature called 'undo' which simply re-opens a previously closed tab. How should I get started on implementing this feature in Conkeror? From nick at servo.cc Mon Feb 2 06:31:39 2009 From: nick at servo.cc (Nicholas A. Zigarovich) Date: Mon, 02 Feb 2009 09:31:39 -0500 Subject: [Conkeror] How can I control pdf file viewing? In-Reply-To: <20090202102822.CBBDADFC2@xi.msri.org> References: <20090202102822.CBBDADFC2@xi.msri.org> Message-ID: <498703CB.6010605@servo.cc> Silvio Levy wrote: > Hi, I've poked around a bit but haven't found the answer: > > Currently, when I click a pdf link, I get an instance of acroread in > the same tab as the parent page. I'd like to change this in two ways: > > (1) xpdf should be used instead of acroread > (2) a separate window should appear, preferably an xpdf window but a > conkeror window would also be ok. > > If either of these is not possible, I'd like to have conkeror save > instead of open each pdf file (with or without asking first). > > Note that I have download_buffer_automatic_open_target=OPEN_NEW_BUFFER > because I want download windows (for movies and other long downloads) > not to clutter the screen, but I need to view pdfs on a separate > window from the browser. > > Thanks, > > Silvio > > > _______________________________________________ > Conkeror mailing list > Conkeror at mozdev.org > https://www.mozdev.org/mailman/listinfo/conkeror > Silvio, You need to disable the Adobe Reader plugin to prevent it from viewing PDFs inside Conkeror. Type M-x extensions to open the extensions manager, select plugins, select Adobe Reader, and click disable. See the following page to learn how to make xpdf the default action for application/pdf: http://conkeror.org/MimeTypeHandlers Cheers, - Nick From nick at servo.cc Mon Feb 2 07:17:50 2009 From: nick at servo.cc (Nicholas A. Zigarovich) Date: Mon, 02 Feb 2009 10:17:50 -0500 Subject: [Conkeror] Feature request: Undo In-Reply-To: References: Message-ID: <49870E9E.9070502@servo.cc> Ramkumar R wrote: > Vimperator implements a very useful feature called 'undo' which simply > re-opens a previously closed tab. How should I get started on > implementing this feature in Conkeror? The ability to recover closed tabs is a feature of Firefox which Vimperator leverages. modules/buffer.js and modules/window.js are good places to start. Tentatively, I'd say it doesn't look too painful to implement. Cheers, - Nick From its.sec at gmx.net Tue Feb 3 13:50:35 2009 From: its.sec at gmx.net (Tom Rauchenwald) Date: Tue, 03 Feb 2009 22:50:35 +0100 Subject: [Conkeror] fix for reddit.js Message-ID: <871vufrxzo.fsf@sec.modprobe.de> Hi, I took a quick look at reddit.js and put a fix together.. I don't have time to test it properly, but it seems to work for me. If anyone could test it i'd be thankful. Thanks, Tom diff --git a/modules/page-modes/reddit.js b/modules/page-modes/reddit.js index e299629..1cd0e98 100644 --- a/modules/page-modes/reddit.js +++ b/modules/page-modes/reddit.js @@ -59,10 +59,9 @@ function reddit_mode_setup(buffer) { // Get all divs that have a id that starts with "thingrow" var links = siteTable.getElementsByTagName("div"); links = Array.filter(links, function (element) { - var start = element.id.substr(0, 12); - if (start === "thingrow_t3_") { - - element.articleId = element.id.substr(12, element.id.length-12); + var start = element.className.substr(0, 12); + if (start === "thing id-t3_") { + element.articleId = element.className.substr(12, 5); element.highlighted = false; if(element.style.backgroundColor == "") element.originalBackgroundColor = "transparent"; From jjfoerch at earthlink.net Tue Feb 3 14:15:03 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Tue, 03 Feb 2009 17:15:03 -0500 Subject: [Conkeror] fix for reddit.js References: <871vufrxzo.fsf@sec.modprobe.de> Message-ID: <878won5frs.fsf@earthlink.net> > Hi, > > I took a quick look at reddit.js and put a fix together.. I don't have > time to test it properly, but it seems to work for me. > > If anyone could test it i'd be thankful. > > Thanks, > Tom Thank you. Works great. Applied. Any idea why the bindings , and . don't work, and what they are supposed to do? -- John Foerch From aditya.siram at gmail.com Wed Feb 4 12:03:25 2009 From: aditya.siram at gmail.com (aditya siram) Date: Wed, 4 Feb 2009 14:03:25 -0600 Subject: [Conkeror] Copy-Paste on a Mac Message-ID: <594f78210902041203m66d8f305p776c16adb7f7ab63@mail.gmail.com> Hi all, How do I copy-paste from/to conkeror on Mac OSX? Command-C doesn't work for copying and there is no 'Edit' menu. This is a new platform for me so pardon the ignorance. I'm sure this has been asked before but it isn't in the FAQ's and Google search didn't turn up much. -deech -------------- next part -------------- An HTML attachment was scrubbed... URL: From deniz.a.m.dogan at gmail.com Wed Feb 4 12:08:10 2009 From: deniz.a.m.dogan at gmail.com (Deniz Dogan) Date: Wed, 4 Feb 2009 21:08:10 +0100 Subject: [Conkeror] Copy-Paste on a Mac In-Reply-To: <594f78210902041203m66d8f305p776c16adb7f7ab63@mail.gmail.com> References: <594f78210902041203m66d8f305p776c16adb7f7ab63@mail.gmail.com> Message-ID: <7b501d5c0902041208p3d5de44ekc1c9dbf470e67ed9@mail.gmail.com> 2009/2/4 aditya siram : > Hi all, > How do I copy-paste from/to conkeror on Mac OSX? Command-C doesn't work for > copying and there is no 'Edit' menu. This is a new platform for me so pardon > the ignorance. > I'm sure this has been asked before but it isn't in the FAQ's and Google > search didn't turn up much. > > -deech Hi, and welcome to Conkeror! :) Conkeror has been quite inspired by Emacs in its keybindings. You copy text using M-w and "paste" it using C-y. Cut text with C-w. Hope that helps! Deniz From brian at microcomaustralia.com.au Wed Feb 4 15:11:26 2009 From: brian at microcomaustralia.com.au (Brian May) Date: Thu, 05 Feb 2009 10:11:26 +1100 Subject: [Conkeror] Copy-Paste on a Mac In-Reply-To: <7b501d5c0902041208p3d5de44ekc1c9dbf470e67ed9@mail.gmail.com> References: <594f78210902041203m66d8f305p776c16adb7f7ab63@mail.gmail.com> <7b501d5c0902041208p3d5de44ekc1c9dbf470e67ed9@mail.gmail.com> Message-ID: <498A209E.4060400@microcomaustralia.com.au> Deniz Dogan wrote: > Conkeror has been quite inspired by Emacs in its keybindings. You copy > text using M-w and "paste" it using C-y. Cut text with C-w. Hope that > helps! > Just remember not to use C-w with other programs. It usually means "close window" - Firefox doesn't even ask for confirmation, so you automagically lose everything you were typing. (Been there - done that - repeatedly - even after I worked why Firefox kept "Crashing"!) -- Brian May From tim at we-are-teh-b.org Wed Feb 4 15:37:37 2009 From: tim at we-are-teh-b.org (Tim Schumacher) Date: Thu, 05 Feb 2009 00:37:37 +0100 Subject: [Conkeror] Copy-Paste on a Mac In-Reply-To: <498A209E.4060400@microcomaustralia.com.au> References: <594f78210902041203m66d8f305p776c16adb7f7ab63@mail.gmail.com> <7b501d5c0902041208p3d5de44ekc1c9dbf470e67ed9@mail.gmail.com> <498A209E.4060400@microcomaustralia.com.au> Message-ID: <873aet3ha6.wl%tim@we-are-teh-b.org> At Thu, 05 Feb 2009 10:11:26 +1100, Brian May wrote: > Just remember not to use C-w with other programs. It usually means > "close window" - Firefox doesn't even ask for confirmation, so you > automagically lose everything you were typing. > > (Been there - done that - repeatedly - even after I worked why Firefox > kept "Crashing"!) To prevent this, install the firemacs extension, which does a very nice job to integrate emacs keybindings into firefox. HTH Tim -- It's a dangerous business going out your front door. -- J.R.R. Tolkien From dcl441-bugs at yahoo.com Thu Feb 5 09:50:58 2009 From: dcl441-bugs at yahoo.com (Daniel Clemente) Date: Thu, 05 Feb 2009 18:50:58 +0100 Subject: [Conkeror] Search in Google the clipboard content with just one key Message-ID: <874oz8bwn1.fsf@CPU107.opentrends.net> Hi, I want to share a code which allows you to search in Google your clipboard's contents. That means you copy any text (in X, you select it with the mouse), press a key (I have ?l?), and you have the results page. interactive("search-clipboard-contents", "Search in Google the content of the X clipboard", "find-url", $browser_object= function(I) { return "g "+ read_from_x_primary_selection(); } ); define_key(content_buffer_normal_keymap, "l", "search-clipboard-contents"); -- Daniel From jjfoerch at earthlink.net Thu Feb 5 13:20:07 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Thu, 05 Feb 2009 16:20:07 -0500 Subject: [Conkeror] how to change page encoding? References: <20081230015614.GA5564@lars-x200s> <87ocys47ta.fsf@earthlink.net> <20081231185959.GA4245@lars-x200s> <877i5g3wfs.fsf@earthlink.net> <20090101043117.GA3838@lars-x200s> <87myeah2l7.fsf@earthlink.net> Message-ID: <87ljsk4m48.fsf@earthlink.net> Hi, Conkeror now has a command called reload-with-charset. The default key binding is `C-x return r'. It's very basic, but it's a good first step. Let me know if this works for the problem-pages you encountered. -- John Foerch From kettler at internode.on.net Fri Feb 6 20:43:05 2009 From: kettler at internode.on.net (David Kettler) Date: Sat, 07 Feb 2009 15:13:05 +1030 Subject: [Conkeror] flurry of patches Message-ID: <87ab8y6ena.fsf@internode.on.net> G'day all, I'm about to send a bunch of patches that I've been brewing for a while. I can push them myself, but I'd like comments first (even if it's just an okay). Sorry that there's quite a few at once, but there's no hurry. Unfortunately, communicating via IRC isn't working out too well for me, due to time zone differences and other commitments. regards, David From kettler at internode.on.net Fri Feb 6 20:44:38 2009 From: kettler at internode.on.net (David Kettler) Date: Sat, 7 Feb 2009 15:14:38 +1030 Subject: [Conkeror] [PATCH] google-search-results: added com.au domain Message-ID: <1233981878-9883-1-git-send-email-kettler@internode.on.net> --- modules/page-modes/google-search-results.js | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/modules/page-modes/google-search-results.js b/modules/page-modes/google-search-results.js index e41e132..abca8e9 100644 --- a/modules/page-modes/google-search-results.js +++ b/modules/page-modes/google-search-results.js @@ -71,7 +71,7 @@ let (google_search_re = build_url_regex( $domain = "google", $allow_www = true, $path = "search?", - $tlds = ["com", "co.uk", "de", "dk", "es", + $tlds = ["com", "com.au", "co.uk", "de", "dk", "es", "fr", "it", "no", "se", "uk"])) { auto_mode_list.push([google_search_re, google_search_results_mode]); }; -- 1.5.6.5 From kettler at internode.on.net Fri Feb 6 20:46:51 2009 From: kettler at internode.on.net (David Kettler) Date: Sat, 7 Feb 2009 15:16:51 +1030 Subject: [Conkeror] [PATCH] google-search-results: use search result links for more commands Message-ID: <1233982011-9912-1-git-send-email-kettler@internode.on.net> Use browser_object_google_search_results_links as the default browser object for all interactive commands that normally use browser_object_links. This commit adds follow-new-buffer, follow-new-buffer-background, follow-new-window and removes shell-command-on-url. The code is restructured a little too. --- It's clunky to have to explicitly list and override all relevant commands. Alternatives: - trawl through interactive_commands and set buffer.default_browser_object_classes for those that have browser_object == browser_object_links. That's very heavy handed though. - Have some further indirection in the hints or browser_object system to allow classes to be overridden. Perhaps this relates to the generalized interactive extensions discussed at http://bugs.conkeror.org/issue90. --- modules/page-modes/google-search-results.js | 21 ++++++++++++--------- 1 files changed, 12 insertions(+), 9 deletions(-) diff --git a/modules/page-modes/google-search-results.js b/modules/page-modes/google-search-results.js index abca8e9..29037c1 100644 --- a/modules/page-modes/google-search-results.js +++ b/modules/page-modes/google-search-results.js @@ -56,15 +56,18 @@ function google_search_bind_number_shortcuts () { define_page_mode("google_search_results_mode", "Google Search Results", $enable = function (buffer) { - buffer.local_variables.content_buffer_normal_keymap = google_search_results_keymap; - buffer.default_browser_object_classes = { - follow: browser_object_google_search_results_links, - copy: browser_object_google_search_results_links, - save: browser_object_google_search_results_links }; - buffer.default_browser_object_classes['shell-command-on-file'] = - browser_object_google_search_results_links; - buffer.default_browser_object_classes['shell-command-on-url'] = - browser_object_google_search_results_links; + buffer.local_variables.content_buffer_normal_keymap = + google_search_results_keymap; + var link_using_commands = ["follow", + "follow-new-buffer", + "follow-new-buffer-background", + "follow-new-window", + "save", + "copy", + "shell-command-on-file"]; + for each (var c in link_using_commands) + buffer.default_browser_object_classes[c] = + browser_object_google_search_results_links; }); let (google_search_re = build_url_regex( -- 1.5.6.5 From kettler at internode.on.net Fri Feb 6 20:49:08 2009 From: kettler at internode.on.net (David Kettler) Date: Sat, 7 Feb 2009 15:19:08 +1030 Subject: [Conkeror] [PATCH 1/2] Set buffer.loading false before content_buffer_finished_loading_hook Message-ID: <1233982149-9948-1-git-send-email-kettler@internode.on.net> Hook functions may want to check that flag, so we now set it prior to calling the hook functions. The (equivalent) flag was previously set first, but that was changed, perhaps inadvertently, in 61d83c5 (Implemented tab bar module, 2008-01-13). --- modules/content-buffer.js | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/modules/content-buffer.js b/modules/content-buffer.js index 880f306..43d61f3 100644 --- a/modules/content-buffer.js +++ b/modules/content-buffer.js @@ -202,8 +202,8 @@ content_buffer.prototype = { aStateFlags & Ci.nsIWebProgressListener.STATE_IS_NETWORK) { if (this.loading == true) { //dumpln("*** finished loading"); - content_buffer_finished_loading_hook.run(this); this.loading = false; + content_buffer_finished_loading_hook.run(this); } } -- 1.5.6.5 From kettler at internode.on.net Fri Feb 6 20:49:09 2009 From: kettler at internode.on.net (David Kettler) Date: Sat, 7 Feb 2009 15:19:09 +1030 Subject: [Conkeror] [PATCH 2/2] mode-line: provide a widget to show count of buffers currently loading In-Reply-To: <1233982149-9948-1-git-send-email-kettler@internode.on.net> References: <1233982149-9948-1-git-send-email-kettler@internode.on.net> Message-ID: <1233982149-9948-2-git-send-email-kettler@internode.on.net> This provides a count like (2 loading) in the mode-line. When no buffers are being loaded, the widget is blank. This is useful as a notifier when a buffer is visiting a web page that loads slowly. I enable this and the buffer count with: add_hook("mode_line_hook", mode_line_adder(loading_count_widget), true); add_hook("mode_line_hook", mode_line_adder(buffer_count_widget), true); --- modules/mode-line.js | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/modules/mode-line.js b/modules/mode-line.js index f07a8fa..74a4b27 100644 --- a/modules/mode-line.js +++ b/modules/mode-line.js @@ -206,6 +206,24 @@ buffer_count_widget.prototype.update = function () { this.window.buffers.count + "]"); }; +function loading_count_widget(window) { + this.name = "loading-count-widget"; + text_widget.call(this, window); + var obj = this; + this.add_hook("content_buffer_started_loading_hook"); + this.add_hook("content_buffer_finished_loading_hook"); + this.add_hook("kill_buffer_hook"); +} +loading_count_widget.prototype.__proto__ = text_widget.prototype; +loading_count_widget.prototype.update = function () { + var count = 0; + for_each_buffer(function(b) {if (b.loading) count++;}); + if (count) + this.view.text = "(" + count + " loading)"; + else + this.view.text = ""; +}; + function mode_line_adder(widget_constructor) { if (!('mode_line_adder' in widget_constructor)) widget_constructor.mode_line_adder = function (window) { -- 1.5.6.5 From kettler at internode.on.net Fri Feb 6 20:49:36 2009 From: kettler at internode.on.net (David Kettler) Date: Sat, 7 Feb 2009 15:19:36 +1030 Subject: [Conkeror] [PATCH 2/2] search-engine: provide alternative urls for search engine webjumps In-Reply-To: <1233982177-9981-1-git-send-email-kettler@internode.on.net> References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> Message-ID: <1233982177-9981-2-git-send-email-kettler@internode.on.net> The alternative url is visited when the user provides no arguments to the webjump; thus the webjump can function both as a way to invoke a search and as a bookmark. The alternative may be specified to define_search_engine_webjump(). If no alternative is supplied, conkeror will try to guess an appropriate url. The guess uses the text/html url for the search engine and trims off the path and any "search." prefix on the domain. This works for all the supplied search engines. --- Maybe it would be better to attach the alternative to the webjump object and to have the alternative logic in getWebJump(). Then it need not be in the handlers specified in define_webjump() and define_search_engine_webjump(). --- modules/search-engine.js | 24 +++++++++++++++++++++++- 1 files changed, 23 insertions(+), 1 deletions(-) diff --git a/modules/search-engine.js b/modules/search-engine.js index 010ec57..73c3c92 100644 --- a/modules/search-engine.js +++ b/modules/search-engine.js @@ -292,6 +292,19 @@ search_engine.prototype.__defineGetter__("completer", function () { } }); +/** + * Take a guess at a home page to correspond with the search engine. + * This works for all the provided search engines. + */ +search_engine.prototype.intuit_home_page = function() { + var url = this.urls.get("text/html"); + if (!url) + return null; + url = url_path_trim(url.template); + url = url.replace("//search.", "//"); + return url; +} + // Load search engines from default directories { let dir = file_locator.get("CurProcD", Ci.nsIFile); @@ -305,16 +318,25 @@ search_engine.prototype.__defineGetter__("completer", function () { load_search_engines_in_directory(dir); } +define_keywords("$alternative"); function define_search_engine_webjump(search_engine_name, key) { + keywords(arguments); var eng = search_engines.get(search_engine_name); + let alternative = arguments.$alternative; if (key == null) key = search_engine_name; + if (alternative == null) + alternative = eng.intuit_home_page(); define_webjump(key, function (arg) { - return eng.get_query_load_spec(arg); + if (arg == null && alternative) + return alternative + else + return eng.get_query_load_spec(arg); }, + $alternative = alternative, $description = eng.description, $completer = eng.completer); } -- 1.5.6.5 From kettler at internode.on.net Fri Feb 6 20:49:35 2009 From: kettler at internode.on.net (David Kettler) Date: Sat, 7 Feb 2009 15:19:35 +1030 Subject: [Conkeror] [PATCH 1/2] webjump: reworked code for the "alternative" url Message-ID: <1233982177-9981-1-git-send-email-kettler@internode.on.net> The alternative url (which is used when no argument is supplied by the user when invoking a webjump) should now be specified explicitly using the $alternative keyword to define_webjump(). The previous method (which will continue to be supported) of specifying the handler as an array of two strings was a bit arbitrary. Furthermore, it seems quite peculiar when considering an expansion of alternative urls for function handlers. Prepared for allowing search engine webjumps to specify an alternative url by allowing function handlers to have an alternative url. Expanded the comment describing the parameters to define_webjump(). The supplied webjumps that have alternative urls are changed to use the new style (although the old style will still work). --- modules/webjump.js | 76 ++++++++++++++++++++++++++++++--------------------- 1 files changed, 45 insertions(+), 31 deletions(-) diff --git a/modules/webjump.js b/modules/webjump.js index ce429d2..572329e 100644 --- a/modules/webjump.js +++ b/modules/webjump.js @@ -9,39 +9,54 @@ var webjumps = {}; -define_keywords("$completer", "$description", "$argument"); +define_keywords("$completer", "$description", "$argument", "$alternative"); function define_webjump(key, handler) { - keywords(arguments, $argument = true); - var argument; - - // handler may be a function, a string, or an array - // of a string and a "no args" alternate string. + keywords(arguments); + var argument = arguments.$argument; + let alternative = arguments.$alternative; + + // handler may be a function, a string, or (discouraged) an array + // of a string and an alternative string. The alternative string + // may be passed explictly using the $alternative keyword; it is + // used in place of the handler when no arguments are supplied by + // the user when invoking the webjump. For string webjumps that + // contain %s and for which no alternative is provided, an + // alternative is autogenerated by trimming the path from the url. + // A webjump can thus function both as a way to invoke a search + // and as a bookmark. // - // if the argument property was given as false, then completing on - // the name of the webjump in the minibuffer will not result in a - // space being appended. for string webjumps that contain %s, the - // argument is set as optional and a no-arg alternative is - // autogenerated by trimming the path from the url. + // The argument property may be false (no arguments will be + // accepted for the webjump), true (arguments are required for the + // webjump) or 'optional' (arguments are accepted but not + // required). If the property is not specified, a sensible default + // is chosen depending on the type of the handler and whether an + // alternative is specified. If the property is false, then + // completing on the name of the webjump in the minibuffer will + // not result in a space being appended. // + if (typeof(handler) == "object" && handler.length == 2) { + // the webjump was given as a two element array, with + // the second element being the provided alternative. + alternative = handler[1]; + handler = handler[0]; + } if (typeof(handler) == "function") { - argument = arguments.$argument; + if (argument == null && alternative == null) + argument = true; } else if (typeof(handler) == "string") { if (handler.indexOf('%s') == -1) argument = false; - else - argument = 'optional'; - } else if (typeof(handler) == "object") - // the webjump was given as a two element array, with - // the second element being the provided alternative. + else if (alternative == null) + alternative = url_path_trim(handler); + } + if (alternative && argument == null) argument = 'optional'; - function make_handler (template, alternative) { - if (alternative == null) - alternative = url_path_trim(template); + function make_handler (template) { var b = template.indexOf('%s'); return function (arg) { var a = b + 2; - if (arg == null && b > -1) + if (arg == null && alternative) return alternative; // Just return the same string if it doesn't contain a %s if (b == -1) @@ -52,9 +67,6 @@ function define_webjump(key, handler) { if (typeof(handler) == "string") handler = make_handler(handler); - else if (typeof(handler) == "object") - // An array of a template and an alternative url (for no args) - handler = make_handler(handler[0], handler[1]); webjumps[key] = { key: key, handler: handler, @@ -107,15 +119,17 @@ function define_default_webjumps() define_webjump("clusty", "http://www.clusty.com/search?query=%s"); define_webjump("slang", "http://www.urbandictionary.com/define.php?term=%s"); define_webjump("dictionary", "http://dictionary.reference.com/search?q=%s"); - define_webjump("xulplanet", ["http://www.google.com/custom?q=%s&cof=S%3A"+ - "http%3A%2F%2Fwww.xulplanet.com%3BAH%3Aleft%3BLH%3A65%3BLC"+ - "%3A4682B4%3BL%3Ahttp%3A%2F%2Fwww.xulplanet.com%2Fimages%2F"+ - "xulplanet.png%3BALC%3Ablue%3BLW%3A215%3BAWFID%3A0979f384d5"+ - "181409%3B&domains=xulplanet.com&sitesearch=xulplanet.com&sa=Go", - "http://xulplanet.com"]); + define_webjump("xulplanet", + "http://www.google.com/custom?q=%s&cof=S%3A"+ + "http%3A%2F%2Fwww.xulplanet.com%3BAH%3Aleft%3BLH%3A65%3BLC"+ + "%3A4682B4%3BL%3Ahttp%3A%2F%2Fwww.xulplanet.com%2Fimages%2F"+ + "xulplanet.png%3BALC%3Ablue%3BLW%3A215%3BAWFID%3A0979f384d5"+ + "181409%3B&domains=xulplanet.com&sitesearch=xulplanet.com&sa=Go", + $alternative = "http://xulplanet.com"); define_webjump("image", "http://images.google.com/images?q=%s"); - define_webjump("clhs", ["http://www.xach.com/clhs?q=%s", - "http://www.lispworks.com/documentation/HyperSpec/Front/index.htm"]); + define_webjump("clhs", + "http://www.xach.com/clhs?q=%s", + $alternative = "http://www.lispworks.com/documentation/HyperSpec/Front/index.htm"); define_webjump("emacswiki", "http://www.emacswiki.org/cgi-bin/wiki?search=%s"); define_webjump("cliki", "http://www.cliki.net/admin/search?words=%s"); define_webjump("ratpoisonwiki", "http://ratpoison.antidesktop.net/?search=%s"); -- 1.5.6.5 From kettler at internode.on.net Fri Feb 6 20:49:37 2009 From: kettler at internode.on.net (David Kettler) Date: Sat, 7 Feb 2009 15:19:37 +1030 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. In-Reply-To: <1233982177-9981-2-git-send-email-kettler@internode.on.net> References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> Message-ID: <1233982177-9981-3-git-send-email-kettler@internode.on.net> There's a convenient way to choose an alternative url as either a particular repository or as the repository list. A completer is available which fetches the list of repositories from gitweb. This should only be used on local sites; it's slow and not nice to the server to use on a large external site. Acknowledgement: The completer is glommed together from all_word_completer and the search_engine completer. Examples: require("gitweb-webjump.js"); define_gitweb_summary_webjump("gitweb-ko", "http://git.kernel.org"); define_gitweb_summary_webjump("gitweb-cz", "http://repo.or.cz/w"); You can now use the following webjumps: gitweb-cz conkeror gitweb-ko git/git --- The intention with the completer is that it gets the list from the server once only. However currently, if you press more keys before it has the list, it will redo the request. That's slower and is unfriendly to the server. It's okay for a fast, local server. Here's a patch that forces the get to happen only once. However in this case when more keys are pressed the get is never completed, so completions aren't available. I don't know how to fix this. --8<-- | diff --git a/modules/gitweb-webjump.js b/modules/gitweb-webjump.js | index 3067a79..37daef2 100644 | --- a/modules/gitweb-webjump.js | +++ b/modules/gitweb-webjump.js | @@ -16,13 +16,14 @@ require("webjump.js"); | */ | function gitweb_webjump_completer(opml_url) { | const response_type_xml = "application/x-suggestions+xml"; | - let completions = []; | + let completions = null; | return function (input, pos, conservative) { | if (pos == 0 && conservative) | yield co_return(undefined); | let str = input.substring(0,pos); | try { | - if (completions.length == 0) { | + if (completions == null) { | + completions = []; // only fetch once | let lspec = load_spec(opml_url, response_type_xml); | let doc = (yield send_http_request(lspec)).responseXML; | if (!doc) -->8-- Note that even with this fixed, I don't think you want the completer for either of the example sites; it takes a long time to get the OPML data. --- modules/gitweb-webjump.js | 91 +++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 91 insertions(+), 0 deletions(-) create mode 100644 modules/gitweb-webjump.js diff --git a/modules/gitweb-webjump.js b/modules/gitweb-webjump.js new file mode 100644 index 0000000..0b72cc5 --- /dev/null +++ b/modules/gitweb-webjump.js @@ -0,0 +1,91 @@ +/** + * (C) Copyright 2009 David Kettler + * + * Use, modification, and distribution are subject to the terms specified in the + * COPYING file. + * + * Construct a webjump (with optional completer) to visit repository + * summary pages at a gitweb server. +**/ + +require("webjump.js"); + +/** + * A completer that gets the list of repositories from the gitweb + * generated OPML. + */ +function gitweb_webjump_completer(opml_url) { + const response_type_xml = "application/x-suggestions+xml"; + let completions = []; + return function (input, pos, conservative) { + if (pos == 0 && conservative) + yield co_return(undefined); + let str = input.substring(0,pos); + try { + if (completions.length == 0) { + let lspec = load_spec(opml_url, response_type_xml); + let doc = (yield send_http_request(lspec)).responseXML; + if (!doc) + yield co_return(null); + let elems = doc.getElementsByTagName("outline"); + for (let i = 0; i < elems.length; ++i) { + let node = elems[i]; + let type = node.getAttribute("type"); + let name = node.getAttribute("text"); + if (type == "rss" && name) + completions.push(name.replace(/\.git$/, "")); + } + completions.sort(); + } + let words = trim_whitespace(input.toLowerCase()).split(/\s+/); + let data = completions.filter(function (x) { + for (var i = 0; i < words.length; ++i) + if (x.toLowerCase().indexOf(words[i]) == -1) + return false; + return true; + }); + let c = {count: data.length, + get_string: function (i) data[i], + get_description: function (i) data[i], + get_input_state: function (i) [data[i]]}; + yield co_return(c); + } catch (e) { + yield co_return(null); + } + }; +} + +/** + * Construct a webjump to visit repository summary pages at a gitweb + * server. + * + * If a repository name is supplied as $default then the alternative + * url is set to that repository at the gitweb site. If an + * alternative is not specified by either $default or $alternative + * then it is set to the repository list page of the gitweb site. + * + * If the $completer keyword is true, a completer is provided that + * fetches the list of repositories from gitweb. This should only be + * used on local sites; it's slow and not nice to the server to use on + * a large external site. + */ +define_keywords("$default", "$alternative", "$completer"); +function define_gitweb_summary_webjump(key, base_url) { + keywords(arguments); + let completer = arguments.$completer; + let alternative = arguments.$alternative; + let gitweb_url = base_url + "/gitweb.cgi"; + let search_url = gitweb_url + "?p=%s.git;a=summary"; + let opml_url = gitweb_url + "?a=opml"; + + if (completer == true) + completer = gitweb_webjump_completer(opml_url); + if (arguments.$default) + alternative = search_url.replace("%s", arguments.$default); + if (!alternative) + alternative = gitweb_url; + + define_webjump(key, search_url, + $completer = completer, + $alternative = alternative); +} -- 1.5.6.5 From songcq at gmail.com Fri Feb 6 20:59:19 2009 From: songcq at gmail.com (Chengqi(Lars) Song) Date: Sat, 7 Feb 2009 12:59:19 +0800 Subject: [Conkeror] the git is extremely slow Message-ID: <20090207045919.GB7046@lars-x200s.ust.hk> hi, im in hong kong and i found the official git of conkeror is extremely slow to access. it takes hours to finish this command: git clone git://repo.or.cz/conkeror.git is it slow too for any one else? lars From tassilo at member.fsf.org Sat Feb 7 04:32:43 2009 From: tassilo at member.fsf.org (Tassilo Horn) Date: Sat, 07 Feb 2009 13:32:43 +0100 Subject: [Conkeror] the git is extremely slow References: <20090207045919.GB7046@lars-x200s.ust.hk> Message-ID: <871vuao2ac.fsf@thinkpad.tsdh.de> "Chengqi(Lars) Song" writes: Hi! > [git clone git://repo.or.cz/conkeror.git is very slow] Hm, I've just timed this command, and here (in Germany) to takes about 10 seconds, so your hour is far too much. Git says it downloads about 2 MiB of data. If that really takes one hour, your connection seems to be at 3.3 KiB/second. Anyway, each "git pull" after the first clone should be much faster. Bye, Tassilo From jjfoerch at earthlink.net Sat Feb 7 11:24:40 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 14:24:40 -0500 Subject: [Conkeror] [PATCH] google-search-results: added com.au domain References: <1233981878-9883-1-git-send-email-kettler@internode.on.net> Message-ID: <87hc363v9j.fsf@earthlink.net> David Kettler writes: > --- > modules/page-modes/google-search-results.js | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/modules/page-modes/google-search-results.js b/modules/page-modes/google-search-results.js > index e41e132..abca8e9 100644 > --- a/modules/page-modes/google-search-results.js > +++ b/modules/page-modes/google-search-results.js > @@ -71,7 +71,7 @@ let (google_search_re = build_url_regex( > $domain = "google", > $allow_www = true, > $path = "search?", > - $tlds = ["com", "co.uk", "de", "dk", "es", > + $tlds = ["com", "com.au", "co.uk", "de", "dk", "es", > "fr", "it", "no", "se", "uk"])) { > auto_mode_list.push([google_search_re, google_search_results_mode]); > }; ok -- John Foerch From jjfoerch at earthlink.net Sat Feb 7 11:34:10 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 14:34:10 -0500 Subject: [Conkeror] [PATCH] google-search-results: use search result links for more commands References: <1233982011-9912-1-git-send-email-kettler@internode.on.net> Message-ID: <87d4du3utp.fsf@earthlink.net> David Kettler writes: > Use browser_object_google_search_results_links as the default browser > object for all interactive commands that normally use > browser_object_links. This commit adds follow-new-buffer, > follow-new-buffer-background, follow-new-window and removes > shell-command-on-url. > > The code is restructured a little too. > > --- > > It's clunky to have to explicitly list and override all relevant > commands. Alternatives: > > - trawl through interactive_commands and set > buffer.default_browser_object_classes for those that have > browser_object == browser_object_links. > > That's very heavy handed though. > > - Have some further indirection in the hints or browser_object > system to allow classes to be overridden. Perhaps this relates to > the generalized interactive extensions discussed at > http://bugs.conkeror.org/issue90. Looks good. Let's keep it simple and just list the overrides explicitly, as you do in your patch. The idea of a level of indirection in the browser object system is a good one, though. I'm not immediately sure what form its implementation will take, but it is something to keep in mind as we improve the system. -- John Foerch From jjfoerch at earthlink.net Sat Feb 7 12:05:47 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 15:05:47 -0500 Subject: [Conkeror] [PATCH 1/2] webjump: reworked code for the "alternative" url References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> Message-ID: <878woi3td0.fsf@earthlink.net> David Kettler writes: > The alternative url (which is used when no argument is supplied by the > user when invoking a webjump) should now be specified explicitly using > the $alternative keyword to define_webjump(). The previous method > (which will continue to be supported) of specifying the handler as an > array of two strings was a bit arbitrary. Furthermore, it seems quite > peculiar when considering an expansion of alternative urls for function > handlers. > > Prepared for allowing search engine webjumps to specify an alternative > url by allowing function handlers to have an alternative url. > > Expanded the comment describing the parameters to define_webjump(). > > The supplied webjumps that have alternative urls are changed to use > the new style (although the old style will still work). This looks good. I don't see any reason to keep compatibility with the two-element-array form, though. Conkeror's API is still unstable and I think everybody understands they will have to update their rc's with changes as we figure things out. -- John Foerch From jjfoerch at earthlink.net Sat Feb 7 12:38:34 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 15:38:34 -0500 Subject: [Conkeror] [PATCH 2/2] search-engine: provide alternative urls for search engine webjumps References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> Message-ID: <874oz63rud.fsf@earthlink.net> David Kettler writes: > The alternative url is visited when the user provides no arguments to > the webjump; thus the webjump can function both as a way to invoke a > search and as a bookmark. > > The alternative may be specified to define_search_engine_webjump(). > If no alternative is supplied, conkeror will try to guess an > appropriate url. The guess uses the text/html url for the search > engine and trims off the path and any "search." prefix on the domain. > This works for all the supplied search engines. This looks good, though I would make one change.. > +search_engine.prototype.intuit_home_page = function() { Change this to an ordinary function called search_engine_get_homepage that takes a search engine as its argument. > + url = url.replace("//search.", "//"); What is the purpose of this line? > Maybe it would be better to attach the alternative to the webjump > object and to have the alternative logic in getWebJump(). Then it > need not be in the handlers specified in define_webjump() and > define_search_engine_webjump(). That's a thought. Let's get these current changes in first. Thanks, I was looking at writing this feature myself, and now I don't have to. :) -- John Foerch From jjfoerch at earthlink.net Sat Feb 7 12:43:29 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 15:43:29 -0500 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <1233982177-9981-3-git-send-email-kettler@internode.on.net> Message-ID: <87zlgy2d1q.fsf@earthlink.net> David Kettler writes: > There's a convenient way to choose an alternative url as either a > particular repository or as the repository list. > > A completer is available which fetches the list of repositories from > gitweb. This should only be used on local sites; it's slow and not > nice to the server to use on a large external site. > > Acknowledgement: The completer is glommed together from > all_word_completer and the search_engine completer. > > Examples: > > require("gitweb-webjump.js"); > define_gitweb_summary_webjump("gitweb-ko", "http://git.kernel.org"); > define_gitweb_summary_webjump("gitweb-cz", "http://repo.or.cz/w"); > > You can now use the following webjumps: > gitweb-cz conkeror > gitweb-ko git/git > --- > > The intention with the completer is that it gets the list from the > server once only. However currently, if you press more keys before it > has the list, it will redo the request. That's slower and is > unfriendly to the server. It's okay for a fast, local server. > > Here's a patch that forces the get to happen only once. However in > this case when more keys are pressed the get is never completed, so > completions aren't available. I don't know how to fix this. Can this go on the Webjumps page of our wiki, perhaps on its own page, since it is long? Because of the problems you cite and it being "not nice to external servers" I hesitate to add it. -- John Foerch From jjfoerch at earthlink.net Sat Feb 7 12:50:11 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 15:50:11 -0500 Subject: [Conkeror] [PATCH 2/2] mode-line: provide a widget to show count of buffers currently loading References: <1233982149-9948-1-git-send-email-kettler@internode.on.net> <1233982149-9948-2-git-send-email-kettler@internode.on.net> Message-ID: <87r62a2cqk.fsf@earthlink.net> David Kettler writes: > This provides a count like (2 loading) in the mode-line. When no > buffers are being loaded, the widget is blank. This is useful as a > notifier when a buffer is visiting a web page that loads slowly. > > I enable this and the buffer count with: > add_hook("mode_line_hook", mode_line_adder(loading_count_widget), true); > add_hook("mode_line_hook", mode_line_adder(buffer_count_widget), true); ok -- John Foerch From jjfoerch at earthlink.net Sat Feb 7 12:48:49 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 15:48:49 -0500 Subject: [Conkeror] [PATCH 1/2] Set buffer.loading false before content_buffer_finished_loading_hook References: <1233982149-9948-1-git-send-email-kettler@internode.on.net> Message-ID: <87vdrm2csu.fsf@earthlink.net> David Kettler writes: > Hook functions may want to check that flag, so we now set it prior to > calling the hook functions. > > The (equivalent) flag was previously set first, but that was changed, > perhaps inadvertently, in 61d83c5 (Implemented tab bar module, > 2008-01-13). ok -- John Foerch From kettler at internode.on.net Sat Feb 7 17:20:58 2009 From: kettler at internode.on.net (David Kettler) Date: Sun, 08 Feb 2009 11:50:58 +1030 Subject: [Conkeror] [PATCH] google-search-results: use search result links for more commands In-Reply-To: <87d4du3utp.fsf@earthlink.net> References: <1233982011-9912-1-git-send-email-kettler@internode.on.net> <87d4du3utp.fsf@earthlink.net> Message-ID: <498E337A.9010502@internode.on.net> Thanks very much for your quick and thoughtful reviews, John. I very much appreciate it. > Looks good. Let's keep it simple and just list the overrides > explicitly, as you do in your patch. Righto. From kettler at internode.on.net Sat Feb 7 17:24:03 2009 From: kettler at internode.on.net (David Kettler) Date: Sun, 08 Feb 2009 11:54:03 +1030 Subject: [Conkeror] [PATCH 1/2] webjump: reworked code for the "alternative" url In-Reply-To: <878woi3td0.fsf@earthlink.net> References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <878woi3td0.fsf@earthlink.net> Message-ID: <498E3433.4000108@internode.on.net> > This looks good. I don't see any reason to keep compatibility with the > two-element-array form, though. Conkeror's API is still unstable and I > think everybody understands they will have to update their rc's with > changes as we figure things out. Okay, I'll remove that. When I push I'll also update the examples on the Webjumps wiki page and note the change on the BreakingChanges page. From kettler at internode.on.net Sat Feb 7 17:40:29 2009 From: kettler at internode.on.net (David Kettler) Date: Sun, 08 Feb 2009 12:10:29 +1030 Subject: [Conkeror] [PATCH 2/2] search-engine: provide alternative urls for search engine webjumps In-Reply-To: <874oz63rud.fsf@earthlink.net> References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <874oz63rud.fsf@earthlink.net> Message-ID: <498E380D.6020901@internode.on.net> > This looks good, though I would make one change.. > >> +search_engine.prototype.intuit_home_page = function() { > > Change this to an ordinary function called search_engine_get_homepage > that takes a search engine as its argument. Ack. >> + url = url.replace("//search.", "//"); > > What is the purpose of this line? Here are the (path stripped) urls from the provided search-engines: % sed -ne '/text\/html/{s,.*template=",,;s,\(.*://[^/]*\)/.*,\1,;p}' *.xml http://www.answers.com http://search.creativecommons.org http://search.ebay.com http://www.google.com https://bugzilla.mozilla.org http://en.wikipedia.org http://search.yahoo.com My intention is that the alternative url is normally the home page of the site. Three of those urls have a "search." component in the url which, if removed, yields the home page. That's what the url.replace() line is for. You could argue that visiting a specialised search page is also useful. But it's hard to intuit what that page is on most sites (and most sites don't have anything more than a simple search box anyway). So I think its better for the intuited alternative to be consistently the home page. The user can always specify something else explicitly of they prefer. >> Maybe it would be better to attach the alternative to the webjump >> object and to have the alternative logic in getWebJump(). Then it >> need not be in the handlers specified in define_webjump() and >> define_search_engine_webjump(). > > That's a thought. Let's get these current changes in first. Ack. > Thanks, I was looking at writing this feature myself, and now I don't > have to. :) No worries. regards, David. From jjfoerch at earthlink.net Sat Feb 7 17:44:08 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 20:44:08 -0500 Subject: [Conkeror] [PATCH 1/2] webjump: reworked code for the "alternative" url References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <878woi3td0.fsf@earthlink.net> <498E3433.4000108@internode.on.net> Message-ID: <87iqnl3dp3.fsf@earthlink.net> David Kettler writes: >> This looks good. I don't see any reason to keep compatibility with the >> two-element-array form, though. Conkeror's API is still unstable and I >> think everybody understands they will have to update their rc's with >> changes as we figure things out. > > Okay, I'll remove that. When I push I'll also update the examples on > the Webjumps wiki page and note the change on the BreakingChanges > page. thanks From kettler at internode.on.net Sat Feb 7 18:18:03 2009 From: kettler at internode.on.net (David Kettler) Date: Sun, 08 Feb 2009 12:48:03 +1030 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. In-Reply-To: <87zlgy2d1q.fsf@earthlink.net> References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <1233982177-9981-3-git-send-email-kettler@internode.on.net> <87zlgy2d1q.fsf@earthlink.net> Message-ID: <498E40DB.9020906@internode.on.net> > Can this go on the Webjumps page of our wiki, perhaps on its own page, > since it is long? Perhaps. > Because of the problems you cite and it being "not > nice to external servers" I hesitate to add it. I think I overstated the problem. The webjump itself is fine, there's only a problem with the completer. The completer is disabled by default; it must be explicitly requested for each gitweb site. For "external" servers, I don't think the completer is useful anyway. Fetching the OPML data from the gitweb server is very slow for both kernel.org and repo.or.cz. Both sites have many projects, resulting in a long list. I don't think the completion system is a convenient way to choose from that list. It's probably better to visit the repo list page at the site (which is the default alternative url) and select the repo with isearch on that page. For local servers, the problem is of not much consequence. It may end up requesting the OPML data several times, but if the list is not very long that doesn't much matter. At my work, with about ten projects on the gitweb server it works great. Note that once it's got the data, it is cached, so subsequent uses of the webjump incur no cost. I think the right thing is to fix the completer so it always requests the OPML data just once. That should be straightforward enough, presumably involving co_call(). I don't understand the coroutine interface well enough yet though. Another thought for external servers; the completion data could be cached somewhere (in a preference or something) and be persistent across sessions. That might reduce the cost enough to make it useful. regards, David. From jjfoerch at earthlink.net Sat Feb 7 18:35:36 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 21:35:36 -0500 Subject: [Conkeror] [PATCH 2/2] search-engine: provide alternative urls for search engine webjumps References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <874oz63rud.fsf@earthlink.net> <498E380D.6020901@internode.on.net> Message-ID: <87eiy93bbb.fsf@earthlink.net> David Kettler writes: >>> + url = url.replace("//search.", "//"); >> >> What is the purpose of this line? > > Here are the (path stripped) urls from the provided search-engines: > > % sed -ne '/text\/html/{s,.*template=",,;s,\(.*://[^/]*\)/.*,\1,;p}' *.xml > http://www.answers.com > http://search.creativecommons.org > http://search.ebay.com > http://www.google.com > https://bugzilla.mozilla.org > http://en.wikipedia.org > http://search.yahoo.com > > My intention is that the alternative url is normally the home page of > the site. Three of those urls have a "search." component in the url > which, if removed, yields the home page. That's what the > url.replace() line is for. > > You could argue that visiting a specialised search page is also > useful. But it's hard to intuit what that page is on most sites (and > most sites don't have anything more than a simple search box anyway). > So I think its better for the intuited alternative to be consistently > the home page. The user can always specify something else explicitly > of they prefer. Oh, okay. -- John Foerch From jjfoerch at earthlink.net Sat Feb 7 19:12:56 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 07 Feb 2009 22:12:56 -0500 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <1233982177-9981-3-git-send-email-kettler@internode.on.net> <87zlgy2d1q.fsf@earthlink.net> <498E40DB.9020906@internode.on.net> Message-ID: <87ab8x39l3.fsf@earthlink.net> David Kettler writes: >> Can this go on the Webjumps page of our wiki, perhaps on its own page, >> since it is long? > > Perhaps. > >> Because of the problems you cite and it being "not >> nice to external servers" I hesitate to add it. > > I think I overstated the problem. The webjump itself is fine, there's > only a problem with the completer. The completer is disabled by > default; it must be explicitly requested for each gitweb site. > > For "external" servers, I don't think the completer is useful > anyway. Fetching the OPML data from the gitweb server is very slow for > both kernel.org and repo.or.cz. Both sites have many projects, > resulting in a long list. I don't think the completion system is a > convenient way to choose from that list. It's probably better to > visit the repo list page at the site (which is the default alternative > url) and select the repo with isearch on that page. > > For local servers, the problem is of not much consequence. It may end > up requesting the OPML data several times, but if the list is not very > long that doesn't much matter. At my work, with about ten projects on > the gitweb server it works great. Note that once it's got the data, > it is cached, so subsequent uses of the webjump incur no cost. > > I think the right thing is to fix the completer so it always requests > the OPML data just once. That should be straightforward enough, > presumably involving co_call(). I don't understand the coroutine > interface well enough yet though. > > Another thought for external servers; the completion data could be > cached somewhere (in a preference or something) and be persistent > across sessions. That might reduce the cost enough to make it useful. > > regards, David. Hi David, How about the following approach? Shift the burden of downloading the OPML file to the user, and have them store it in a directory of their choice, and update it manually when they want. This would eliminate the problem of large downloads at inconvenient times, as well as the problem of storing the opml data in a profile-dependent way. gitweb-webjumps.js would define a user variable called, for example, `gitweb_webjumps_opml_directory'. Its default value would be null, and users would be expected to set it to an nsILocalFile object. (Conkeror is now using nsILocalFile objects in favor of string paths for things like this because they are cross-platform safe and provide convenient methods for adding directories and resolving relative paths.) The user would obtain an opml file and put it in that directory, and then call `define_gitweb_summary_webjump' with the name of the webjump and the name of the file. If needed, there could be any kind of utility to assist users in obtaining the opml file. This design is patterned closely after how search-engine.js works with its opensearch files. -- John Foerch From kettler at internode.on.net Sat Feb 7 22:42:29 2009 From: kettler at internode.on.net (David Kettler) Date: Sun, 08 Feb 2009 17:12:29 +1030 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. In-Reply-To: <87ab8x39l3.fsf@earthlink.net> References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <1233982177-9981-3-git-send-email-kettler@internode.on.net> <87zlgy2d1q.fsf@earthlink.net> <498E40DB.9020906@internode.on.net> <87ab8x39l3.fsf@earthlink.net> Message-ID: <498E7ED5.504@internode.on.net> G'day John, > How about the following approach? Shift the burden of downloading the > OPML file to the user, and have them store it in a directory of their > choice, and update it manually when they want. This would eliminate the > problem of large downloads at inconvenient times, as well as the problem > of storing the opml data in a profile-dependent way. Yes, that does sound like a better idea. > gitweb-webjumps.js would define a user variable called, for example, > `gitweb_webjumps_opml_directory'. Its default value would be null, and > users would be expected to set it to an nsILocalFile object. How about we pick a default of gitweb-webjumps-opml under (whatever the variables are denoting) one of these: ~/.conkerorrc/ ~/.conkeror.mozdev.org/conkeror/blahblah.default/ > (Conkeror > is now using nsILocalFile objects in favor of string paths for things > like this because they are cross-platform safe and provide convenient > methods for adding directories and resolving relative paths.) Okay. > The user would obtain an opml file and put it in that directory, and > then call `define_gitweb_summary_webjump' with the name of the webjump > and the name of the file. With the default filename being s/xml$/opml$/. > If needed, there could be any kind of utility > to assist users in obtaining the opml file. Maybe gitweb-webjump-get-repository-list with a completer that lists the available gitweb webjumps. (I guess I'll need to mark those webjumps in some way; perhaps they'll have a gitweb_opml_file property.) > This design is patterned closely after how search-engine.js works with > its opensearch files. Sounds good. regards, David From songcq at gmail.com Sun Feb 8 00:39:29 2009 From: songcq at gmail.com (Chengqi(Lars) Song) Date: Sun, 8 Feb 2009 16:39:29 +0800 Subject: [Conkeror] the git is extremely slow In-Reply-To: <871vuao2ac.fsf@thinkpad.tsdh.de> References: <20090207045919.GB7046@lars-x200s.ust.hk> <871vuao2ac.fsf@thinkpad.tsdh.de> Message-ID: <20090208083929.GA11577@lars-x200s.ust.hk> my internet access is rather good in fact, so i dont know if i did something wrong or the connection from hong kong to repo.or.cz is slow. the output of git clone is: lars:/tmp$ git clone git://repo.or.cz/conkeror.git Initialized empty Git repository in /tmp/conkeror/.git/ remote: Counting objects: 7395, done. remote: CompressingReceiving objects: 0% (1/7395) then the remote compessing will take 1-2 hours and receiving objects will take another 1-2 hours. thanks lars On Sat, 07 Feb 2009, Tassilo Horn wrote: > "Chengqi(Lars) Song" writes: > > Hi! > > > [git clone git://repo.or.cz/conkeror.git is very slow] > > Hm, I've just timed this command, and here (in Germany) to takes about > 10 seconds, so your hour is far too much. Git says it downloads about 2 > MiB of data. If that really takes one hour, your connection seems to be > at 3.3 KiB/second. > > Anyway, each "git pull" after the first clone should be much faster. > > Bye, > Tassilo > > _______________________________________________ > Conkeror mailing list > Conkeror at mozdev.org > https://www.mozdev.org/mailman/listinfo/conkeror From kettler at internode.on.net Sun Feb 8 04:37:56 2009 From: kettler at internode.on.net (David Kettler) Date: Sun, 08 Feb 2009 23:07:56 +1030 Subject: [Conkeror] [PATCH 1/2] webjump: reworked code for the "alternative" url In-Reply-To: <87iqnl3dp3.fsf@earthlink.net> References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <878woi3td0.fsf@earthlink.net> <498E3433.4000108@internode.on.net> <87iqnl3dp3.fsf@earthlink.net> Message-ID: <498ED224.5020301@internode.on.net> >> Okay, I'll remove that. When I push I'll also update the examples on >> the Webjumps wiki page and note the change on the BreakingChanges >> page. Done. I forgot to comment the changes on the wiki though. Sorry about that; the wiki I normally use doesn't take comments on changes. From jjfoerch at earthlink.net Sun Feb 8 06:37:33 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sun, 08 Feb 2009 09:37:33 -0500 Subject: [Conkeror] the git is extremely slow References: <20090207045919.GB7046@lars-x200s.ust.hk> <871vuao2ac.fsf@thinkpad.tsdh.de> <20090208083929.GA11577@lars-x200s.ust.hk> Message-ID: <8763jl2dw2.fsf@earthlink.net> "Chengqi(Lars) Song" writes: > my internet access is rather good in fact, so i dont know if i did something wrong or the connection from hong kong to repo.or.cz is slow. > the output of git clone is: > > lars:/tmp$ git clone git://repo.or.cz/conkeror.git > Initialized empty Git repository in /tmp/conkeror/.git/ > remote: Counting objects: 7395, done. > remote: CompressingReceiving objects: 0% (1/7395) > > then the remote compessing will take 1-2 hours and receiving objects will take another 1-2 hours. > > thanks > lars It's probably just "one of those things"--a slow link somewhere between Hong Kong and Czechoslovakia. But once you have made one clone, you never have to clone again, so it shouldn't be a big problem. -- John Foerch From deniz.a.m.dogan at gmail.com Sun Feb 8 06:37:48 2009 From: deniz.a.m.dogan at gmail.com (Deniz Dogan) Date: Sun, 8 Feb 2009 15:37:48 +0100 Subject: [Conkeror] the git is extremely slow In-Reply-To: <8763jl2dw2.fsf@earthlink.net> References: <20090207045919.GB7046@lars-x200s.ust.hk> <871vuao2ac.fsf@thinkpad.tsdh.de> <20090208083929.GA11577@lars-x200s.ust.hk> <8763jl2dw2.fsf@earthlink.net> Message-ID: <7b501d5c0902080637m7bec8baau194c4852b265dded@mail.gmail.com> 2009/2/8 John J Foerch : > It's probably just "one of those things"--a slow link somewhere between > Hong Kong and Czechoslovakia. The Czech Republic* ;) Deniz From jjfoerch at earthlink.net Sun Feb 8 06:46:40 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sun, 08 Feb 2009 09:46:40 -0500 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <1233982177-9981-3-git-send-email-kettler@internode.on.net> <87zlgy2d1q.fsf@earthlink.net> <498E40DB.9020906@internode.on.net> <87ab8x39l3.fsf@earthlink.net> <498E7ED5.504@internode.on.net> Message-ID: <871vu92dgv.fsf@earthlink.net> David Kettler writes: > > How about we pick a default of gitweb-webjumps-opml under (whatever > the variables are denoting) one of these: > ~/.conkerorrc/ > ~/.conkeror.mozdev.org/conkeror/blahblah.default/ Hi David, For the time being, I don't want to have a default directory. In the case of something under "~/.conkerorrc", that does not work because ~/.conkerorrc is permitted to be either a file or a directory. In the case of using the profile directory, I would like to move away from dependencies on the profile. The search-engine module does in fact use the profile directory for this purpose, but that is something I would like to remove in favor of a load-path style loader. I think the ultimate solution will be, at some future point, to eliminate the use of ~/.conkerorrc in favor of a directory called ~/.conkeror, which can contain pre-defined subdirectories for opensearch files, opml files, themes, and whatever else we come up with. But let us consider that as a project for the future. > > Maybe gitweb-webjump-get-repository-list with a completer that lists > the available gitweb webjumps. (I guess I'll need to mark those > webjumps in some way; perhaps they'll have a gitweb_opml_file > property.) > A special buffer for listing the available opml files? The user still has to enable them in the rc, so I don't see the point of this. But maybe I misunderstand. All else sounds good. I'm really looking forward to this feature. -- John Foerch From jjfoerch at earthlink.net Sun Feb 8 06:57:42 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sun, 08 Feb 2009 09:57:42 -0500 Subject: [Conkeror] the git is extremely slow References: <20090207045919.GB7046@lars-x200s.ust.hk> <871vuao2ac.fsf@thinkpad.tsdh.de> <20090208083929.GA11577@lars-x200s.ust.hk> <8763jl2dw2.fsf@earthlink.net> <7b501d5c0902080637m7bec8baau194c4852b265dded@mail.gmail.com> Message-ID: <87wsc10ye1.fsf@earthlink.net> Deniz Dogan writes: > 2009/2/8 John J Foerch : >> It's probably just "one of those things"--a slow link somewhere between >> Hong Kong and Czechoslovakia. > > The Czech Republic* ;) > > Deniz Ah, my bad. -- John Foerch From jjfoerch at earthlink.net Sun Feb 8 07:00:48 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sun, 08 Feb 2009 10:00:48 -0500 Subject: [Conkeror] [PATCH 1/2] webjump: reworked code for the "alternative" url References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <878woi3td0.fsf@earthlink.net> <498E3433.4000108@internode.on.net> <87iqnl3dp3.fsf@earthlink.net> <498ED224.5020301@internode.on.net> Message-ID: <87skmp0y8v.fsf@earthlink.net> David Kettler writes: >>> Okay, I'll remove that. When I push I'll also update the examples on >>> the Webjumps wiki page and note the change on the BreakingChanges >>> page. > > Done. I forgot to comment the changes on the wiki though. Sorry > about that; the wiki I normally use doesn't take comments on changes. No problem. Any thoughts on using the keyword $alternate instead of $alternative? If there's no difference in meaning, I have an aesthetic preference for the shorter one. -- John Foerch From its.sec at gmx.net Sun Feb 8 09:43:22 2009 From: its.sec at gmx.net (Tom Rauchenwald) Date: Sun, 08 Feb 2009 18:43:22 +0100 Subject: [Conkeror] fix for reddit.js References: <871vufrxzo.fsf@sec.modprobe.de> <878won5frs.fsf@earthlink.net> Message-ID: <87k580n7t1.fsf@sec.modprobe.de> John J Foerch writes: >> Hi, >> >> I took a quick look at reddit.js and put a fix together.. I don't have >> time to test it properly, but it seems to work for me. >> >> If anyone could test it i'd be thankful. >> >> Thanks, >> Tom > > Thank you. Works great. Applied. Any idea why the bindings , and > . don't work, and what they are supposed to do? In reddit, you can vote stories up or down, when you like or dislike them. Those keys are supposed to be shortcuts to this function.. I took a look at the code but haven't been able to come up with a solution, they changed the site to use jquery and i barely know javascript. Anyway, I installed mozrepl and it's a good chance for me to get started with JavaScript, so maybe i'll be able to fix it sometime. -t -- They look at me funny; they think I twitch a lot. I'm not twitching. I'm controlling my impulse to snag my 9mm Sig-Sauer out from my day-pack and make a few strong points about the quality of undergraduate education in Amerika. -- Olin Shivers From jjfoerch at earthlink.net Sun Feb 8 11:28:12 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sun, 08 Feb 2009 14:28:12 -0500 Subject: [Conkeror] [PATCH 1/2] webjump: reworked code for the "alternative" url References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <878woi3td0.fsf@earthlink.net> <498E3433.4000108@internode.on.net> <87iqnl3dp3.fsf@earthlink.net> <498ED224.5020301@internode.on.net> <87skmp0y8v.fsf@earthlink.net> Message-ID: <87ocxc20fn.fsf@earthlink.net> John J Foerch writes: > Any thoughts on using the keyword $alternate instead of $alternative? > If there's no difference in meaning, I have an aesthetic preference for > the shorter one. Nevermind that point. I looked it up and found that "alternative" is considered the more standard noun form. -- John Foerch From jjfoerch at earthlink.net Sun Feb 8 11:29:28 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sun, 08 Feb 2009 14:29:28 -0500 Subject: [Conkeror] fix for reddit.js References: <871vufrxzo.fsf@sec.modprobe.de> <878won5frs.fsf@earthlink.net> <87k580n7t1.fsf@sec.modprobe.de> Message-ID: <87k58020dj.fsf@earthlink.net> Tom Rauchenwald writes: > In reddit, you can vote stories up or down, when you like or dislike > them. Those keys are supposed to be shortcuts to this function.. > > I took a look at the code but haven't been able to come up with a > solution, they changed the site to use jquery and i barely know > javascript. Anyway, I installed mozrepl and it's a good chance for me to > get started with JavaScript, so maybe i'll be able to fix it sometime. > > -t Dybber said he was going to work on it too. You can probably catch him in the irc channel some time if you wanted to work with him on it. -- John Foerch From philip.weaver at gmail.com Sun Feb 8 12:57:07 2009 From: philip.weaver at gmail.com (Philip Weaver) Date: Sun, 8 Feb 2009 12:57:07 -0800 Subject: [Conkeror] the git is extremely slow In-Reply-To: <8763jl2dw2.fsf@earthlink.net> References: <20090207045919.GB7046@lars-x200s.ust.hk> <871vuao2ac.fsf@thinkpad.tsdh.de> <20090208083929.GA11577@lars-x200s.ust.hk> <8763jl2dw2.fsf@earthlink.net> Message-ID: On Sun, Feb 8, 2009 at 6:37 AM, John J Foerch wrote: > "Chengqi(Lars) Song" writes: > > my internet access is rather good in fact, so i dont know if i did > something wrong or the connection from hong kong to repo.or.cz is slow. > > the output of git clone is: > > > > lars:/tmp$ git clone git://repo.or.cz/conkeror.git > > Initialized empty Git repository in /tmp/conkeror/.git/ > > remote: Counting objects: 7395, done. > > remote: CompressingReceiving objects: 0% (1/7395) > > > > then the remote compessing will take 1-2 hours and receiving objects will > take another 1-2 hours. > > > > thanks > > lars > > It's probably just "one of those things"--a slow link somewhere between > Hong Kong and Czechoslovakia. But once you have made one clone, you > never have to clone again, so it shouldn't be a big problem. > Could we perhaps mirror the repo on something like github? > > -- > John Foerch > > _______________________________________________ > Conkeror mailing list > Conkeror at mozdev.org > https://www.mozdev.org/mailman/listinfo/conkeror > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jeremy at jeremyms.com Sun Feb 8 13:22:59 2009 From: jeremy at jeremyms.com (Jeremy Maitin-Shepard) Date: Sun, 08 Feb 2009 13:22:59 -0800 Subject: [Conkeror] the git is extremely slow In-Reply-To: (Philip Weaver's message of "Sun, 08 Feb 2009 12:57:07 -0800") References: <20090207045919.GB7046@lars-x200s.ust.hk> <871vuao2ac.fsf@thinkpad.tsdh.de> <20090208083929.GA11577@lars-x200s.ust.hk> <8763jl2dw2.fsf@earthlink.net> Message-ID: <87ljsgipxo.fsf@jeremyms.com> Philip Weaver writes: > On Sun, Feb 8, 2009 at 6:37 AM, John J Foerch wrote: >> "Chengqi(Lars) Song" writes: >> > my internet access is rather good in fact, so i dont know if i did >> something wrong or the connection from hong kong to repo.or.cz is slow. >> > the output of git clone is: >> > >> > lars:/tmp$ git clone git://repo.or.cz/conkeror.git >> > Initialized empty Git repository in /tmp/conkeror/.git/ >> > remote: Counting objects: 7395, done. >> > remote: CompressingReceiving objects: 0% (1/7395) >> > >> > then the remote compessing will take 1-2 hours and receiving objects will >> take another 1-2 hours. >> > >> > thanks >> > lars >> >> It's probably just "one of those things"--a slow link somewhere between >> Hong Kong and Czechoslovakia. But once you have made one clone, you >> never have to clone again, so it shouldn't be a big problem. >> > Could we perhaps mirror the repo on something like github? Well, you could set up a mirror, I suppose. However, I haven't had any problems with repo.or.cz so far. It seems just like a routing problem that Chengqi Song is experiencing, though. Chengqi Song: Do you also find that the websites hosted on repo.or.cz are slow as well, such as http://repo.or.cz/about.html ? -- Jeremy Maitin-Shepard From David.Kettler at dsto.defence.gov.au Sun Feb 8 15:24:13 2009 From: David.Kettler at dsto.defence.gov.au (David Kettler) Date: 09 Feb 2009 09:54:13 +1030 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. In-Reply-To: <871vu92dgv.fsf@earthlink.net> References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <1233982177-9981-3-git-send-email-kettler@internode.on.net> <87zlgy2d1q.fsf@earthlink.net> <498E40DB.9020906@internode.on.net> <87ab8x39l3.fsf@earthlink.net> <498E7ED5.504@internode.on.net> <871vu92dgv.fsf@earthlink.net> Message-ID: > For the time being, I don't want to have a default directory. In the > case of something under "~/.conkerorrc", that does not work because > ~/.conkerorrc is permitted to be either a file or a directory. In the > case of using the profile directory, I would like to move away from > dependencies on the profile. The search-engine module does in fact use > the profile directory for this purpose, but that is something I would > like to remove in favor of a load-path style loader. Okay. I see that magick-options uses a preference; that's probably where I got that idea. I guess that will also change in time. Actually, if I'd paid more attention to that example, it would have been easier for me to write the gitweb completer. BTW, thanks for updating it, which I missed, for $alternative. > I think the ultimate solution will be, at some future point, to > eliminate the use of ~/.conkerorrc in favor of a directory called > ~/.conkeror, which can contain pre-defined subdirectories for opensearch > files, opml files, themes, and whatever else we come up with. But let > us consider that as a project for the future. Yes, that sounds like a good plan. > > > If needed, there could be any kind of utility > > > to assist users in obtaining the opml file. > > > > Maybe gitweb-webjump-get-repository-list with a completer that lists > > the available gitweb webjumps. (I guess I'll need to mark those > > webjumps in some way; perhaps they'll have a gitweb_opml_file > > property.) > > A special buffer for listing the available opml files? The user still > has to enable them in the rc, so I don't see the point of this. But > maybe I misunderstand. I meant that gitweb-webjump-get-repository-list is a user command that prompts for the name of a webjump (with completion on gitweb webjumps only) and fetches the corresponding opml. The user would call this after having enabled the gitweb webjump. For the completion to work on the webjump name, the gitweb webjumps would need to be marked, and a gitweb_opml_file property would be a natural way to do that. -- IMPORTANT: This email remains the property of the Australian Defence Organisation and is subject to the jurisdiction of section 70 of the CRIMES ACT 1914. If you have received this email in error, you are requested to contact the sender and delete the email. From songcq at gmail.com Sun Feb 8 18:27:18 2009 From: songcq at gmail.com (Chengqi(Lars) Song) Date: Mon, 9 Feb 2009 10:27:18 +0800 Subject: [Conkeror] the git is extremely slow In-Reply-To: <87ljsgipxo.fsf@jeremyms.com> References: <20090207045919.GB7046@lars-x200s.ust.hk> <871vuao2ac.fsf@thinkpad.tsdh.de> <20090208083929.GA11577@lars-x200s.ust.hk> <8763jl2dw2.fsf@earthlink.net> <87ljsgipxo.fsf@jeremyms.com> Message-ID: <20090209022718.GA4832@lars-x200s.ust.hk> On Sun, 08 Feb 2009, Jeremy Maitin-Shepard wrote: hi, i can access the website of repo.or.cz without any lag. so it could be my git's problem or our network gate's problem. anyway, i can be sure that it should be my personal problem. thank you for your reminders. regards chengqi song > Philip Weaver writes: > Well, you could set up a mirror, I suppose. However, I haven't had any > problems with repo.or.cz so far. It seems just like a routing problem > that Chengqi Song is experiencing, though. > > Chengqi Song: Do you also find that the websites hosted on repo.or.cz > are slow as well, such as http://repo.or.cz/about.html ? > > -- > Jeremy Maitin-Shepard > _______________________________________________ > Conkeror mailing list > Conkeror at mozdev.org > https://www.mozdev.org/mailman/listinfo/conkeror From jjfoerch at earthlink.net Mon Feb 9 07:43:17 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Mon, 09 Feb 2009 10:43:17 -0500 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <1233982177-9981-3-git-send-email-kettler@internode.on.net> <87zlgy2d1q.fsf@earthlink.net> <498E40DB.9020906@internode.on.net> <87ab8x39l3.fsf@earthlink.net> <498E7ED5.504@internode.on.net> <871vu92dgv.fsf@earthlink.net> Message-ID: <878wof1uqy.fsf@earthlink.net> David Kettler writes: > I see that magick-options uses a preference; that's probably where I > got that idea. I guess that will also change in time. Actually, if > I'd paid more attention to that example, it would have been easier for > me to write the gitweb completer. BTW, thanks for updating it, which > I missed, for $alternative. I think the system we have worked out for gitweb-webjumps is a definite improvement over how magick-options works. > I meant that gitweb-webjump-get-repository-list is a user command that > prompts for the name of a webjump (with completion on gitweb webjumps > only) and fetches the corresponding opml. The user would call this > after having enabled the gitweb webjump. For the completion to work > on the webjump name, the gitweb webjumps would need to be marked, and > a gitweb_opml_file property would be a natural way to do that. This could be a job for a browser object class. If the current buffer is visiting a gitweb page, the browser object would be the corresponding OPML url for that gitweb. This browser object could be combined with the `save' command, as usual. I don't know what will end up being the best interface for getting these OPML files. We'll have to experiment. -- John Foerch From deniz.a.m.dogan at gmail.com Mon Feb 9 10:47:58 2009 From: deniz.a.m.dogan at gmail.com (Deniz Dogan) Date: Mon, 9 Feb 2009 19:47:58 +0100 Subject: [Conkeror] What do you want in a JavaScript editor? Message-ID: <7b501d5c0902091047o327dd204q2c6653689744661d@mail.gmail.com> Hi, everyone While this is not the exemplary place to ask this, I already know some of you guys, and some of you know me, so I figured it would be a nice place to start. I will be starting my MSc thesis soon in developing a JavaScript mode for the Yi editor (http://www.haskell.org/haskellwiki/Yi) in Haskell. I'm trying to think of functionality that users are missing from other editors so that I have that in the back of my head when writing this mode. So what do you *want* in a JavaScript editor? And what are you *missing* in the existing editors/modes? Thanks, Deniz Dogan From kettler at internode.on.net Tue Feb 10 02:12:26 2009 From: kettler at internode.on.net (David Kettler) Date: Tue, 10 Feb 2009 20:42:26 +1030 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. In-Reply-To: <878wof1uqy.fsf@earthlink.net> References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <1233982177-9981-3-git-send-email-kettler@internode.on.net> <87zlgy2d1q.fsf@earthlink.net> <498E40DB.9020906@internode.on.net> <87ab8x39l3.fsf@earthlink.net> <498E7ED5.504@internode.on.net> <871vu92dgv.fsf@earthlink.net> <878wof1uqy.fsf@earthlink.net> Message-ID: <4991530A.1080209@internode.on.net> >> I meant that gitweb-webjump-get-repository-list is a user command that >> prompts for the name of a webjump (with completion on gitweb webjumps >> only) and fetches the corresponding opml. The user would call this >> after having enabled the gitweb webjump. For the completion to work >> on the webjump name, the gitweb webjumps would need to be marked, and >> a gitweb_opml_file property would be a natural way to do that. > > This could be a job for a browser object class. If the current buffer > is visiting a gitweb page, the browser object would be the corresponding > OPML url for that gitweb. This browser object could be combined with > the `save' command, as usual. Perhaps. That has the (minor) disadvantage of requiring the user to visit the gitweb server before completion is available. > I don't know what will end up being the best interface for getting > these OPML files. We'll have to experiment. See what you think of the gitweb-webjump-get-opml command in my followup patch. regards, David. From kettler at internode.on.net Tue Feb 10 03:04:21 2009 From: kettler at internode.on.net (David Kettler) Date: Tue, 10 Feb 2009 21:34:21 +1030 Subject: [Conkeror] [PATCH v2] New module to define webjumps for git repository summaries. Message-ID: <1234263861-6761-1-git-send-email-kettler@internode.on.net> A webjump to access repositories at a gitweb server can be defined using define_gitweb_summary_webjump. The alternative url for the webjump can be a particular repository, the repository list or user defined. The default completer for the webjump will complete against the repositories available at the gitweb server. To enable this, the user must specify where to store the OPML data from the server (using either $opml_file or gitweb_webjumps_opml_directory) and fetch the data once using gitweb-webjump-get-opml. Examples: In your rc have: require("gitweb-webjump.js"); gitweb_webjumps_opml_directory = get_home_directory(); gitweb_webjumps_opml_directory.appendRelativePath(".conkerorrc/gitweb-webjumps-opml"); define_gitweb_summary_webjump("gitweb-ko", "http://git.kernel.org"); define_gitweb_summary_webjump("gitweb-cz", "http://repo.or.cz/w"); You can now use the following webjumps: gitweb-cz conkeror gitweb-ko git/git If you create the directory ~/.conkerorrc/gitweb-webjumps-opml/ and in conkeror use M-x gitweb-webjump-get-opml and select gitweb-cz then, once the download is finished, completions will be available for that webjump. With thanks to John Foerch for suggestions. --- This implements the changes as discussed with John. In particular, the completer uses local copies of the OPML data; auto fetching was too expensive. Rather than attaching the opml url and filename to the webjump, as I had suggested, I put them in the global gitweb_webjumps_opml. gitweb_webjump_completer could be changed to use all_word_completer. One difference in behaviour is that the former fills in the completion in the minibuffer when tab is pressed, but the latter does not. I'm not sure which is preferable. There are three remaining problems, all related to gitweb-webjump-get-opml. 1a) If you invoke gitweb-webjump-get-opml on gitweb-cz, and then attempt to use completion on that webjump while the download is in progress, conkeror will try to parse the incomplete file and fail. The fix is to download to a .temp file and then rename once it's complete. That should be supported in save_uri and the download manager so that the .temp suffix isn't visible in the UI. I'm surprised this isn't supported directly by the download engine; mozilla does download to a temporary. 1b) There seems to be another underlying problem (but this won't be an issue once (1a) is fixed). After the parser has failed once and the download is complete, retrying the completer causes the parser to fail again, this time erroneously. After restarting conkeror, the file parses fine. Here's a simpler way to reproduce: Have a copy of the opml in the right file for some site (eg. run gitweb-webjump-get-opml on it and wait for that to complete). Copy the opml file then truncate it from the middle of some line. Run this in conkeror (eg): M-: gitweb_webjump_get_completions_from_file(gitweb_webjumps_opml["gitweb-cz"].file) You get a malformed-xml error on the console, which is correct. Now overwrite the mangled file with the copy. Run the command again; you still get the error, which is wrong. 2) If you invoke gitweb-webjump-get-opml on gitweb-ko, an invalid OPML file results. The problem is that kernel.org helpfully puts up a "Generating.." page with a meta refresh . save_uri doesn't do the refresh. A work around is to visit the OPML link with find-url and save it to the right place; that will work fine. --- modules/gitweb-webjump.js | 173 +++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 173 insertions(+), 0 deletions(-) create mode 100644 modules/gitweb-webjump.js diff --git a/modules/gitweb-webjump.js b/modules/gitweb-webjump.js new file mode 100644 index 0000000..1a8317d --- /dev/null +++ b/modules/gitweb-webjump.js @@ -0,0 +1,173 @@ +/** + * (C) Copyright 2009 David Kettler + * + * Use, modification, and distribution are subject to the terms specified in the + * COPYING file. + * + * Construct a webjump (with completer) to visit repository summary + * pages at a gitweb server. +**/ + +require("webjump.js"); + +/* OPML files for completion on webjumps. */ +gitweb_webjumps_opml = {}; + +define_variable("gitweb_webjumps_opml_directory", null, + "A directory for storing the OPML data corresponding to a " + + "gitweb webjump; the data can be fetched using " + + "gitweb-webjump-get-opml. " + + "If the data is available for a webjump then it will provide " + + "completions for the available repositories."); + + +function parse_gitweb_completions_from_dom_node(doc) { + let elems = doc.getElementsByTagName("outline"); + + let completions = []; + for (let i = 0; i < elems.length; ++i) { + let node = elems[i]; + let type = node.getAttribute("type"); + let name = node.getAttribute("text"); + if (type == "rss" && name) + completions.push(name.replace(/\.git$/, "")); + } + completions.sort(); + + return completions; +} + + +function gitweb_webjump_get_completions_from_file(file) { + var file_istream = Cc["@mozilla.org/network/file-input-stream;1"] + .createInstance(Ci.nsIFileInputStream); + file_istream.init(file, MODE_RDONLY, 0644, false); + var dom_parser = Cc["@mozilla.org/xmlextras/domparser;1"] + .createInstance(Ci.nsIDOMParser); + var doc = dom_parser.parseFromStream(file_istream, "UTF-8", + file.fileSize, "text/xml"); + + return parse_gitweb_completions_from_dom_node(doc); +} + + +/** + * A completer that gets the list of repositories from the gitweb + * generated OPML. + */ +function gitweb_webjump_completer(opml_file) { + let completions = null; + let file_time = 0; + + return function (input, pos, conservative) { + if (pos == 0 && conservative) + yield co_return(undefined); + let str = input.substring(0,pos); + + if (opml_file.exists() && opml_file.lastModifiedTime > file_time) { + file_time = opml_file.lastModifiedTime; + completions = gitweb_webjump_get_completions_from_file(opml_file); + } + if (!completions) + yield co_return(null); + + let words = trim_whitespace(input.toLowerCase()).split(/\s+/); + let data = completions.filter(function (x) { + for (var i = 0; i < words.length; ++i) + if (x.toLowerCase().indexOf(words[i]) == -1) + return false; + return true; + }); + + let c = {count: data.length, + get_string: function (i) data[i], + get_description: function (i) data[i], + get_input_state: function (i) [data[i]]}; + yield co_return(c); + }; +} + + +/* buffer is used only to associate with the download */ +define_keywords("$buffer"); +function gitweb_webjump_get_opml(key) { + keywords(arguments); + let opml = gitweb_webjumps_opml[key]; + if (!opml) + return null; + save_uri(load_spec(opml.url), opml.file, + $buffer = arguments.$buffer, $use_cache = false); + return opml; +} + +interactive("gitweb-webjump-get-opml", + "Fetch the OPML data corresponding to a gitweb webjump from " + + "the gitweb server and make it available to the gitweb webjump " + + "completer.", + function (I) { + var completions = []; + for (let i in gitweb_webjumps_opml) + completions.push(i); + var key = yield I.minibuffer.read( + $prompt = "Get OPML for gitweb webjump:", + $history = "webjump", + $completer = all_word_completer($completions = completions), + $match_required = true); + gitweb_webjump_get_opml(key, $buffer = I.buffer); + }); + + +/** + * Construct a webjump to visit repository summary pages at a gitweb + * server. + * + * If a repository name is supplied as $default then the alternative + * url is set to that repository at the gitweb site. If an + * alternative is not specified by either $default or $alternative + * then it is set to the repository list page of the gitweb site. + * + * A completer is provided that uses the list of repositories from the + * OPML data on the gitweb server. A local file for the OPML data + * must be specified either with $opml_file or via + * gitweb_webjumps_opml_directory. The OPML data must be manually + * downloaded; eg. using gitweb-webjump-get-opml. Each time the + * completer is used it will check if the file has been updated and + * reload if necessary. + * + * A completer may instead be specified with $completer. + */ +define_keywords("$default", "$alternative", "$completer", "$opml_file"); +function define_gitweb_summary_webjump(key, base_url) { + keywords(arguments); + let completer = arguments.$completer; + let alternative = arguments.$alternative; + let gitweb_url = base_url + "/gitweb.cgi"; + let summary_url = gitweb_url + "?p=%s.git;a=summary"; + let opml_url = gitweb_url + "?a=opml"; + + let opml_file = arguments.$opml_file; + if (typeof opml_file == 'string') + opml_file = make_file(opml_file); + if (!opml_file && gitweb_webjumps_opml_directory) { + opml_file = Cc["@mozilla.org/file/local;1"] + .createInstance(Ci.nsILocalFile); + if (gitweb_webjumps_opml_directory instanceof Ci.nsILocalFile) + opml_file.initWithFile(gitweb_webjumps_opml_directory); + else + opml_file.initWithPath(gitweb_webjumps_opml_directory); + opml_file.appendRelativePath(key + ".opml"); + } + + if (!completer && opml_file) { + completer = gitweb_webjump_completer(opml_file); + gitweb_webjumps_opml[key] = {file: opml_file, url: opml_url}; + } + if (arguments.$default) + alternative = summary_url.replace("%s", arguments.$default); + if (!alternative) + alternative = gitweb_url; + + define_webjump(key, summary_url, + $completer = completer, + $alternative = alternative); +} -- 1.5.6.5 From jjfoerch at earthlink.net Tue Feb 10 09:12:04 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Tue, 10 Feb 2009 12:12:04 -0500 Subject: [Conkeror] [PATCH] New module to define webjumps for git repository summaries. References: <1233982177-9981-1-git-send-email-kettler@internode.on.net> <1233982177-9981-2-git-send-email-kettler@internode.on.net> <1233982177-9981-3-git-send-email-kettler@internode.on.net> <87zlgy2d1q.fsf@earthlink.net> <498E40DB.9020906@internode.on.net> <87ab8x39l3.fsf@earthlink.net> <498E7ED5.504@internode.on.net> <871vu92dgv.fsf@earthlink.net> <878wof1uqy.fsf@earthlink.net> <4991530A.1080209@internode.on.net> Message-ID: <87zlguz063.fsf@earthlink.net> David Kettler writes: >>> I meant that gitweb-webjump-get-repository-list is a user command that >>> prompts for the name of a webjump (with completion on gitweb webjumps >>> only) and fetches the corresponding opml. The user would call this >>> after having enabled the gitweb webjump. For the completion to work >>> on the webjump name, the gitweb webjumps would need to be marked, and >>> a gitweb_opml_file property would be a natural way to do that. >> >> This could be a job for a browser object class. If the current buffer >> is visiting a gitweb page, the browser object would be the corresponding >> OPML url for that gitweb. This browser object could be combined with >> the `save' command, as usual. > > Perhaps. That has the (minor) disadvantage of requiring the user to > visit the gitweb server before completion is available. > >> I don't know what will end up being the best interface for getting >> these OPML files. We'll have to experiment. > > See what you think of the gitweb-webjump-get-opml command in my > followup patch. > > regards, David. Looks good to me. Sounds like gitweb-webjump-get-opml needs to chase redirects for kernel.org. Or what if there was a command called gitweb-webjump-visit-opml instead of, or in addition to gitweb-webjump-get-opml? -- John Foerch From rohan.nicholls at googlemail.com Wed Feb 11 01:55:22 2009 From: rohan.nicholls at googlemail.com (Rohan Nicholls) Date: Wed, 11 Feb 2009 10:55:22 +0100 Subject: [Conkeror] run-conkeror script tweak Message-ID: Hi all, I have been really enjoying using run-conkeror, but have noticed that it takes the first xulrunner config it finds in whichever directory it is using. I just use the default /etc/gre.d/*.conf on xubuntu. The problem is that every time xulrunner gets upgraded the run-conkeror script becomes broken because it finds the old conf and tries to call an executable that does not exist. I finally thought I would take a look, and after muddling my way through the very cool one-liner, I made a change and it worked, so it now grabs the largest version number it finds. Attached is the patch. Hope this helps someone. :) Rohan -------------- next part -------------- A non-text attachment was scrubbed... Name: run-conkeror.patch Type: text/x-diff Size: 463 bytes Desc: not available URL: From kettler at internode.on.net Wed Feb 11 03:24:20 2009 From: kettler at internode.on.net (David Kettler) Date: Wed, 11 Feb 2009 21:54:20 +1030 Subject: [Conkeror] [PATCH] save_uri: optionally use a temporary download file Message-ID: <1234351460-3924-1-git-send-email-kettler@internode.on.net> This is useful when it is undesirable for some other tool to attempt to open the downloaded file before it is complete. If $temp_file is specified then the uri is downloaded to that file and then renamed to the output_file when the download is finished. If $temp_file is the value true then a new temporary file in the same directory as output_file is used. The download manager indicates this by showing the output_file name parenthetically. Note that this save_uri usage of the term "temporary" is different to the download-manager usage; in that case the file is deleted, not renamed. --- In particular this addresses problem (1a) discussed in "[PATCH v2] New module to define webjumps for git repository summaries". I added another property, finished_function, to download_info. It would be possible to use download_finished_hook, but that's probably inappropriate for internal functionality like this. It would be possible to subsume the shell_command stuff into finished_function. The file rename will foil download-delete-target. I was undecided as to whether that should be fixed or if it's better as is. The deletion uses download_manager_service.removeDownload(this.id); so it will either need to be handled separately, or the state of the nsIDownloadManager will need fiddling. --- modules/download-manager.js | 14 +++++++++++++- modules/save.js | 17 +++++++++++++++-- 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/modules/download-manager.js b/modules/download-manager.js index dda61b7..bc1f292 100644 --- a/modules/download-manager.js +++ b/modules/download-manager.js @@ -181,6 +181,8 @@ download_info.prototype = { download_added_hook.run(this); }, + finished_function : null, + shell_command : null, shell_command_cwd : null, @@ -203,6 +205,7 @@ download_info.prototype = { // Reflectors to properties of nsIDownload get state () { return this.mozilla_info.state; }, get target_file () { return this.mozilla_info.targetFile; }, + get display_name () { return this.mozilla_info.displayName; }, get amount_transferred () { return this.mozilla_info.amountTransferred; }, get percent_complete () { return this.mozilla_info.percentComplete; }, get size () { @@ -428,6 +431,9 @@ var download_progress_listener = { if (info.state == DOWNLOAD_FINISHED) { download_finished_hook.run(info); + if (info.finished_function != null) + info.finished_function(); + if (info.shell_command != null) { info.running_shell_command = true; co_call(function () { @@ -719,7 +725,13 @@ download_buffer.prototype = { target_label = "Target:"; g.text(target_label, label); value = g.element("div", div, "class", "download-value"); - g.text(info.target_file.path, value); + { + let target = info.target_file.path; + let display = info.display_name; + if (target.indexOf(display, target.length - display.length) == -1) + target = target + " (" + display + ")"; + g.text(target, value); + } div = g.element("div", d.body, "class", "download-info", "id", "download-mime-type"); label = g.element("div", div, "class", "download-label"); diff --git a/modules/save.js b/modules/save.js index 23e7115..3228411 100644 --- a/modules/save.js +++ b/modules/save.js @@ -12,7 +12,7 @@ require("load-spec.js"); require("suggest-file-name.js"); /* buffer is used only to associate with the download */ -define_keywords("$use_cache", "$buffer", "$prepare_download"); +define_keywords("$use_cache", "$buffer", "$prepare_download", "$temp_file"); function save_uri(lspec, output_file) { keywords(arguments, $use_cache = true); @@ -22,6 +22,15 @@ function save_uri(lspec, output_file) { var prepare_download = arguments.$prepare_download; + var temp_file = arguments.$temp_file; + if (temp_file == true) { + temp_file = Cc["@mozilla.org/file/local;1"] + .createInstance(Ci.nsILocalFile); + temp_file.initWithFile(output_file); + temp_file.leafName = "temp"; + temp_file.createUnique(Ci.nsIFile.NORMAL_FILE_TYPE, 0666); + } + var cache_key = null; var uri = load_spec_uri(lspec); var referrer_uri = load_spec_referrer(lspec); @@ -29,7 +38,7 @@ function save_uri(lspec, output_file) { if (use_cache) cache_key = load_spec_cache_key(lspec); - var file_uri = make_uri(output_file); + var file_uri = make_uri(temp_file || output_file); var persist = Cc["@mozilla.org/embedding/browser/nsWebBrowserPersist;1"] .createInstance(Ci.nsIWebBrowserPersist); @@ -45,6 +54,10 @@ function save_uri(lspec, output_file) { persist.persistFlags |= Ci.nsIWebBrowserPersist.PERSIST_FLAGS_BYPASS_CACHE; var info = register_download(buffer, uri); + if (temp_file) + info.finished_function = function() { + temp_file.moveTo(null, output_file.leafName); + }; if (prepare_download) prepare_download(info); -- 1.5.6.5 From jjfoerch at earthlink.net Wed Feb 11 09:35:48 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Wed, 11 Feb 2009 12:35:48 -0500 Subject: [Conkeror] run-conkeror script tweak References: Message-ID: <87vdrgzxjf.fsf@earthlink.net> Rohan Nicholls writes: > Hi all, > > I have been really enjoying using run-conkeror, but have noticed that > it takes the first xulrunner config it finds in whichever directory it > is using. > > I just use the default /etc/gre.d/*.conf on xubuntu. The problem is > that every time xulrunner gets upgraded the run-conkeror script > becomes broken because it finds the old conf and tries to call an > executable that does not exist. > > I finally thought I would take a look, and after muddling my way > through the very cool one-liner, I made a change and it worked, so it > now grabs the largest version number it finds. Attached is the patch. > > Hope this helps someone. :) Thank you. -- John Foerch From jeremy at jeremyms.com Wed Feb 11 12:29:11 2009 From: jeremy at jeremyms.com (Jeremy Maitin-Shepard) Date: Wed, 11 Feb 2009 12:29:11 -0800 Subject: [Conkeror] [PATCH] save_uri: optionally use a temporary download file In-Reply-To: <1234351460-3924-1-git-send-email-kettler@internode.on.net> (David Kettler's message of "Wed, 11 Feb 2009 21:54:20 +1030") References: <1234351460-3924-1-git-send-email-kettler@internode.on.net> Message-ID: <87bpt8hg4o.fsf@jeremyms.com> David Kettler writes: [snip] > I added another property, finished_function, to download_info. It > would be possible to use download_finished_hook, but that's probably > inappropriate for internal functionality like this. It would be > possible to subsume the shell_command stuff into finished_function. I think it makes sense to use download_finished_hook, even though this is functionality of the download manager itself, since it adds less overhead and I don't see any reason not to. The shell command handling is done specially because the download buffer displays information about the shell command. > The file rename will foil download-delete-target. I was undecided as > to whether that should be fixed or if it's better as is. The deletion uses > download_manager_service.removeDownload(this.id); > so it will either need to be handled separately, or the state of the > nsIDownloadManager will need fiddling. The built-in file saving uses a temporary file as well; perhaps this can somehow make use of some of the same facilities for handling that? -- Jeremy Maitin-Shepard From kettler at internode.on.net Thu Feb 12 02:36:12 2009 From: kettler at internode.on.net (David Kettler) Date: Thu, 12 Feb 2009 21:06:12 +1030 Subject: [Conkeror] [PATCH] save_uri: optionally use a temporary download file In-Reply-To: <87bpt8hg4o.fsf@jeremyms.com> References: <1234351460-3924-1-git-send-email-kettler@internode.on.net> <87bpt8hg4o.fsf@jeremyms.com> Message-ID: <4993FB9C.6010006@internode.on.net> >> I added another property, finished_function, to download_info. It >> would be possible to use download_finished_hook, but that's probably >> inappropriate for internal functionality like this. It would be >> possible to subsume the shell_command stuff into finished_function. > > I think it makes sense to use download_finished_hook, even though this > is functionality of the download manager itself, since it adds less > overhead and I don't see any reason not to. I've done so in the follow up patch, but I'm not pleased with it. > The shell command handling > is done specially because the download buffer displays information about > the shell command. Yes, I see. The temporary download also has special info displayed, but it uses the existing displayName property for that. >> The file rename will foil download-delete-target. I was undecided as >> to whether that should be fixed or if it's better as is. The deletion uses >> download_manager_service.removeDownload(this.id); >> so it will either need to be handled separately, or the state of the >> nsIDownloadManager will need fiddling. That's fixed in the followup, but required changes to the way target_file is managed. > The built-in file saving uses a temporary file as well; perhaps this can > somehow make use of some of the same facilities for handling that? I'm making use of displayName; I don't think there's much more we can use. I'm only going by the doco though; I haven't examined the firefox code. regards, David. From kettler at internode.on.net Thu Feb 12 02:47:37 2009 From: kettler at internode.on.net (David Kettler) Date: Thu, 12 Feb 2009 21:17:37 +1030 Subject: [Conkeror] [Patch v2] save_uri: optionally use a temporary download file In-Reply-To: <4993FB9C.6010006@internode.on.net> References: <4993FB9C.6010006@internode.on.net> Message-ID: <1234435657-5659-1-git-send-email-kettler@internode.on.net> This is useful when it is undesirable for some other tool to attempt to open the downloaded file before it is complete. If $temp_file is specified then the uri is downloaded to that file and then renamed to the output_file when the download is finished. If $temp_file is the value true then a new temporary file in the same directory as output_file is used. The download manager indicates this by showing the output_file name parenthetically. Note that this save_uri usage of the term "temporary" is different to the download-manager usage; in that case the file is deleted, not renamed. --- This version uses download_finished_hook. I'm not sure that's worked out well; I preferred the former version. I attach a hook for each download, then remove it again in the hook function; that's a bit yucky. Maybe it would be better to have a single hook function, but also to attach a finished_function to the info object. The hook could call that function, if it's defined. That wouldn't require changes to download-manager for defining or calling finished_function. This version also fixes download-delete-target so that it will still function properly. It does this by changing target_file to reflect the rename. To do this it was necessary to separate target_file from the service property targetFile, because the latter is immutable. --- modules/download-manager.js | 21 ++++++++++++++++----- modules/save.js | 21 ++++++++++++++++++--- 2 files changed, 34 insertions(+), 8 deletions(-) diff --git a/modules/download-manager.js b/modules/download-manager.js index 888ef6a..65724e3 100644 --- a/modules/download-manager.js +++ b/modules/download-manager.js @@ -169,13 +169,18 @@ const DOWNLOAD_NOT_TEMPORARY = 0; const DOWNLOAD_TEMPORARY_FOR_ACTION = 1; const DOWNLOAD_TEMPORARY_FOR_COMMAND = 2; -function download_info(source_buffer, mozilla_info) { +function download_info(source_buffer, mozilla_info, target_file) { this.source_buffer = source_buffer; + this.target_file = target_file; if (mozilla_info != null) this.attach(mozilla_info); } download_info.prototype = { attach : function (mozilla_info) { + if (!this.target_file) + target_file = this.mozilla_info.targetFile; + else if (this.target_file.path != mozilla_info.targetFile.path) + throw interactive_error("Download target file unexpected."); this.mozilla_info = mozilla_info; id_to_download_info[mozilla_info.id] = this; download_added_hook.run(this); @@ -202,7 +207,7 @@ download_info.prototype = { // Reflectors to properties of nsIDownload get state () { return this.mozilla_info.state; }, - get target_file () { return this.mozilla_info.targetFile; }, + get display_name () { return this.mozilla_info.displayName; }, get amount_transferred () { return this.mozilla_info.amountTransferred; }, get percent_complete () { return this.mozilla_info.percentComplete; }, get size () { @@ -357,8 +362,8 @@ download_info.prototype = { var define_download_local_hook = simple_local_hook_definer(); // FIXME: add more parameters -function register_download(buffer, source_uri) { - var info = new download_info(buffer); +function register_download(buffer, source_uri, target_file) { + var info = new download_info(buffer, null, target_file); info.registered_time_stamp = Date.now(); info.registered_source_uri = source_uri; unmanaged_download_info_list.push(info); @@ -719,7 +724,13 @@ download_buffer.prototype = { target_label = "Target:"; g.text(target_label, label); value = g.element("div", div, "class", "download-value"); - g.text(info.target_file.path, value); + { + let target = info.target_file.path; + let display = info.display_name; + if (target.indexOf(display, target.length - display.length) == -1) + target = target + " (" + display + ")"; + g.text(target, value); + } div = g.element("div", d.body, "class", "download-info", "id", "download-mime-type"); label = g.element("div", div, "class", "download-label"); diff --git a/modules/save.js b/modules/save.js index 23e7115..0a7e3ea 100644 --- a/modules/save.js +++ b/modules/save.js @@ -12,7 +12,7 @@ require("load-spec.js"); require("suggest-file-name.js"); /* buffer is used only to associate with the download */ -define_keywords("$use_cache", "$buffer", "$prepare_download"); +define_keywords("$use_cache", "$buffer", "$prepare_download", "$temp_file"); function save_uri(lspec, output_file) { keywords(arguments, $use_cache = true); @@ -22,6 +22,15 @@ function save_uri(lspec, output_file) { var prepare_download = arguments.$prepare_download; + let temp_file = arguments.$temp_file; + if (temp_file == true) { + temp_file = Cc["@mozilla.org/file/local;1"] + .createInstance(Ci.nsILocalFile); + temp_file.initWithFile(output_file); + temp_file.leafName = "temp"; + temp_file.createUnique(Ci.nsIFile.NORMAL_FILE_TYPE, 0666); + } + var cache_key = null; var uri = load_spec_uri(lspec); var referrer_uri = load_spec_referrer(lspec); @@ -29,7 +38,7 @@ function save_uri(lspec, output_file) { if (use_cache) cache_key = load_spec_cache_key(lspec); - var file_uri = make_uri(output_file); + var file_uri = make_uri(temp_file || output_file); var persist = Cc["@mozilla.org/embedding/browser/nsWebBrowserPersist;1"] .createInstance(Ci.nsIWebBrowserPersist); @@ -44,7 +53,13 @@ function save_uri(lspec, output_file) { else persist.persistFlags |= Ci.nsIWebBrowserPersist.PERSIST_FLAGS_BYPASS_CACHE; - var info = register_download(buffer, uri); + var info = register_download(buffer, uri, temp_file || output_file); + if (temp_file) + add_hook("download_finished_hook", function(info) { + remove_hook("download_finished_hook", arguments.callee); + temp_file.moveTo(null, output_file.leafName); + info.target_file.leafName = output_file.leafName; + }); if (prepare_download) prepare_download(info); -- 1.5.6.5 From rohan.nicholls at googlemail.com Sat Feb 14 01:00:07 2009 From: rohan.nicholls at googlemail.com (Rohan Nicholls) Date: Sat, 14 Feb 2009 10:00:07 +0100 Subject: [Conkeror] What do you want in a JavaScript editor? In-Reply-To: <7b501d5c0902091047o327dd204q2c6653689744661d@mail.gmail.com> References: <7b501d5c0902091047o327dd204q2c6653689744661d@mail.gmail.com> Message-ID: I am no expert in this, but if you are dealing with a mode for editting javascript files, as opposed to something that is mixed (like html, css, javascript) you would be hard pressed to beat js2.el for emacs written by Steve Yegge. It checks your syntax in real-time, because he embedded a complete js parser, it handles various versions of javascript, including rhino extensions etc. I have not used it enough to see if it does any form of completion, but it would not surprise me. Anyway, if you google up Steve Yegge and javascript he gives a good rundown of what he was up to, and of course the code is freely available. Good luck with you project. Rohan On Mon, Feb 9, 2009 at 7:47 PM, Deniz Dogan wrote: > Hi, everyone > > While this is not the exemplary place to ask this, I already know some > of you guys, and some of you know me, so I figured it would be a nice > place to start. > > I will be starting my MSc thesis soon in developing a JavaScript mode > for the Yi editor (http://www.haskell.org/haskellwiki/Yi) in Haskell. > I'm trying to think of functionality that users are missing from other > editors so that I have that in the back of my head when writing this > mode. > > So what do you *want* in a JavaScript editor? And what are you > *missing* in the existing editors/modes? > > Thanks, > Deniz Dogan > _______________________________________________ > Conkeror mailing list > Conkeror at mozdev.org > https://www.mozdev.org/mailman/listinfo/conkeror > From deniz.a.m.dogan at gmail.com Sat Feb 14 04:06:02 2009 From: deniz.a.m.dogan at gmail.com (Deniz Dogan) Date: Sat, 14 Feb 2009 13:06:02 +0100 Subject: [Conkeror] What do you want in a JavaScript editor? In-Reply-To: References: <7b501d5c0902091047o327dd204q2c6653689744661d@mail.gmail.com> Message-ID: <7b501d5c0902140406g6ed2617aq53474c17291da4a@mail.gmail.com> I know about js2-mode and use it sometimes, but I noticed how sluggish it got when I was editing the Conkeror source code at modules/utils.js (specifically the end of it, if that matters). This is something which I'm aiming for to improve in my own JavaScript-mode using the Yi incremental parser which looks very promising. Thanks for your input! 2009/2/14 Rohan Nicholls : > I am no expert in this, but if you are dealing with a mode for > editting javascript files, as > opposed to something that is mixed (like html, css, javascript) you > would be hard > pressed to beat js2.el for emacs written by Steve Yegge. It checks your syntax > in real-time, because he embedded a complete js parser, it handles various > versions of javascript, including rhino extensions etc. > > I have not used it enough to see if it does any form of completion, > but it would not surprise > me. > > Anyway, if you google up Steve Yegge and javascript he gives a good rundown of > what he was up to, and of course the code is freely available. > > Good luck with you project. > > Rohan > > On Mon, Feb 9, 2009 at 7:47 PM, Deniz Dogan wrote: >> Hi, everyone >> >> While this is not the exemplary place to ask this, I already know some >> of you guys, and some of you know me, so I figured it would be a nice >> place to start. >> >> I will be starting my MSc thesis soon in developing a JavaScript mode >> for the Yi editor (http://www.haskell.org/haskellwiki/Yi) in Haskell. >> I'm trying to think of functionality that users are missing from other >> editors so that I have that in the back of my head when writing this >> mode. >> >> So what do you *want* in a JavaScript editor? And what are you >> *missing* in the existing editors/modes? >> >> Thanks, >> Deniz Dogan >> _______________________________________________ >> Conkeror mailing list >> Conkeror at mozdev.org >> https://www.mozdev.org/mailman/listinfo/conkeror >> > From hippely at gmail.com Sat Feb 14 08:25:31 2009 From: hippely at gmail.com (Matthew Hippely) Date: Sat, 14 Feb 2009 09:25:31 -0700 Subject: [Conkeror] What do you want in a JavaScript editor? In-Reply-To: References: <7b501d5c0902091047o327dd204q2c6653689744661d@mail.gmail.com> Message-ID: Hi Rohan, If you are using emacs + js2 mode you can easily get completion with a really cool minor mode called yasnippets (stands for Yet Another Snippet - i think) check it out here: http://code.google.com/p/yasnippet/ The cool thing about yasnippets is that you can define your own completions and base them on mode and it works with any mode that you tell it to. On Feb 14, 2009, at 2:00 AM, Rohan Nicholls wrote: > I am no expert in this, but if you are dealing with a mode for > editting javascript files, as > opposed to something that is mixed (like html, css, javascript) you > would be hard > pressed to beat js2.el for emacs written by Steve Yegge. It checks > your syntax > in real-time, because he embedded a complete js parser, it handles > various > versions of javascript, including rhino extensions etc. > > I have not used it enough to see if it does any form of completion, > but it would not surprise > me. > > Anyway, if you google up Steve Yegge and javascript he gives a good > rundown of > what he was up to, and of course the code is freely available. > > Good luck with you project. > > Rohan > > On Mon, Feb 9, 2009 at 7:47 PM, Deniz Dogan > wrote: >> Hi, everyone >> >> While this is not the exemplary place to ask this, I already know >> some >> of you guys, and some of you know me, so I figured it would be a nice >> place to start. >> >> I will be starting my MSc thesis soon in developing a JavaScript mode >> for the Yi editor (http://www.haskell.org/haskellwiki/Yi) in Haskell. >> I'm trying to think of functionality that users are missing from >> other >> editors so that I have that in the back of my head when writing this >> mode. >> >> So what do you *want* in a JavaScript editor? And what are you >> *missing* in the existing editors/modes? >> >> Thanks, >> Deniz Dogan >> _______________________________________________ >> Conkeror mailing list >> Conkeror at mozdev.org >> https://www.mozdev.org/mailman/listinfo/conkeror >> > _______________________________________________ > Conkeror mailing list > Conkeror at mozdev.org > https://www.mozdev.org/mailman/listinfo/conkeror From kettler at internode.on.net Wed Feb 18 03:57:19 2009 From: kettler at internode.on.net (David Kettler) Date: Wed, 18 Feb 2009 22:27:19 +1030 Subject: [Conkeror] [PATCH] webjumps: manage alternative url explicitly, not in handler functions Message-ID: <1234958239-4542-1-git-send-email-kettler@internode.on.net> If no arguments are supplied to a webjump and an alternative url is available, then the webjump system will visit the alternative url. Handler functions are no longer concerned with the alternative url. --- modules/search-engine.js | 5 +---- modules/webjump.js | 17 +++++++++-------- 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/modules/search-engine.js b/modules/search-engine.js index 3836b01..51f8ffa 100644 --- a/modules/search-engine.js +++ b/modules/search-engine.js @@ -333,10 +333,7 @@ function define_search_engine_webjump(search_engine_name, key) { define_webjump(key, function (arg) { - if (arg == null && alternative) - return alternative - else - return eng.get_query_load_spec(arg); + return eng.get_query_load_spec(arg); }, $alternative = alternative, $description = eng.description, diff --git a/modules/webjump.js b/modules/webjump.js index e4b8456..7ca9c48 100644 --- a/modules/webjump.js +++ b/modules/webjump.js @@ -18,11 +18,11 @@ function define_webjump(key, handler) { // handler may be a function or a string. An alternative url may // be passed using the $alternative keyword; it is used in place // of the handler when no arguments are supplied by the user when - // invoking the webjump. For string webjumps that contain %s and - // for which no alternative is provided, an alternative is - // autogenerated by trimming the path from the url. A webjump can - // thus function both as a way to invoke a search and as a - // bookmark. + // invoking the webjump (see getWebJump). For string webjumps + // that contain %s and for which no alternative is provided, an + // alternative is autogenerated by trimming the path from the url. + // A webjump can thus function both as a way to invoke a search + // and as a bookmark. // // The argument property may be false (no arguments will be // accepted for the webjump), true (arguments are required for the @@ -49,8 +49,6 @@ function define_webjump(key, handler) { var b = template.indexOf('%s'); return function (arg) { var a = b + 2; - if (arg == null && alternative) - return alternative; // Just return the same string if it doesn't contain a %s if (b == -1) return template; @@ -65,7 +63,8 @@ function define_webjump(key, handler) { handler: handler, completer: arguments.$completer, description: arguments.$description, - argument: argument }; + argument: argument, + alternative: alternative}; } @@ -181,6 +180,8 @@ function getWebJump(value) if (!res) return null; let [match,key,arg] = res; + if (arg == null && match.alternative) + return match.alternative; return match.handler(arg); } -- 1.5.6.5 From kettler at internode.on.net Wed Feb 18 04:01:51 2009 From: kettler at internode.on.net (David Kettler) Date: Wed, 18 Feb 2009 22:31:51 +1030 Subject: [Conkeror] [PATCH 1/2] download manager: show display name, allow target file name to change Message-ID: <1234958512-4612-1-git-send-email-kettler@internode.on.net> The download manager will now update the display of the target file name each time there is a change in download state. If the display name differs from the (basename of) the target name, it is shown parenthetically. Changes to the names in hooks are thus reflected in the display. The download manager handling of the target file is changed. It is now maintained explicitly and can be specified in register_download. This is necessary because the targetFile property is immutable. These changes allow, for instance, downloads to a file with a temporary name that is changed to the final name when the download is finished. --- modules/download-manager.js | 27 ++++++++++++++++++++++----- 1 files changed, 22 insertions(+), 5 deletions(-) diff --git a/modules/download-manager.js b/modules/download-manager.js index 888ef6a..3fd146a 100644 --- a/modules/download-manager.js +++ b/modules/download-manager.js @@ -169,18 +169,25 @@ const DOWNLOAD_NOT_TEMPORARY = 0; const DOWNLOAD_TEMPORARY_FOR_ACTION = 1; const DOWNLOAD_TEMPORARY_FOR_COMMAND = 2; -function download_info(source_buffer, mozilla_info) { +function download_info(source_buffer, mozilla_info, target_file) { this.source_buffer = source_buffer; + this.target_file = target_file; if (mozilla_info != null) this.attach(mozilla_info); } download_info.prototype = { attach : function (mozilla_info) { + if (!this.target_file) + target_file = this.mozilla_info.targetFile; + else if (this.target_file.path != mozilla_info.targetFile.path) + throw interactive_error("Download target file unexpected."); this.mozilla_info = mozilla_info; id_to_download_info[mozilla_info.id] = this; download_added_hook.run(this); }, + target_file : null, + shell_command : null, shell_command_cwd : null, @@ -202,7 +209,7 @@ download_info.prototype = { // Reflectors to properties of nsIDownload get state () { return this.mozilla_info.state; }, - get target_file () { return this.mozilla_info.targetFile; }, + get display_name () { return this.mozilla_info.displayName; }, get amount_transferred () { return this.mozilla_info.amountTransferred; }, get percent_complete () { return this.mozilla_info.percentComplete; }, get size () { @@ -227,6 +234,14 @@ download_info.prototype = { get id () { return this.mozilla_info.id; }, get referrer () { return this.mozilla_info.referrer; }, + target_file_text : function() { + let target = this.target_file.path; + let display = this.display_name; + if (target.indexOf(display, target.length - display.length) == -1) + target += " (" + display + ")"; + return target; + }, + throw_if_removed : function () { if (this.removed) throw interactive_error("Download has already been removed from the download manager."); @@ -357,8 +372,8 @@ download_info.prototype = { var define_download_local_hook = simple_local_hook_definer(); // FIXME: add more parameters -function register_download(buffer, source_uri) { - var info = new download_info(buffer); +function register_download(buffer, source_uri, target_file) { + var info = new download_info(buffer, null, target_file); info.registered_time_stamp = Date.now(); info.registered_source_uri = source_uri; unmanaged_download_info_list.push(info); @@ -599,6 +614,7 @@ download_buffer.prototype = { // Remove all node references delete this.status_textnode; + delete this.target_file_node; delete this.transferred_div_node; delete this.transferred_textnode; delete this.progress_container_node; @@ -719,7 +735,7 @@ download_buffer.prototype = { target_label = "Target:"; g.text(target_label, label); value = g.element("div", div, "class", "download-value"); - g.text(info.target_file.path, value); + this.target_file_node = g.text("", value); div = g.element("div", d.body, "class", "download-info", "id", "download-mime-type"); label = g.element("div", div, "class", "download-label"); @@ -791,6 +807,7 @@ download_buffer.prototype = { break; } this.status_textnode.nodeValue = label + ":"; + this.target_file_node.nodeValue = info.target_file_text(); this.update_time_field(); var tran_text = ""; -- 1.5.6.5 From kettler at internode.on.net Wed Feb 18 04:01:52 2009 From: kettler at internode.on.net (David Kettler) Date: Wed, 18 Feb 2009 22:31:52 +1030 Subject: [Conkeror] [PATCH 2/2 (v3)] save_uri: optionally use a temporary download file In-Reply-To: <1234958512-4612-1-git-send-email-kettler@internode.on.net> References: <1234958512-4612-1-git-send-email-kettler@internode.on.net> Message-ID: <1234958512-4612-2-git-send-email-kettler@internode.on.net> This is useful when it is undesirable for some other tool to attempt to open the downloaded file before it is complete. If $temp_file is specified then the uri is downloaded to that file and then renamed to the output_file when the download is finished. If $temp_file is the value true then a new temporary file in the same directory as output_file is used. The download manager indicates this by showing the temp_file name with the output_file name following parenthetically. When the download is complete and the file is renamed, the download manager will update to show the new name. Note that this save_uri usage of the term "temporary" is different to the download-manager usage; in that case the file is deleted, not renamed. --- This third version differs from the second in that: - The proper local hook is used. This lets us update before the download buffer and means we don't need to remove the function from the hook. It also prevents the hook firing on the wrong download. - The target file name shown in the download buffer will update after the rename. - The download manager changes are separate. - Correct test for temp_file===true. --- modules/save.js | 28 +++++++++++++++++++++++++--- 1 files changed, 25 insertions(+), 3 deletions(-) diff --git a/modules/save.js b/modules/save.js index 23e7115..9ed4794 100644 --- a/modules/save.js +++ b/modules/save.js @@ -12,7 +12,7 @@ require("load-spec.js"); require("suggest-file-name.js"); /* buffer is used only to associate with the download */ -define_keywords("$use_cache", "$buffer", "$prepare_download"); +define_keywords("$use_cache", "$buffer", "$prepare_download", "$temp_file"); function save_uri(lspec, output_file) { keywords(arguments, $use_cache = true); @@ -22,6 +22,19 @@ function save_uri(lspec, output_file) { var prepare_download = arguments.$prepare_download; + var download_file = output_file; + + var temp_file = arguments.$temp_file; + if (temp_file === true) { + temp_file = Cc["@mozilla.org/file/local;1"] + .createInstance(Ci.nsILocalFile); + temp_file.initWithFile(output_file); + temp_file.leafName = "temp"; + temp_file.createUnique(Ci.nsIFile.NORMAL_FILE_TYPE, 0666); + } + if (temp_file) + download_file = temp_file; + var cache_key = null; var uri = load_spec_uri(lspec); var referrer_uri = load_spec_referrer(lspec); @@ -29,7 +42,7 @@ function save_uri(lspec, output_file) { if (use_cache) cache_key = load_spec_cache_key(lspec); - var file_uri = make_uri(output_file); + var file_uri = make_uri(download_file); var persist = Cc["@mozilla.org/embedding/browser/nsWebBrowserPersist;1"] .createInstance(Ci.nsIWebBrowserPersist); @@ -44,7 +57,16 @@ function save_uri(lspec, output_file) { else persist.persistFlags |= Ci.nsIWebBrowserPersist.PERSIST_FLAGS_BYPASS_CACHE; - var info = register_download(buffer, uri); + var info = register_download(buffer, uri, download_file); + if (temp_file) { + // We want this hook so that we run before the download buffer updates. + add_hook.call(info, "download_state_change_hook", function() { + if (info.state == DOWNLOAD_FINISHED) { + temp_file.moveTo(null, output_file.leafName); + info.target_file.leafName = output_file.leafName; + } + }); + } if (prepare_download) prepare_download(info); -- 1.5.6.5 From jjfoerch at earthlink.net Wed Feb 18 08:53:14 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Wed, 18 Feb 2009 11:53:14 -0500 Subject: [Conkeror] [PATCH] webjumps: manage alternative url explicitly, not in handler functions References: <1234958239-4542-1-git-send-email-kettler@internode.on.net> Message-ID: <874oyrk7ph.fsf@earthlink.net> David Kettler writes: > If no arguments are supplied to a webjump and an alternative url is > available, then the webjump system will visit the alternative url. > Handler functions are no longer concerned with the alternative url. Looks good! -- John Foerch From jjfoerch at earthlink.net Thu Feb 19 09:01:49 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Thu, 19 Feb 2009 12:01:49 -0500 Subject: [Conkeror] Scrolling eye guide References: <87d4kedkwo.fsf@notebook.home> <87zliif4bs.fsf@yahoo.com> <87y6xw2hjx.fsf@earthlink.net> <87hc3jsfax.fsf@CPU107.opentrends.net> <87bpto7qe9.fsf@earthlink.net> Message-ID: <87r61uicn6.fsf@earthlink.net> Conkeror now has a feature like this.. a bit of a different implementation, but you can use it like this: require('eye-guide.js'); define_key(content_buffer_normal_keymap, "space", "eye-guide-scroll-down"); define_key(content_buffer_normal_keymap, "back_space", "eye-guide-scroll-up"); -- John Foerch From jjfoerch at earthlink.net Fri Feb 20 08:48:38 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Fri, 20 Feb 2009 11:48:38 -0500 Subject: [Conkeror] browser_prevent_automatic_form_focus_mode disabled Message-ID: <87hc2pt5p5.fsf@earthlink.net> Hi all, browser_prevent_automatic_form_focus_mode is no longer enabled by default. A lot of people have reported a bug related to it whereby clicking on a form element during page load does not focus the element. So until the problem can be fixed, and the mode can consistently tell the difference between a click event originating from the user and a click event originating from the web page, this mode will no longer be enabled by default. If you want to use it, put the following in your rc: browser_prevent_automatic_form_focus_mode(true); -- John Foerch From jjfoerch at earthlink.net Fri Feb 20 08:49:59 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Fri, 20 Feb 2009 11:49:59 -0500 Subject: [Conkeror] [PATCH 1/2] download manager: show display name, allow target file name to change References: <1234958512-4612-1-git-send-email-kettler@internode.on.net> Message-ID: <87d4ddt5mw.fsf@earthlink.net> David Kettler writes: > The download manager will now update the display of the target file > name each time there is a change in download state. If the display > name differs from the (basename of) the target name, it is shown > parenthetically. Changes to the names in hooks are thus reflected in > the display. > > The download manager handling of the target file is changed. It is > now maintained explicitly and can be specified in register_download. > This is necessary because the targetFile property is immutable. > > These changes allow, for instance, downloads to a file with a > temporary name that is changed to the final name when the download is > finished. Sounds like a good feature. When you have tested it to your satisfaction, please push. -- John Foerch From jjfoerch at earthlink.net Fri Feb 20 08:51:04 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Fri, 20 Feb 2009 11:51:04 -0500 Subject: [Conkeror] [PATCH 2/2 (v3)] save_uri: optionally use a temporary download file References: <1234958512-4612-1-git-send-email-kettler@internode.on.net> <1234958512-4612-2-git-send-email-kettler@internode.on.net> Message-ID: <878wo1t5l3.fsf@earthlink.net> David Kettler writes: > This is useful when it is undesirable for some other tool to attempt > to open the downloaded file before it is complete. > > If $temp_file is specified then the uri is downloaded to that file and > then renamed to the output_file when the download is finished. If > $temp_file is the value true then a new temporary file in the same > directory as output_file is used. > > The download manager indicates this by showing the temp_file name with > the output_file name following parenthetically. When the download is > complete and the file is renamed, the download manager will update to > show the new name. > > Note that this save_uri usage of the term "temporary" is different to > the download-manager usage; in that case the file is deleted, not > renamed. Sounds good. -- John Foerch From kettler at internode.on.net Sat Feb 21 04:55:54 2009 From: kettler at internode.on.net (David Kettler) Date: Sat, 21 Feb 2009 23:25:54 +1030 Subject: [Conkeror] [PATCH 1/2] download manager: show display name, allow target file name to change In-Reply-To: <87d4ddt5mw.fsf@earthlink.net> References: <1234958512-4612-1-git-send-email-kettler@internode.on.net> <87d4ddt5mw.fsf@earthlink.net> Message-ID: <499FF9DA.8000907@internode.on.net> > Sounds like a good feature. When you have tested it to your > satisfaction, please push. I've pushed these, along with an updated gitweb-webjump that makes use of the temporary file download. Thanks again for your reviews, John. regards, David From jjfoerch at earthlink.net Sat Feb 21 14:35:02 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 21 Feb 2009 17:35:02 -0500 Subject: [Conkeror] [PATCH 1/2] download manager: show display name, allow target file name to change References: <1234958512-4612-1-git-send-email-kettler@internode.on.net> <87d4ddt5mw.fsf@earthlink.net> <499FF9DA.8000907@internode.on.net> Message-ID: <87skm78lm1.fsf@earthlink.net> David Kettler writes: >> Sounds like a good feature. When you have tested it to your >> satisfaction, please push. > > I've pushed these, along with an updated gitweb-webjump that makes use > of the temporary file download. > > Thanks again for your reviews, John. > > regards, David Very nice. Here is how I am using gitweb-webjump in my config: (there is a nice symmetry to this config) define_gitweb_summary_webjump("repo.or.cz", "http://repo.or.cz/w", $alternative = "http://repo.or.cz/"); Works nicely. -- John Foerch From jjfoerch at earthlink.net Sat Feb 21 20:06:51 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sat, 21 Feb 2009 23:06:51 -0500 Subject: [Conkeror] [PATCH 1/2] download manager: show display name, allow target file name to change References: <1234958512-4612-1-git-send-email-kettler@internode.on.net> <87d4ddt5mw.fsf@earthlink.net> <499FF9DA.8000907@internode.on.net> Message-ID: <87mycf8690.fsf@earthlink.net> David Kettler writes: >> Sounds like a good feature. When you have tested it to your >> satisfaction, please push. > > I've pushed these, along with an updated gitweb-webjump that makes use > of the temporary file download. > > Thanks again for your reviews, John. > > regards, David Hi David, I am having problems downloading files since "download manager: show display name, allow target file name to change". The file downloads in the background, but I get no download buffer, and conkeror spews errors: error: encountered unknown download in progress change error: encountered unknown download in progress change error: encountered unknown download in progress change I was noticing that even before these patches, mozilla used a temporary file with the extension ".part" while downloading a file. So I am not sure that your adding explicit support for a temp file was even necessary. What's your experience on this? Thanks, -- John Foerch From kettler at internode.on.net Sun Feb 22 03:55:50 2009 From: kettler at internode.on.net (David Kettler) Date: Sun, 22 Feb 2009 22:25:50 +1030 Subject: [Conkeror] [PATCH 1/2] download manager: show display name, allow target file name to change In-Reply-To: <87mycf8690.fsf@earthlink.net> References: <1234958512-4612-1-git-send-email-kettler@internode.on.net> <87d4ddt5mw.fsf@earthlink.net> <499FF9DA.8000907@internode.on.net> <87mycf8690.fsf@earthlink.net> Message-ID: <49A13D46.4040200@internode.on.net> > I am having problems downloading files since "download manager: show > display name, allow target file name to change". The file downloads in > the background, but I get no download buffer, and conkeror spews errors: > > error: encountered unknown download in progress change > error: encountered unknown download in progress change > error: encountered unknown download in progress change Sorry, John, I broke it. I've just pushed a fix. See commit message included below for further info. > I was noticing that even before these patches, mozilla used a > temporary file with the extension ".part" while downloading a file. So > I am not sure that your adding explicit support for a temp file was even > necessary. What's your experience on this? I hadn't realized that there are two ways to save files. The save command uses the saveURI method of nsWebBrowserPersist, while visiting a download link ends up using the saveToDisk method of nsIHelperAppLauncherDialog. The latter does the .part thing. I was aware of the functionality from having previously used iceape, but I didn't realize that it is in the xul code that conkeror uses too. The saveURI method does not offer anything similar, so I implemented the temp file work around. If save_uri could use the nsIHelperAppLauncherDialog method then my temp file code won't be needed. That would be great. regards, David. --8<-- download manager: display downloads properly again Commit 080e20e (download manager: show display name, allow target file name to change, 2009-02-18) broke the download manager display of most downloads. There are two separate interfaces for downloading files that use different methods; (1) the save interactive command and (2) choosing "save" in response to the "Action to perform" prompt when visiting a download url. That commit was tested for case (1) but not case (2). The one line of code changed in this commit had two errors; this.mozilla_info was not yet set (it is set a couple of lines later) and mozilla_info.targetFile is not set at the time that attach() is called. The fix restores the previous behaviour of target_file being a getter, if it is not already set. It may be that the two methods could be changed to use the same underlying interface and so simplify this code and obviate the need for the changes in commit 9645e93 (save_uri: optionally use a temporary download file, 2009-02-18). From jjfoerch at earthlink.net Sun Feb 22 07:37:11 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Sun, 22 Feb 2009 10:37:11 -0500 Subject: [Conkeror] [PATCH 1/2] download manager: show display name, allow target file name to change References: <1234958512-4612-1-git-send-email-kettler@internode.on.net> <87d4ddt5mw.fsf@earthlink.net> <499FF9DA.8000907@internode.on.net> <87mycf8690.fsf@earthlink.net> <49A13D46.4040200@internode.on.net> Message-ID: <87iqn2lbyw.fsf@earthlink.net> David Kettler writes: >> I am having problems downloading files since "download manager: show >> display name, allow target file name to change". The file downloads in >> the background, but I get no download buffer, and conkeror spews errors: >> >> error: encountered unknown download in progress change >> error: encountered unknown download in progress change >> error: encountered unknown download in progress change > > Sorry, John, I broke it. I've just pushed a fix. See commit message > included below for further info. > Great, thank you for the quick fix. > I hadn't realized that there are two ways to save files. The save > command uses the saveURI method of nsWebBrowserPersist, while visiting > a download link ends up using the saveToDisk method of > nsIHelperAppLauncherDialog. The latter does the .part thing. I was > aware of the functionality from having previously used iceape, but I > didn't realize that it is in the xul code that conkeror uses too. The > saveURI method does not offer anything similar, so I implemented the > temp file work around. If save_uri could use the > nsIHelperAppLauncherDialog method then my temp file code won't be > needed. That would be great. Okay. This can be delayed until later. If you have any good ideas about better abstration, feel free. Without having looked closely at the code in a while, the idea of only using nsIHelperAppLauncherDialog rings an alarm in my mind because by its name, it is obviously intended for use in dialogs, which is not the case with save_uri. -- John Foerch From dcl441-bugs at yahoo.com Tue Feb 24 11:02:30 2009 From: dcl441-bugs at yahoo.com (Daniel Clemente) Date: Tue, 24 Feb 2009 20:02:30 +0100 Subject: [Conkeror] Scrolling eye guide References: <87d4kedkwo.fsf@notebook.home> <87zliif4bs.fsf@yahoo.com> <87y6xw2hjx.fsf@earthlink.net> <87hc3jsfax.fsf@CPU107.opentrends.net> <87bpto7qe9.fsf@earthlink.net> <87r61uicn6.fsf@earthlink.net> Message-ID: <87vdqz4q0p.fsf@CPU107.opentrends.net> El dj, feb 19 2009, John J Foerch va escriure: > Conkeror now has a feature like this.. a bit of a different > implementation, but you can use it like this: > Thanks, this works well, and it's also easy to change the CSS (color, opacity, ?). At first it seemed a very big bar (50px) but it is useful in this way. I suppose this can be closed. http://bugs.conkeror.org/issue113 From abe at deuxchevaux.org Tue Feb 24 17:09:17 2009 From: abe at deuxchevaux.org (Axel Beckert) Date: Wed, 25 Feb 2009 02:09:17 +0100 Subject: [Conkeror] Icon suggestion for Conkeror Message-ID: <20090225010917.GJ5399@sym.noone.org> Hi, as some people on #conkeror liked the CC-BY-SA-3.0 licensed image at http://en.wikipedia.org/wiki/File:Conker.jpg and at least the idea of using it as Conkeror logo was floating around, I played around a little bit with Gimp and made a transparent square image out of it by removing the shadow: http://noone.org/tmp/Conker.tr.png The Gimp sources are at: http://noone.org/tmp/Conker.xcf.bz2 How to make it an application icon is explained at https://developer.mozilla.org/En/Window_icons Instead of XPM images, PNG images seem to be fine, too. And I would prefer PNG images due to their alpha channel. On my Debian Linux box with xulrunner 1.9.0.6 I have Conkeror successfully running using the above mentioned PNG as launch button and application icon (in the title bar of the window as well as in the task bar). Anybody else in favour of using this image as preliminary icon for conkeror? Comments? Regards, Axel -- Axel Beckert - abe at deuxchevaux.org, abe at noone.org - http://noone.org/abe/ From mashdot at toshine.net Wed Feb 25 04:02:22 2009 From: mashdot at toshine.net ('Mash) Date: Wed, 25 Feb 2009 12:02:22 +0000 Subject: [Conkeror] Icon suggestion for Conkeror In-Reply-To: <20090225010917.GJ5399@sym.noone.org> References: <20090225010917.GJ5399@sym.noone.org> Message-ID: <20090225120222.GF3851@grace.toshine.net> Nice! I had just made a web button for my upcoming site last weekend but maybe I can squeeze a conker in instead of a dinosaur. http://toshine.net/media/conkeror.png 'Mash On 2009-02-25 02:09+0100, Axel Beckert wrote: > Hi, > > as some people on #conkeror liked the CC-BY-SA-3.0 licensed image at > > http://en.wikipedia.org/wiki/File:Conker.jpg > > and at least the idea of using it as Conkeror logo was floating > around, I played around a little bit with Gimp and made a transparent > square image out of it by removing the shadow: > > http://noone.org/tmp/Conker.tr.png > > The Gimp sources are at: > > http://noone.org/tmp/Conker.xcf.bz2 > > How to make it an application icon is explained at > > https://developer.mozilla.org/En/Window_icons > > Instead of XPM images, PNG images seem to be fine, too. And I would > prefer PNG images due to their alpha channel. > > On my Debian Linux box with xulrunner 1.9.0.6 I have Conkeror > successfully running using the above mentioned PNG as launch button > and application icon (in the title bar of the window as well as in the > task bar). > > Anybody else in favour of using this image as preliminary icon for > conkeror? Comments? > > Regards, Axel > -- > Axel Beckert - abe at deuxchevaux.org, abe at noone.org - http://noone.org/abe/ > _______________________________________________ > Conkeror mailing list > Conkeror at mozdev.org > https://www.mozdev.org/mailman/listinfo/conkeror From jjfoerch at earthlink.net Wed Feb 25 16:11:54 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Wed, 25 Feb 2009 19:11:54 -0500 Subject: [Conkeror] Scrolling eye guide References: <87d4kedkwo.fsf@notebook.home> <87zliif4bs.fsf@yahoo.com> <87y6xw2hjx.fsf@earthlink.net> <87hc3jsfax.fsf@CPU107.opentrends.net> <87bpto7qe9.fsf@earthlink.net> <87r61uicn6.fsf@earthlink.net> <87vdqz4q0p.fsf@CPU107.opentrends.net> Message-ID: <87d4d6qcol.fsf@earthlink.net> Daniel Clemente writes: > El dj, feb 19 2009, John J Foerch va escriure: >> Conkeror now has a feature like this.. a bit of a different >> implementation, but you can use it like this: >> > > Thanks, this works well, and it's also easy to change the CSS (color, opacity, ?). At first it seemed a very big bar (50px) but it is useful in this way. > > I suppose this can be closed. http://bugs.conkeror.org/issue113 Thanks, done. -- John Foerch From deniz.a.m.dogan at gmail.com Wed Feb 25 17:43:56 2009 From: deniz.a.m.dogan at gmail.com (Deniz Dogan) Date: Thu, 26 Feb 2009 02:43:56 +0100 Subject: [Conkeror] Change the name of Conkeror, quickly! Message-ID: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> Hello, fellow Conkeror users This is a public service announcement! There has been much discussion in the IRC channel about changing the name of the web browser. I think I'm probably the most eager one to change the name, so please know that this is a very biased post. Also know that this is pretty important to have this discussion right now, since people are pulling strings to have an official logo made for us. The main reason for *me* wanting to change the name is that it is pronounced the exact same way as Konqueror, a KDE web browser and file manager, with a much bigger user base. This has confused people I've talked to about the browser a lot and seeing as KDE was first released way back in 2000, it was a terrible choice for a new web browser to begin with. I have no law degree, but I suspect that some legal issues may arise from this as well. Of course, there are reasons for keeping the name as well, but personally, I don't think they make up for the fact that another browser is called the same thing. One of the reasons for not changing the name that comes up frequently is that it would be "too difficult" to change the name. Sure, it would be difficult *now*, but consider how difficult it would be if the user base was to grow drastically in the future. Then we would have quite some (chest)nut to crack. Another reason for not changing the name is that the name is nice. I agree, it is a nice name -- it's just that it's already taken that bothers me. What do you think about the current name? Why should we change it? Why should we keep it? How should we make a final decision about it? And if you want to change the name, what would you like it to be called instead? Deniz From brian at microcomaustralia.com.au Wed Feb 25 19:59:58 2009 From: brian at microcomaustralia.com.au (Brian May) Date: Thu, 26 Feb 2009 14:59:58 +1100 Subject: [Conkeror] Change the name of Conkeror, quickly! In-Reply-To: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> Message-ID: <49A613BE.40703@microcomaustralia.com.au> Deniz Dogan wrote: > The main reason for *me* wanting to change the name is that it is > pronounced the exact same way as Konqueror, a KDE web browser and file > manager, with a much bigger user base. This has confused people I've > talked to about the browser a lot and seeing as KDE was first released > way back in 2000, it was a terrible choice for a new web browser to > begin with. I have no law degree, but I suspect that some legal issues > may arise from this as well. > I have to say "Conkeror spelt with a C". It *is* confusing. Changing the name now may be a lot of work though... -- Brian May From aditya.siram at gmail.com Wed Feb 25 22:02:27 2009 From: aditya.siram at gmail.com (aditya siram) Date: Thu, 26 Feb 2009 00:02:27 -0600 Subject: [Conkeror] Bookmarking a page to Delicious account Message-ID: <594f78210902252202t700672b7u79018064e5be6411@mail.gmail.com> Hi all, Is there a way to bookmark a page directly to my Delicious account? So I am reading a page, I type a command and my account is updated. Thanks .. Deech -------------- next part -------------- An HTML attachment was scrubbed... URL: From artagnon at gmail.com Wed Feb 25 23:46:37 2009 From: artagnon at gmail.com (Ramkumar R) Date: Thu, 26 Feb 2009 13:16:37 +0530 Subject: [Conkeror] Change the name of Conkeror, quickly! In-Reply-To: <49A613BE.40703@microcomaustralia.com.au> References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> <49A613BE.40703@microcomaustralia.com.au> Message-ID: > I have to say "Conkeror spelt with a C". > > It *is* confusing. > > Changing the name now may be a lot of work though... I'm strongly in favor of the name change, primarily because of the confusion with Konqueror. Better change it now, when the project is at its initial stages, than later. I can't think of any names at the moment, but on a related note, we might want to subtly include the word 'Emacs' in some form in the name. From tassilo at member.fsf.org Thu Feb 26 00:00:53 2009 From: tassilo at member.fsf.org (Tassilo Horn) Date: Thu, 26 Feb 2009 09:00:53 +0100 Subject: [Conkeror] Change the name of Conkeror, quickly! References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> Message-ID: <871vtly6dm.fsf@thinkpad.tsdh.de> Deniz Dogan writes: Hi Deniz, > What do you think about the current name? Well, personally I don't care too much, but I agree with your "sounds like konqueror" argument. > How should we make a final decision about it? If no developer has a strong feeling about the issue, we could collect suggestions on the wiki for some weeks and then mako a poll. > And if you want to change the name, what would you like it to be > called instead? I'd like to shown its relation to emacs in the name, so maybe something like webmacs or netmacs would be appropriate. Or an acronym? CIEFTI (Conkeror Is Emacs For The Internet) Bye, Tassilo -- Richard Stallman's compiler is afraid to report errors. From abe at deuxchevaux.org Thu Feb 26 02:56:55 2009 From: abe at deuxchevaux.org (Axel Beckert) Date: Thu, 26 Feb 2009 11:56:55 +0100 Subject: [Conkeror] Change the name of Conkeror, quickly! (Name ideas and suggestions) In-Reply-To: <871vtly6dm.fsf@thinkpad.tsdh.de> References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> <871vtly6dm.fsf@thinkpad.tsdh.de> Message-ID: <20090226105655.GR5399@sym.noone.org> Hi, On Thu, Feb 26, 2009 at 09:00:53AM +0100, Tassilo Horn wrote: > > And if you want to change the name, what would you like it to be > > called instead? > > I'd like to shown its relation to emacs in the name, Yeah, and maybe Gecko or XULRunner, too. (Not sure about Mozilla itself, though. :-) Geckomacs? Xulmacs? (We would get a Ghostbusters reference for free! ;-) Mozmacs? (Sounds horrible in German: motzen = grouching) Firemacs? (No, it's no Firefox anymore, so not that one. :-) > so maybe something like webmacs or netmacs would be appropriate. "webmacs" seems quite obvious, that name came to my mind yesterday when the discussion started again, too. But I still prefer something funny. Conkeror has that Nature/Beer/Game/Children/Winner allusions and I would like to keep at least some of them. Not easy together with http://en.wikipedia.org/wiki/Conkers has some other names for the game Conkers and those were already mentioned (I wouldn't write "suggested" ;-) on IRC: + Obblyonkers + Cheggies + Cheesers If we choose one of them, we should probably go for the singular version and call it Obblyyonker, Cheggy or Cheeser. > Or an acronym? > > CIEFTI (Conkeror Is Emacs For The Internet) CINK? Conkeror is not Konqueror? ;-) Hmmm. EMACS FTW! Ehm. No, not "Emacs for the win", but: Escape Meta Alt Control Shift for the Web. (SCNR and forget that suggestion quickly again! ;-) Regards, Axel -- Axel Beckert - abe at deuxchevaux.org, abe at noone.org - http://noone.org/abe/ From abe at deuxchevaux.org Thu Feb 26 03:26:31 2009 From: abe at deuxchevaux.org (Axel Beckert) Date: Thu, 26 Feb 2009 12:26:31 +0100 Subject: [Conkeror] Change the name of Conkeror, quickly! (Discussion) In-Reply-To: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> Message-ID: <20090226112631.GS5399@sym.noone.org> Hi, On Thu, Feb 26, 2009 at 02:43:56AM +0100, Deniz Dogan wrote: > The main reason for *me* wanting to change the name is that it is > pronounced the exact same way as Konqueror, a KDE web browser and file > manager, with a much bigger user base. This has confused people I've > talked to about the browser a lot Here, too. Wouldn't be as worse if it wasn't a web browser, too. But remember: Firefox changed its name twice before it was known as Firefox, once because of a legal threat by Phoenix Inc. (because they called it Phoenix initially and Phoenix offered a web browser feature in some of their BIOSes) and then because there was another Open Source project called Firebird (a database system, not a web browser) and so they renamed it finally to Firefox. > I have no law degree, but I suspect that some legal issues may arise > from this as well. Not sure about that. I would expect that if someone sees it as a problem, the lawsuit would have been already made. IMHO and IANAL. > Of course, there are reasons for keeping the name as well, but > personally, I don't think they make up for the fact that another > browser is called the same thing. One of the reasons for not > changing the name that comes up frequently is that it would be "too > difficult" to change the name. Not too difficult. But a lot of work and loss. > Sure, it would be difficult *now*, but consider how difficult it > would be if the user base was to grow drastically in the future. That's an argument indeed. > Then we would have quite some (chest)nut to crack. Not sure if it would be really more difficult. We already have two websites, a mailing list, a git repository, an Ohloh project page[1] (summasummarum 5 URLs to change -- and "Good URLs never change"), a Debian package (no big deal though, software renames have well known procedures in Debian). [1] https://www.ohloh.net/p/5294 But the later we change the name the bigger the impact would be, there you are right. Another thing which bothers me with the rename is the domain conkeror.org. If we have to use another domain (which seems unavoidable), we need a proper redirect from conkeror.org(*) and we have to keep them for a long time, not only until conkeror.org expires -- because people are lazy and never change their links. So if we let conkeror.org expire, it will get catched by link spammer and will cause quite some harm. (*) The redirect has to be a "301 moved permanently", not a "302 found" nor a "307 moved temporarily" nor one of those ugly "meta refreshes" -- only a "permanent Redirect" can change bookmarks, feed readers or search engines to change the saved URL. Additionally, I don't know if we are able to make redirects on repo.or.cz or conkeror.mozdev.org. Same counts for the ML (well, we could perhaps make the new ML the only susbscriber) if we rename conkeror. The Ohloh project page is probably not important here, since only a very few people link there and most links pointing there are Ohloh internal links. > Another reason for not changing the name is that the name is nice. I > agree, it is a nice name The current name has indeed some meaning and history. We would probably throw away that one, too. Well, I guess some of us wouldn't be too unhappy if we could throw away this beer story that way. ;-) > it's just that it's already taken that bothers me. s/it's/its pronounciation/ Regards, Axel -- Axel Beckert - abe at deuxchevaux.org, abe at noone.org - http://noone.org/abe/ From mashdot at toshine.net Thu Feb 26 04:39:07 2009 From: mashdot at toshine.net ('Mash) Date: Thu, 26 Feb 2009 12:39:07 +0000 Subject: [Conkeror] Change the name of Conkeror, quickly! (Name ideas and suggestions) In-Reply-To: <20090226105655.GR5399@sym.noone.org> References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> <871vtly6dm.fsf@thinkpad.tsdh.de> <20090226105655.GR5399@sym.noone.org> Message-ID: <20090226123907.GI3851@grace.toshine.net> Horse Chestnuts "Conkers" (genus Aesculus) Call the browser "aEsculus" or "aESCculus" You could even keep the Conker as the icon for the browser. 'Mash --- http://toshine.org On 2009-02-26 11:56+0100, Axel Beckert wrote: > Hi, > > On Thu, Feb 26, 2009 at 09:00:53AM +0100, Tassilo Horn wrote: > > > And if you want to change the name, what would you like it to be > > > called instead? > > > > I'd like to shown its relation to emacs in the name, > From abe at deuxchevaux.org Thu Feb 26 06:29:57 2009 From: abe at deuxchevaux.org (Axel Beckert) Date: Thu, 26 Feb 2009 15:29:57 +0100 Subject: [Conkeror] Change the name of Conkeror, quickly! (Name ideas and suggestions) In-Reply-To: <20090226123907.GI3851@grace.toshine.net> References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> <871vtly6dm.fsf@thinkpad.tsdh.de> <20090226105655.GR5399@sym.noone.org> <20090226123907.GI3851@grace.toshine.net> Message-ID: <20090226142957.GT5399@sym.noone.org> Hi, On Thu, Feb 26, 2009 at 12:39:07PM +0000, 'Mash wrote: > Horse Chestnuts "Conkers" (genus Aesculus) > > Call the browser "aEsculus" or "aESCculus" Sounds like Aesculap to me and that reminds of doctors. > You could even keep the Conker as the icon for the browser. Ehm, why don't we just move from Conkeror to Conker (or Conkers)? That's not so far away, has nearly the same history, jokes, allusions and anecdotes, but is not already another browser and is shorter. :-) *google* Oh, I see (and now I also remember), there was a video game where the main character was named Conker: http://en.wikipedia.org/wiki/Conker's_Bad_Fur_Day So basically I reduce the suggestion to "Conkers" which is a plural and probably therefore not really perfect. Anyway, had to get rid of this brain dump... Regards, Axel -- Axel Beckert - abe at deuxchevaux.org, abe at noone.org - http://noone.org/abe/ From stefan-husmann at t-online.de Thu Feb 26 07:03:47 2009 From: stefan-husmann at t-online.de (stefan-husmann at t-online.de) Date: Thu, 26 Feb 2009 16:03:47 +0100 Subject: [Conkeror] =?iso-8859-15?q?FW=3A_Re=3A__Change_the_name_of_Conker?= =?iso-8859-15?q?or=2C_quickly!?= Message-ID: <1Lchm7-0LeBiS0@fwd11.aul.t-online.de> -----Original Message----- Date: Thu, 26 Feb 2009 16:02:32 +0100 Subject: Re: [Conkeror] Change the name of Conkeror, quickly! From: "stefan-husmann at t-online.de" To: "Deniz Dogan" -----Original Message----- > Date: Thu, 26 Feb 2009 02:43:56 +0100 > Subject: [Conkeror] Change the name of Conkeror, quickly! > From: Deniz Dogan > To: conkeror list > Hello, fellow Conkeror users > > This is a public service announcement! There has been much discussion > in the IRC channel about changing the name of the web browser. I think > I'm probably the most eager one to change the name, so please know > that this is a very biased post. Also know that this is pretty > important to have this discussion right now, since people are pulling > strings to have an official logo made for us. > > The main reason for *me* wanting to change the name is that it is > pronounced the exact same way as Konqueror, a KDE web browser and file > manager, with a much bigger user base. This has confused people I've > talked to about the browser a lot and seeing as KDE was first released > way back in 2000, it was a terrible choice for a new web browser to > begin with. I have no law degree, but I suspect that some legal issues > may arise from this as well. > > Of course, there are reasons for keeping the name as well, but > personally, I don't think they make up for the fact that another > browser is called the same thing. One of the reasons for not changing > the name that comes up frequently is that it would be "too difficult" > to change the name. Sure, it would be difficult *now*, but consider > how difficult it would be if the user base was to grow drastically in > the future. Then we would have quite some (chest)nut to crack. Another > reason for not changing the name is that the name is nice. I agree, it > is a nice name -- it's just that it's already taken that bothers me. > > What do you think about the current name? Why should we change it? Why > should we keep it? How should we make a final decision about it? And > if you want to change the name, what would you like it to be called > instead? > > Deniz > _______________________________________________ > Conkeror mailing list > Conkeror at mozdev.org > https://www.mozdev.org/mailman/listinfo/conkeror > Hello, what about "Trajan"? ?It is an ancient roman imperator under whose reign the roman empire had its biggest expanse. There is only a commercial Adobe font with the same name. Regards Stefan From songcq at gmail.com Thu Feb 26 07:29:13 2009 From: songcq at gmail.com (Chengqi(Lars) Song) Date: Thu, 26 Feb 2009 23:29:13 +0800 Subject: [Conkeror] FW: Re: Change the name of Conkeror, quickly! In-Reply-To: <1Lchm7-0LeBiS0@fwd11.aul.t-online.de> References: <1Lchm7-0LeBiS0@fwd11.aul.t-online.de> Message-ID: <20090226152913.GA4745@lars-x200s.ust.hk> i would vote for webmacs, simple and explicit :) by this name everyone can tell that it is a emacs-like web browser without more 'google'ing. - lars From artagnon at gmail.com Thu Feb 26 07:33:36 2009 From: artagnon at gmail.com (Ramkumar R) Date: Thu, 26 Feb 2009 21:03:36 +0530 Subject: [Conkeror] FW: Re: Change the name of Conkeror, quickly! In-Reply-To: <20090226152913.GA4745@lars-x200s.ust.hk> References: <1Lchm7-0LeBiS0@fwd11.aul.t-online.de> <20090226152913.GA4745@lars-x200s.ust.hk> Message-ID: > i would vote for webmacs, simple and explicit :) Simple works. I like webmacs too. From jjfoerch at earthlink.net Thu Feb 26 09:20:15 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Thu, 26 Feb 2009 12:20:15 -0500 Subject: [Conkeror] Change the name of Conkeror, quickly! References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> Message-ID: <87wsbdw1ww.fsf@earthlink.net> Hi all, Conkeror is a pretty good name. It has a nice sound to it, and the word origin gives it a classical feeling. Let's not lose sight of that in haste to change it. If we are going to change the name, we should change it to something *better*, something with its own unique aesthetic. So here are my requests to all who are brainstorming for new names: * no stupid puns * conkeror is *not* an emacs emulator. no names that imply it is one. * no browser war references I also have a strong preference against acronyms, because they are annoying to read. A well-planned name change could be used to our advantage as an opportunity to make some needed changes like the structure of the user startup files, as well as some changes of convenience such as the ID string of the program. That said, we are in no rush and we would do ourselves a disservice to rush a change and end up with a worse name than we have. Thanks! -- John Foerch From richardlewis at fastmail.co.uk Thu Feb 26 09:37:07 2009 From: richardlewis at fastmail.co.uk (Richard Lewis) Date: Thu, 26 Feb 2009 17:37:07 +0000 Subject: [Conkeror] Change the name of Conkeror, quickly! In-Reply-To: <87wsbdw1ww.fsf@earthlink.net> References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> <87wsbdw1ww.fsf@earthlink.net> Message-ID: <878wntaym4.wl%richard.lewis@gold.ac.uk> Hi all, At Thu, 26 Feb 2009 12:20:15 -0500, John J Foerch wrote: > > So here are my requests to all who are brainstorming for new > names: > > * no stupid puns > Yes, they always sound a bit amateurish. And make it difficult to *talk* about a piece of software because you feel self-conscious saying the name; you feel as though every time you mention it you also need to explain (or excuse) it. > > I also have a strong preference against acronyms, because they > are annoying to read. > Agreed. Some acronyms become sufficiently well known to take on the status of words in their own right eventually (such as Emacs). But that takes years. I really liked 'Mash's suggestion of "Aesculus" (in that capitalisation). It's good for googling as it only has one other meaning. It sounds sort of trendy and cool. It's a name that you can imagine saying to a colleague without feeling self-conscious. Two to four syllables is generally optimal for names of things. Unless the consonants are very pronounced, one syllable names are more difficult to make clear in speech. And five or more syllables is a bit of a mouthful. The 'c' has potential for being rendered as a conker in a logo. Best, Richard -- -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Richard Lewis ISMS, Computing Goldsmiths, University of London Tel: +44 (0)20 7078 5134 Skype: richardjlewis JID: ironchicken at jabber.earth.li http://www.richard-lewis.me.uk/ -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- +-------------------------------------------------------+ |Please avoid sending me Word or PowerPoint attachments.| |http://www.gnu.org/philosophy/no-word-attachments.html | +-------------------------------------------------------+ From dcl441-bugs at yahoo.com Thu Feb 26 11:39:26 2009 From: dcl441-bugs at yahoo.com (Daniel Clemente) Date: Thu, 26 Feb 2009 20:39:26 +0100 Subject: [Conkeror] Where to go after a tab is closed Message-ID: <87ljrt2djl.fsf@CPU107.opentrends.net> Hi, I see that when you close a buffer, focus goes to the buffer which was active before the ex-buffer was selected. I think I would prefer to go always to the buffer to the right of the buffer which I'm killing. (note: ?right? == ?right, as seen in the tab bar?). This is because I'm mostly working with buffers at the right. Is it easy to change that behaviour? What changes could I try in kill_buffer? Thanks, Daniel From nick at servo.cc Thu Feb 26 12:18:47 2009 From: nick at servo.cc (Nicholas A. Zigarovich) Date: Thu, 26 Feb 2009 15:18:47 -0500 Subject: [Conkeror] Change the name of Conkeror, quickly! In-Reply-To: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> Message-ID: <49A6F927.9000005@servo.cc> Submit your suggestions here on the list or at the wiki: http://conkeror.org/NameChange - Nick Deniz Dogan wrote: > Hello, fellow Conkeror users > > This is a public service announcement! There has been much discussion > in the IRC channel about changing the name of the web browser. I think > I'm probably the most eager one to change the name, so please know > that this is a very biased post. Also know that this is pretty > important to have this discussion right now, since people are pulling > strings to have an official logo made for us. > > The main reason for *me* wanting to change the name is that it is > pronounced the exact same way as Konqueror, a KDE web browser and file > manager, with a much bigger user base. This has confused people I've > talked to about the browser a lot and seeing as KDE was first released > way back in 2000, it was a terrible choice for a new web browser to > begin with. I have no law degree, but I suspect that some legal issues > may arise from this as well. > > Of course, there are reasons for keeping the name as well, but > personally, I don't think they make up for the fact that another > browser is called the same thing. One of the reasons for not changing > the name that comes up frequently is that it would be "too difficult" > to change the name. Sure, it would be difficult *now*, but consider > how difficult it would be if the user base was to grow drastically in > the future. Then we would have quite some (chest)nut to crack. Another > reason for not changing the name is that the name is nice. I agree, it > is a nice name -- it's just that it's already taken that bothers me. > > What do you think about the current name? Why should we change it? Why > should we keep it? How should we make a final decision about it? And > if you want to change the name, what would you like it to be called > instead? > > Deniz > _______________________________________________ > Conkeror mailing list > Conkeror at mozdev.org > https://www.mozdev.org/mailman/listinfo/conkeror > From levy at msri.org Thu Feb 26 12:59:20 2009 From: levy at msri.org (Silvio Levy) Date: Thu, 26 Feb 2009 12:59:20 -0800 Subject: [Conkeror] Change the name of Conkeror, quickly! In-Reply-To: Your message of Thu, 26 Feb 2009 15:18:47 -0500 Message-ID: <20090226205920.72A11DFC2@xi.msri.org> My suggestion is TenFingers. For the browser that frees you from the one-finger mouse. Silvio From jjfoerch at earthlink.net Thu Feb 26 13:06:31 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Thu, 26 Feb 2009 16:06:31 -0500 Subject: [Conkeror] Bookmarking a page to Delicious account References: <594f78210902252202t700672b7u79018064e5be6411@mail.gmail.com> Message-ID: <87skm0x608.fsf@earthlink.net> aditya siram writes: > Hi all, > Is there a way to bookmark a page directly to my Delicious account? So I am reading a page, I type a > command and my account is updated. Put this in your rc: add_delicious_webjumps("your_username"); You will now have a webjump called adelicious. -- John Foerch From brian at gweep.ca Thu Feb 26 13:05:24 2009 From: brian at gweep.ca (Brian Edmonds) Date: Thu, 26 Feb 2009 13:05:24 -0800 Subject: [Conkeror] Change the name of Conkeror, quickly! In-Reply-To: <413a3a380902261303h4bd21e0eqe32c8acd1f1dac3c@mail.gmail.com> References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> <49A6F927.9000005@servo.cc> <413a3a380902261303h4bd21e0eqe32c8acd1f1dac3c@mail.gmail.com> Message-ID: <413a3a380902261305n1748971i7a2e6a05b081f2de@mail.gmail.com> Can you also tabulate those who would prefer not to change the name. I rather like it as is, and find the "confusion" leads to more curiosity than any problems. Brian. -- Sent from my Android phone. Blame GMail for the top-posting that I cannot turn off or edit. I think it sucks too. On Feb 26, 2009 12:19 PM, "Nicholas A. Zigarovich" wrote: Submit your suggestions here on the list or at the wiki: http://conkeror.org/NameChange - Nick Deniz Dogan wrote: > > Hello, fellow Conkeror users > > This is a public service announcement! The... -------------- next part -------------- An HTML attachment was scrubbed... URL: From technomancy at gmail.com Thu Feb 26 13:17:43 2009 From: technomancy at gmail.com (Phil Hagelberg) Date: Thu, 26 Feb 2009 13:17:43 -0800 Subject: [Conkeror] Change the name of Conkeror, quickly! In-Reply-To: <87wsbdw1ww.fsf@earthlink.net> (John J. Foerch's message of "Thu, 26 Feb 2009 12:20:15 -0500") References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> <87wsbdw1ww.fsf@earthlink.net> Message-ID: <873ae0hp8o.fsf@hagelb.org> John J Foerch writes: > Conkeror is a pretty good name. It has a nice sound to it, and > the word origin gives it a classical feeling. I agree; Conkeror is a good name; it's much more searchable than any other decent name that has been proposed so far. Obviously it was deliberately named with the same name as an existing browser back at its inception, and I think this hints a bit at the playful nature of the project and the community surrounding it. This would be a shame to lose. If you have to refer to it in spoken conversation, "Conkeror with a C" is not too bad, especially considering that it's referred to in written conversation far more often. If the name does have to change, "Conker" would be ideal because it would make the relationship between the new and old names very obvious and be the least disorienting to newcomers who follow links that still refer to "Conkeror". Also, we should get Shawn Betts to chime in on the thread as he is the originator of the project. -Phil From jeremy at jeremyms.com Thu Feb 26 15:33:04 2009 From: jeremy at jeremyms.com (Jeremy Maitin-Shepard) Date: Thu, 26 Feb 2009 15:33:04 -0800 Subject: [Conkeror] Change the name of Conkeror, quickly! In-Reply-To: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> (Deniz Dogan's message of "Thu, 26 Feb 2009 02:43:56 +0100") References: <7b501d5c0902251743g1e12e29bu4c229e545700d58@mail.gmail.com> Message-ID: <878wnsrcy7.fsf@jeremyms.com> This has been said on IRC, but I'll repeat it here for those not present in the IRC discussion: I'm opposed to changing the name. I like the current name. I don't think the confusion will Konqueror is a very serious problem --- if any confusion occurs (most likely when saying the name aloud), it simply has to be corrected, which should only take a couple extra seconds. Changing the name would also create additional hassle for a number of reasons. Also consider that web browsers have a history of being named in ways that mimic existing browsers: Navigator Explorer Konqueror Most notable: Links Lynx -- Jeremy Maitin-Shepard From David.Kettler at dsto.defence.gov.au Thu Feb 26 16:07:38 2009 From: David.Kettler at dsto.defence.gov.au (David Kettler) Date: 27 Feb 2009 10:37:38 +1030 Subject: [Conkeror] Where to go after a tab is closed In-Reply-To: <87ljrt2djl.fsf@CPU107.opentrends.net> References: <87ljrt2djl.fsf@CPU107.opentrends.net> Message-ID: G'day, > I see that when you close a buffer, focus goes to the buffer which > was active before the ex-buffer was selected. I think I would > prefer to go always to the buffer to the right of the buffer which > I'm killing. > ... I use the code below, which behaves rather like C-w in firefox. I find it convenient when I have opened a number of links from one page in buffers in the background. It's not quite satisfactory though. It might be nice to have a more sophisticated system where follow-new-buffer-background marks the parent/child relationship between buffers, based on from where a link was followed. Then the kill command can go to the next sibling, or up to the parent. --8<-- /** Convenient for reading series of opened buffers. */ interactive("kill-and-next-buffer", "Kill the current buffer and switch to the logical next.", function (I) { var bufs = I.window.buffers; var i = bufs.selected_index; kill_buffer(I.buffer); // mozilla behaviour: if (i == bufs.count) i--; if (i < bufs.count) bufs.current = bufs.get_buffer(i);}); define_key(content_buffer_normal_keymap, "w", "kill-and-next-buffer"); -->8-- regards, David (with apologies for the obnoxious disclaimer) -- IMPORTANT: This email remains the property of the Australian Defence Organisation and is subject to the jurisdiction of section 70 of the CRIMES ACT 1914. If you have received this email in error, you are requested to contact the sender and delete the email. From dcl441-bugs at yahoo.com Fri Feb 27 00:23:03 2009 From: dcl441-bugs at yahoo.com (Daniel Clemente) Date: Fri, 27 Feb 2009 09:23:03 +0100 Subject: [Conkeror] Where to go after a tab is closed References: <87ljrt2djl.fsf@CPU107.opentrends.net> Message-ID: <87hc2g2src.fsf@CPU107.opentrends.net> El dv, feb 27 2009, David Kettler va escriure: > I use the code below, which behaves rather like C-w in firefox. I > find it convenient when I have opened a number of links from one page > in buffers in the background. This is as I wanted; thanks. > > It's not quite satisfactory though. It might be nice to have a more > sophisticated system where follow-new-buffer-background marks the > parent/child relationship between buffers, based on from where a link > was followed. Then the kill command can go to the next sibling, or up > to the parent. There are many sensible behaviours to close a buffer: - go to the buffer to the right - go to the buffer to the left - go to the last active buffer - go to the parent buffer (the buffer which opened the ex-buffer) - go to the next sibling (next child of the ex-buffer's parent) Since each person seems to have different preferences, ideally the behaviour could be configurable. -- Daniel From jjfoerch at earthlink.net Fri Feb 27 07:33:10 2009 From: jjfoerch at earthlink.net (John J Foerch) Date: Fri, 27 Feb 2009 10:33:10 -0500 Subject: [Conkeror] Where to go after a tab is closed References: <87ljrt2djl.fsf@CPU107.opentrends.net> <87hc2g2src.fsf@CPU107.opentrends.net> Message-ID: <87wsbb3nex.fsf@earthlink.net> Daniel Clemente writes: > There are many sensible behaviours to close a buffer: > - go to the buffer to the right > - go to the buffer to the left > - go to the last active buffer > - go to the parent buffer (the buffer which opened the ex-buffer) > - go to the next sibling (next child of the ex-buffer's parent) > > Since each person seems to have different preferences, ideally the behaviour could be configurable. It's an excellent idea. I can't get to it right away but I'll keep it in mind. -- John Foerch