[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[emacs-wiki-discuss] [PATCH] emacs-wiki.el bug
From: |
Hoan Ton-That |
Subject: |
[emacs-wiki-discuss] [PATCH] emacs-wiki.el bug |
Date: |
Fri, 16 Jul 2004 16:49:02 -0500 |
User-agent: |
Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (gnu/linux) |
Hello,
The function `emacs-wiki-project-interwiki-link' does not highlight
interwiki links properly. The following patch fixes that by
reorginizing the lets.
* looking for address@hidden/emacs-wiki--dev--1.0--patch-52 to compare with
* comparing to address@hidden/emacs-wiki--dev--1.0--patch-52
M emacs-wiki.el
* modified files
--- orig/emacs-wiki.el
+++ mod/emacs-wiki.el
@@ -4029,30 +4029,30 @@
(file-relative-name dest src))))
(defun emacs-wiki-project-interwiki-link (project tag)
- (let ((page-publishing-directory
- (file-name-directory
- (concat emacs-wiki-project-server-prefix
- (emacs-wiki-link-url (emacs-wiki-page-name))))))
- (with-emacs-wiki-project project
- (if emacs-wiki-publishing-p
- (let ((url (emacs-wiki-link-url (or tag emacs-wiki-home-page))))
- (cond
- ;; bad link, no prefix will be added
- ((null url) "")
- ;; try and convert to a relative link
- ((and emacs-wiki-relative-links
- ;; without catching extended links by mistake
- (not (string-match "\\[\\[[^][]+\\(\\]\\[[^][]+\\)?\\]\\]"
- url))
- (emacs-wiki-relative-link-maybe
- (concat emacs-wiki-project-server-prefix url)
- page-publishing-directory)))
- ;; use the server prefix
- ((concat emacs-wiki-project-server-prefix url))))
- (or (emacs-wiki-page-file (or tag emacs-wiki-home-page))
- ;; doesn't yet exist, so we don't qualify the name, causing it
- ;; to be rendered as a bad link
- tag)))))
+ (with-emacs-wiki-project project
+ (if emacs-wiki-publishing-p
+ (let ((url (emacs-wiki-link-url (or tag emacs-wiki-home-page)))
+ (page-publishing-directory
+ (file-name-directory
+ (concat emacs-wiki-project-server-prefix
+ (emacs-wiki-link-url (emacs-wiki-page-name))))))
+ (cond
+ ;; bad link, no prefix will be added
+ ((null url) "")
+ ;; try and convert to a relative link
+ ((and emacs-wiki-relative-links
+ ;; without catching extended links by mistake
+ (not (string-match "\\[\\[[^][]+\\(\\]\\[[^][]+\\)?\\]\\]"
+ url))
+ (emacs-wiki-relative-link-maybe
+ (concat emacs-wiki-project-server-prefix url)
+ page-publishing-directory)))
+ ;; use the server prefix
+ ((concat emacs-wiki-project-server-prefix url))))
+ (or (emacs-wiki-page-file (or tag emacs-wiki-home-page))
+ ;; doesn't yet exist, so we don't qualify the name, causing it
+ ;; to be rendered as a bad link
+ tag))))
;; URLs
- [emacs-wiki-discuss] [PATCH] emacs-wiki.el bug,
Hoan Ton-That <=