Update emacs-git PKGBUILD
This commit is contained in:
parent
2d0e70211d
commit
d012a83581
4 changed files with 87 additions and 73 deletions
36
emacs-git/0001-Always-treat-chomp-as-a-symbol.patch
Normal file
36
emacs-git/0001-Always-treat-chomp-as-a-symbol.patch
Normal file
|
@ -0,0 +1,36 @@
|
|||
From d7e6e8f2ff3572afb4131ea64966b2a9253f9ac6 Mon Sep 17 00:00:00 2001
|
||||
From: Tom Willemse <tom@ryuslash.org>
|
||||
Date: Sun, 4 Jan 2015 05:37:02 +0100
|
||||
Subject: [PATCH] Always treat chomp as a symbol
|
||||
|
||||
---
|
||||
lisp/ChangeLog | 5 +++++
|
||||
lisp/elec-pair.el | 3 ++-
|
||||
2 files changed, 7 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
|
||||
index aa79a8d..b031f25 100644
|
||||
--- a/lisp/ChangeLog
|
||||
+++ b/lisp/ChangeLog
|
||||
@@ -1,3 +1,5 @@
|
||||
+2015-01-04 Tom Willemse <tom@ryuslash.org>
|
||||
+
|
||||
+ * elec-pair.el (electric-pair-post-self-insert-function): Make
|
||||
+ sure chomp isn't used as a function.
|
||||
+
|
||||
diff --git a/lisp/elec-pair.el b/lisp/elec-pair.el
|
||||
index 2cede62..65c3dbf 100644
|
||||
--- a/lisp/elec-pair.el
|
||||
+++ b/lisp/elec-pair.el
|
||||
@@ -475,7 +475,8 @@ (defun electric-pair-post-self-insert-function
|
||||
(when (and (not (and unconditional
|
||||
(eq syntax ?\")))
|
||||
(setq skip-whitespace-info
|
||||
- (if (functionp electric-pair-skip-whitespace)
|
||||
+ (if (and (not (eq electric-pair-skip-whitespace 'chomp))
|
||||
+ (functionp electric-pair-skip-whitespace))
|
||||
(funcall electric-pair-skip-whitespace)
|
||||
electric-pair-skip-whitespace)))
|
||||
(electric-pair--skip-whitespace))
|
||||
--
|
||||
2.2.1
|
|
@ -0,0 +1,47 @@
|
|||
From c9dfaff53b11f6db401d8ed7a7d25e1efb45c461 Mon Sep 17 00:00:00 2001
|
||||
From: Tom Willemse <tom@ryuslash.org>
|
||||
Date: Tue, 6 Jan 2015 20:37:29 +0100
|
||||
Subject: [PATCH] Use a keyword, not symbol, to delete whitespace
|
||||
|
||||
* elec-pair.el (electric-pair-skip-whitespace): Use `:chomp' instead
|
||||
of `chomp'.
|
||||
(electric-pair-post-self-insert-function): Check for a keyword
|
||||
`:chomp' instead of the symbol `chomp' to prevent naming conflicts.
|
||||
---
|
||||
lisp/ChangeLog | 8 ++++++++
|
||||
lisp/elec-pair.el | 6 +++---
|
||||
2 files changed, 11 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/lisp/elec-pair.el b/lisp/elec-pair.el
|
||||
index 2cede62..270f4a3 100644
|
||||
--- a/lisp/elec-pair.el
|
||||
+++ b/lisp/elec-pair.el
|
||||
@@ -129,7 +129,7 @@ (defcustom electric-pair-skip-whitespace
|
||||
The specific kind of whitespace skipped is given by the variable
|
||||
`electric-pair-skip-whitespace-chars'.
|
||||
|
||||
-The symbol `chomp' specifies that the skipped-over whitespace
|
||||
+The keyword `:chomp' specifies that the skipped-over whitespace
|
||||
should be deleted.
|
||||
|
||||
Can also be a function of no arguments, in which case that function's
|
||||
@@ -138,7 +138,7 @@ (defcustom electric-pair-skip-whitespace
|
||||
:group 'electricity
|
||||
:type '(choice
|
||||
(const :tag "Yes, jump over whitespace" t)
|
||||
- (const :tag "Yes, and delete whitespace" chomp)
|
||||
+ (const :tag "Yes, and delete whitespace" :chomp)
|
||||
(const :tag "No, no whitespace skipping" nil)
|
||||
function))
|
||||
|
||||
@@ -487,7 +487,7 @@ (defun electric-pair-post-self-insert-function
|
||||
;; live with it for now.
|
||||
(when skip-whitespace-info
|
||||
(electric-pair--skip-whitespace))
|
||||
- (delete-region (1- pos) (if (eq skip-whitespace-info 'chomp)
|
||||
+ (delete-region (1- pos) (if (eq skip-whitespace-info :chomp)
|
||||
(point)
|
||||
pos))
|
||||
(forward-char))
|
||||
--
|
||||
2.2.1
|
|
@ -7,7 +7,7 @@
|
|||
_opt_puresize="1820000"
|
||||
|
||||
pkgname=emacs-git
|
||||
pkgver=20141227214603
|
||||
pkgver=20150404161006
|
||||
pkgrel=1
|
||||
pkgdesc='The extensible, customizable, self-documenting real-time display editor from its official Git repository'
|
||||
arch=('i686' 'x86_64')
|
||||
|
@ -21,7 +21,7 @@ provides=("emacs=$pkgver")
|
|||
conflicts=('emacs' 'emacs-nox' 'emacs-otf' 'emacs-cvs' 'emacs-bzr')
|
||||
install=$pkgname.install
|
||||
source=("git+http://git.savannah.gnu.org/r/emacs.git"
|
||||
'docstrings2.patch')
|
||||
'0001-Use-a-keyword-not-symbol-to-delete-whitespace.patch')
|
||||
|
||||
_mandir=/usr/share/man
|
||||
|
||||
|
@ -52,6 +52,7 @@ build() {
|
|||
--without-gsettings \
|
||||
--with-x-toolkit=lucid || return 1
|
||||
# patch -p0 -i "$srcdir"/docstrings2.patch || return 1
|
||||
patch -p1 -i "$srcdir"/0001-Use-a-keyword-not-symbol-to-delete-whitespace.patch || return 1
|
||||
make bootstrap
|
||||
}
|
||||
|
||||
|
@ -77,4 +78,4 @@ package() {
|
|||
chown -R root:50 $pkgdir/var/games
|
||||
}
|
||||
md5sums=('SKIP'
|
||||
'3a868e5b80d5912ded06e6bdc040208a')
|
||||
'35e7ce2809180972c1cdfcf1aca3612c')
|
||||
|
|
|
@ -1,70 +0,0 @@
|
|||
# Bazaar merge directive format 2 (Bazaar 0.90)
|
||||
# revision_id: tom@ryuslash.org-20130202085403-n4iv0tg5xh4dwbnm
|
||||
# target_branch: bzr://bzr.savannah.gnu.org/emacs/trunk/
|
||||
# testament_sha1: dca687d2bd301e20ea2dafb8af371ca897851137
|
||||
# timestamp: 2013-02-02 09:54:17 +0100
|
||||
# base_revision_id: rgm@gnu.org-20121227082108-3z2ppeegxrhychws
|
||||
#
|
||||
# Begin patch
|
||||
=== modified file 'lisp/progmodes/python.el'
|
||||
--- lisp/progmodes/python.el 2012-12-13 05:29:15 +0000
|
||||
+++ lisp/progmodes/python.el 2013-02-02 08:54:03 +0000
|
||||
@@ -406,6 +406,23 @@
|
||||
'python-info-ppss-comment-or-string-p
|
||||
#'python-syntax-comment-or-string-p "24.3")
|
||||
|
||||
+(defun python-doc-string-at-p (pos)
|
||||
+ "Check to see if there is a docstring at POS."
|
||||
+ (save-excursion
|
||||
+ (goto-char pos)
|
||||
+ (if (looking-at-p "'''\\|\"\"\"")
|
||||
+ (progn
|
||||
+ (python-nav-backward-statement)
|
||||
+ (looking-at "\\`\\|class \\|def "))
|
||||
+ nil)))
|
||||
+
|
||||
+(defun python-font-lock-syntactic-face-function (state)
|
||||
+ (if (nth 3 state)
|
||||
+ (if (python-doc-string-at-p (nth 8 state))
|
||||
+ font-lock-doc-face
|
||||
+ font-lock-string-face)
|
||||
+ font-lock-comment-face))
|
||||
+
|
||||
(defvar python-font-lock-keywords
|
||||
;; Keywords
|
||||
`(,(rx symbol-start
|
||||
@@ -3213,7 +3230,10 @@
|
||||
'python-nav-forward-sexp)
|
||||
|
||||
(set (make-local-variable 'font-lock-defaults)
|
||||
- '(python-font-lock-keywords nil nil nil nil))
|
||||
+ '(python-font-lock-keywords
|
||||
+ nil nil nil nil
|
||||
+ (font-lock-syntactic-face-function
|
||||
+ . python-font-lock-syntactic-face-function)))
|
||||
|
||||
(set (make-local-variable 'syntax-propertize-function)
|
||||
python-syntax-propertize-function)
|
||||
|
||||
# Begin bundle
|
||||
IyBCYXphYXIgcmV2aXNpb24gYnVuZGxlIHY0CiMKQlpoOTFBWSZTWS+Ut6kAAd3fgF8QUOP/91sA
|
||||
zIT/7//0UAQ7teAGnjYAA1NEamyjQ0yaPUaaBoAAA000NAZQmmo09NGiaExkIYjIxMjRjQjINRGT
|
||||
QQGmI2kAAGTE0bUAZAamFCaGgNA0ADTIAGhoAAkkEaMhT01PQJoyGp6T1MmU2kDQzUbUQCEcFvCF
|
||||
m1Q0hhKkAQlnV4XOCkeRYSGjmMQA0S1k2M6u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