[slime-devel] Setting browse-url-browser-function
Stephen Compall
s11 at member.fsf.org
Thu Apr 6 16:55:26 UTC 2006
On Thu, 2006-04-06 at 07:09 -0800, Tim Johnson wrote:
> (setq browse-url-browser-function "fire-fox")
> ;; where fire-fox is a simple script that I use to launch firefox
> ;; on my RH Linux 9.0 maching
Emacs is a self-documenting editor. C-h v browse-url-browser-function
for all you could possibly want. For example, mine is the symbol
w3m-browse-url.
Here is what I used to use; I copied it from another browse-url
function; edit as necessary. Note it is not very robust. The current
Emacs development includes a `browse-url-firefox' that is much better
all around.
(defun s11-browse-url-firefox (url &optional new-window-ignore)
(interactive (browse-url-interactive-arg "URL: "))
(while (string-match "[,)$]" url)
(setq url (replace-match
(format "%%%x" (string-to-char (match-string 0 url))) t t
url)))
(call-process "/usr/bin/mozilla-firefox" ;firefox on my system
nil 0 nil "-remote" (format "openURL(%s,new-tab)" url)))
--
Stephen Compall
http://scompall.nocandysw.com/blog
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 191 bytes
Desc: This is a digitally signed message part
URL: <https://mailman.common-lisp.net/pipermail/slime-devel/attachments/20060406/8b0189bd/attachment.sig>
More information about the slime-devel
mailing list