emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r99529: Use abbreviated file names in


From: Stefan Monnier
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r99529: Use abbreviated file names in bookmarks (bug#5591).
Date: Thu, 18 Feb 2010 13:52:36 -0500
User-agent: Bazaar (2.0.3)

------------------------------------------------------------
revno: 99529
committer: Stefan Monnier <address@hidden>
branch nick: trunk
timestamp: Thu 2010-02-18 13:52:36 -0500
message:
  Use abbreviated file names in bookmarks (bug#5591).
  * bookmark.el (bookmark-maybe-load-default-file): Remove redundant
  calls to expand-file-name.
  (bookmark-relocate): Use abbreviated file names in bookmarks.
  (bookmark-load): Use abbreviated file names in messages.
modified:
  lisp/ChangeLog
  lisp/bookmark.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2010-02-18 10:08:48 +0000
+++ b/lisp/ChangeLog    2010-02-18 18:52:36 +0000
@@ -1,3 +1,11 @@
+2010-02-18  Stefan Monnier  <address@hidden>
+
+       Use abbreviated file names in bookmarks (bug#5591).
+       * bookmark.el (bookmark-maybe-load-default-file): Remove redundant
+       calls to expand-file-name.
+       (bookmark-relocate): Use abbreviated file names in bookmarks.
+       (bookmark-load): Use abbreviated file names in messages.
+
 2010-02-18  Michael Albinus  <address@hidden>
 
        * net/tramp.el (tramp-handle-directory-files): When FULL, do not
@@ -25,8 +33,8 @@
 
 2010-02-16  Michael Albinus  <address@hidden>
 
-       * net/tramp.el (tramp-do-copy-or-rename-file-out-of-band): Fix
-       errors in copying directories.
+       * net/tramp.el (tramp-do-copy-or-rename-file-out-of-band):
+       Fix errors in copying directories.
        (tramp-handle-add-name-to-file, tramp-handle-copy-directory)
        (tramp-do-copy-or-rename-file, tramp-handle-delete-directory)
        (tramp-handle-delete-file)
@@ -52,8 +60,7 @@
        * cedet/srecode.el (srecode):
        * cedet/semantic.el (semantic): Put in tools and extensions group.
 
-       * nxml/nxml-mode.el (nxml-faces): Remove from font-lock-faces
-       group.
+       * nxml/nxml-mode.el (nxml-faces): Remove from font-lock-faces group.
 
        * textmodes/flyspell.el (flyspell-word): Obey the offset specified
        by ispell-parse-output (Bug#5575).
@@ -170,8 +177,7 @@
 2010-02-08  Jose E. Marchesi  <address@hidden>
 
        * progmodes/ada-mode.el (ada-in-numeric-literal-p): New function.
-       (ada-adjust-case): Don't adjust case in hexadecimal number
-       literals.
+       (ada-adjust-case): Don't adjust case in hexadecimal number literals.
 
 2010-02-08  Kenichi Handa  <address@hidden>
 

=== modified file 'lisp/bookmark.el'
--- a/lisp/bookmark.el  2010-02-10 20:02:54 +0000
+++ b/lisp/bookmark.el  2010-02-18 18:52:36 +0000
@@ -958,14 +958,14 @@
            (and
             ;; Possibly the old bookmark file, "~/.emacs-bkmrks", needs
             ;; to be renamed.
-            (file-exists-p (expand-file-name bookmark-old-default-file))
-            (not (file-exists-p (expand-file-name bookmark-default-file)))
-            (rename-file (expand-file-name bookmark-old-default-file)
-                         (expand-file-name bookmark-default-file)))
+            (file-exists-p bookmark-old-default-file)
+            (not (file-exists-p bookmark-default-file))
+            (rename-file bookmark-old-default-file
+                         bookmark-default-file))
            ;; return t so the `and' will continue...
            t)
 
-       (file-readable-p (expand-file-name bookmark-default-file))
+       (file-readable-p bookmark-default-file)
        (bookmark-load bookmark-default-file t t)
        (setq bookmarks-already-loaded t)))
 
@@ -1152,10 +1152,11 @@
   (bookmark-maybe-historicize-string bookmark)
   (bookmark-maybe-load-default-file)
   (let* ((bmrk-filename (bookmark-get-filename bookmark))
-         (newloc (expand-file-name
-                  (read-file-name
-                   (format "Relocate %s to: " bookmark)
-                   (file-name-directory bmrk-filename)))))
+         (newloc (abbreviate-file-name
+                  (expand-file-name
+                   (read-file-name
+                    (format "Relocate %s to: " bookmark)
+                    (file-name-directory bmrk-filename))))))
     (bookmark-set-filename bookmark newloc)
     (setq bookmark-alist-modification-count
           (1+ bookmark-alist-modification-count))
@@ -1432,7 +1433,7 @@
           ;;but there's no better default, and
           ;;I guess it's better than none at all.
           "~/" bookmark-default-file 'confirm)))
-  (setq file (expand-file-name file))
+  (setq file (abbreviate-file-name (expand-file-name file)))
   (if (not (file-readable-p file))
       (error "Cannot read bookmark file %s" file)
     (if (null no-msg)
@@ -1453,7 +1454,8 @@
                 (setq bookmark-alist-modification-count
                       (1+ bookmark-alist-modification-count)))
               (if (string-equal
-                   (expand-file-name bookmark-default-file)
+                   (abbreviate-file-name
+                    (expand-file-name bookmark-default-file))
                    file)
                   (setq bookmarks-already-loaded t))
               (bookmark-bmenu-surreptitiously-rebuild-list))


reply via email to

[Prev in Thread] Current Thread [Next in Thread]