Apply upstream Subversion >= 1.7 dir structure fix for vc-svn.el.

This commit is contained in:
Ville Skyttä 2011-11-27 23:07:30 +02:00
parent 4d08961b29
commit bb940a5c28
2 changed files with 76 additions and 1 deletions

69
103228_103227.diff Normal file
View File

@ -0,0 +1,69 @@
=== modified file 'lisp/vc-svn.el'
--- lisp/vc-svn.el 2011-01-26 08:36:39 +0000
+++ lisp/vc-svn.el 2011-02-12 01:12:53 +0000
@@ -117,17 +117,13 @@
;;;###autoload (getenv "SVN_ASP_DOT_NET_HACK"))
;;;###autoload "_svn")
;;;###autoload (t ".svn"))))
-;;;###autoload (when (file-readable-p (expand-file-name
-;;;###autoload (concat admin-dir "/entries")
-;;;###autoload (file-name-directory f)))
+;;;###autoload (when (vc-find-root f admin-dir)
;;;###autoload (load "vc-svn")
;;;###autoload (vc-svn-registered f))))
(defun vc-svn-registered (file)
"Check if FILE is SVN registered."
- (when (file-readable-p (expand-file-name (concat vc-svn-admin-directory
- "/entries")
- (file-name-directory file)))
+ (when (vc-svn-root file)
(with-temp-buffer
(cd (file-name-directory file))
(let* (process-file-side-effects
@@ -275,14 +271,12 @@
to the SVN command."
(apply 'vc-svn-command nil 0 files "add" (vc-switches 'SVN 'register)))
-(defun vc-svn-responsible-p (file)
- "Return non-nil if SVN thinks it is responsible for FILE."
- (file-directory-p (expand-file-name vc-svn-admin-directory
- (if (file-directory-p file)
- file
- (file-name-directory file)))))
-
-(defalias 'vc-svn-could-register 'vc-svn-responsible-p
+(defun vc-svn-root (file)
+ (vc-find-root file vc-svn-admin-directory))
+
+(defalias 'vc-svn-responsible-p 'vc-svn-root)
+
+(defalias 'vc-svn-could-register 'vc-svn-root
"Return non-nil if FILE could be registered in SVN.
This is only possible if SVN is responsible for FILE's directory.")
@@ -594,20 +588,10 @@
(defun vc-svn-repository-hostname (dirname)
(with-temp-buffer
- (let ((coding-system-for-read
- (or file-name-coding-system
- default-file-name-coding-system)))
- (vc-insert-file (expand-file-name (concat vc-svn-admin-directory
- "/entries")
- dirname)))
+ (let (process-file-side-effects)
+ (vc-svn-command t t dirname "info" "--xml"))
(goto-char (point-min))
- (when (re-search-forward
- ;; Old `svn' used name="svn:this_dir", newer use just name="".
- (concat "name=\"\\(?:svn:this_dir\\)?\"[\n\t ]*"
- "\\(?:[-a-z]+=\"[^\"]*\"[\n\t ]*\\)*?"
- "url=\"\\(?1:[^\"]+\\)\""
- ;; Yet newer ones don't use XML any more.
- "\\|^\ndir\n[0-9]+\n\\(?1:.*\\)") nil t)
+ (when (re-search-forward "<url>\\(.*\\)</url>" nil t)
;; This is not a hostname but a URL. This may actually be considered
;; as a feature since it allows vc-svn-stay-local to specify different
;; behavior for different modules on the same server.

View File

@ -3,7 +3,7 @@ Summary: GNU Emacs text editor
Name: emacs Name: emacs
Epoch: 1 Epoch: 1
Version: 23.3 Version: 23.3
Release: 17%{?dist} Release: 18%{?dist}
License: GPLv3+ License: GPLv3+
URL: http://www.gnu.org/software/emacs/ URL: http://www.gnu.org/software/emacs/
Group: Applications/Editors Group: Applications/Editors
@ -38,6 +38,8 @@ Patch7: emacs-spellchecker.patch
Patch8: emacs-wm-state-hidden.patch Patch8: emacs-wm-state-hidden.patch
# rhbz#751154 # rhbz#751154
Patch9: emacs-xgselect.patch Patch9: emacs-xgselect.patch
# http://bzr.savannah.gnu.org/lh/emacs/trunk/revision/103228
Patch10: 103228_103227.diff
BuildRequires: atk-devel, cairo-devel, freetype-devel, fontconfig-devel, dbus-devel, giflib-devel, glibc-devel, gtk2-devel, libpng-devel BuildRequires: atk-devel, cairo-devel, freetype-devel, fontconfig-devel, dbus-devel, giflib-devel, glibc-devel, gtk2-devel, libpng-devel
BuildRequires: libjpeg-devel, libtiff-devel, libX11-devel, libXau-devel, libXdmcp-devel, libXrender-devel, libXt-devel BuildRequires: libjpeg-devel, libtiff-devel, libX11-devel, libXau-devel, libXdmcp-devel, libXrender-devel, libXt-devel
@ -163,6 +165,7 @@ packages that add functionality to Emacs.
%patch7 -p1 -b .spellchecker %patch7 -p1 -b .spellchecker
%patch8 -p1 -b .wm-state-hidden %patch8 -p1 -b .wm-state-hidden
%patch9 -p1 -b .xgselect %patch9 -p1 -b .xgselect
%patch10 -p0 -b .svn17
# Install site-lisp files # Install site-lisp files
cp %SOURCE7 %SOURCE10 site-lisp cp %SOURCE7 %SOURCE10 site-lisp
@ -443,6 +446,9 @@ update-desktop-database &> /dev/null || :
%dir %{_datadir}/emacs/site-lisp/site-start.d %dir %{_datadir}/emacs/site-lisp/site-start.d
%changelog %changelog
* Sun Nov 27 2011 Ville Skyttä <ville.skytta@iki.fi> - 1:23.3-18
- Apply upstream Subversion >= 1.7 dir structure fix for vc-svn.el.
* Fri Nov 25 2011 Karel Klíč <kklic@redhat.com> - 1:23.3-17 * Fri Nov 25 2011 Karel Klíč <kklic@redhat.com> - 1:23.3-17
- Add a new command rpm-goto-add-change-log-entry (C-c C-w) to - Add a new command rpm-goto-add-change-log-entry (C-c C-w) to
rpm-spec mode (Jaroslav Skarvada) rpm-spec mode (Jaroslav Skarvada)