]> git.cworth.org Git - notmuch/commitdiff
Merge branch 'release'
authorDavid Bremner <david@tethera.net>
Thu, 17 Nov 2016 12:25:08 +0000 (08:25 -0400)
committerDavid Bremner <david@tethera.net>
Thu, 17 Nov 2016 12:25:08 +0000 (08:25 -0400)
Updates for 0.23.2

22 files changed:
Makefile.local
bindings/python/notmuch/version.py
debian/changelog
debian/control
debian/elpa-notmuch.elpa [new file with mode: 0644]
debian/notmuch-emacs.dirs [deleted file]
debian/notmuch-emacs.emacsen-compat [deleted file]
debian/notmuch-emacs.emacsen-install [deleted file]
debian/notmuch-emacs.emacsen-remove [deleted file]
debian/notmuch-emacs.install [deleted file]
debian/notmuch-emacs.postinst [deleted file]
debian/notmuch-emacs.prerm [deleted file]
debian/rules
emacs/.gitignore
emacs/Makefile.local
emacs/notmuch-address.el
emacs/notmuch-company.el
emacs/notmuch-compat.el [new file with mode: 0644]
emacs/notmuch-lib.el
emacs/notmuch-maildir-fcc.el
emacs/notmuch-pkg.el.tmpl [new file with mode: 0644]
version

index d1b0585f28665a06d7a249e7ee71eec581b984fb..0a122ab0e208c29c501bc3aee9c37243e06b13c9 100644 (file)
@@ -19,9 +19,12 @@ DATE:=$(shell date +%F)
 endif
 
 VERSION:=$(shell cat ${srcdir}/version)
+ELPA_VERSION:=$(subst ~,_,$(VERSION))
 ifeq ($(filter release release-message pre-release update-versions,$(MAKECMDGOALS)),)
 ifeq ($(IS_GIT),yes)
 VERSION:=$(shell git --git-dir=${srcdir}/.git describe --abbrev=7 --match '[0-9.]*'|sed -e s/_/~/ -e s/-/+/ -e s/-/~/)
+# drop the ~g$sha1 part
+ELPA_VERSION:=$(word 1,$(subst ~, ,$(VERSION)))
 # Write the file 'version.stamp' in case its contents differ from $(VERSION)
 FILE_VERSION:=$(shell test -f version.stamp && read vs < version.stamp || vs=; echo $$vs)
 ifneq ($(FILE_VERSION),$(VERSION))
index 4bbe0cdc775990522b2a791d484f217ffa10c5d7..5f234565bf87b2a134709f2f6aa0a17c81017943 100644 (file)
@@ -1,3 +1,3 @@
 # this file should be kept in sync with ../../../version
-__VERSION__ = '0.23.1'
+__VERSION__ = '0.23.2'
 SOVERSION = '4'
index 2c7cd2344f159b427fe56ee9e670622938ca2608..66634034997474e70f0c6b0dd929f188b3c98b89 100644 (file)
@@ -1,3 +1,12 @@
+notmuch (0.23.2-1) unstable; urgency=medium
+
+  * New upstream bugfix release
+  * Convert notmuch-emacs to dh-elpa, new binary package elpa-notmuch
+  * Bug fix: "maintainer script(s) do not start on #!", thanks to
+    treinen@debian.org; (Closes: #843287).
+
+ -- David Bremner <bremner@debian.org>  Thu, 10 Nov 2016 22:36:04 -0400
+
 notmuch (0.23.1-1) unstable; urgency=medium
 
   * New upstream bugfix release
index 4027a79b63b355c7fbe712b1fa87ddf120f94d7c..a8c7ce20e8e42838759b09c9d620f3f74131de67 100644 (file)
@@ -17,6 +17,7 @@ Build-Depends:
  python-all (>= 2.6.6-3~),
  python3-all (>= 3.1.2-7~),
  dh-python,
+ dh-elpa (>= 1.3),
  python-sphinx (>= 1.0),
  ruby, ruby-dev (>>1:1.9.3~),
  emacs24-nox | emacs24 (>=24~) | emacs24-lucid (>=24~) |
@@ -111,13 +112,12 @@ Description: Ruby interface to the notmuch mail search and index library
 
 Package: notmuch-emacs
 Architecture: all
-Section: mail
-Breaks: notmuch (<<0.6~254~)
-Replaces: notmuch (<<0.6~254~)
-Depends: ${misc:Depends}, notmuch (>= ${source:Version}),
- emacs23 (>= 23~) | emacs23-nox (>=23~) | emacs23-lucid (>=23~) |
- emacs24 (>= 24~) | emacs24-nox (>=24~) | emacs24-lucid (>=24~),
- emacsen-common (>= 2.0.8)
+Description: thread-based email index, search and tagging (transitional package)
+ This dummy package help ease transition to the new package elpa-notmuch
+
+Package: elpa-notmuch
+Architecture: all
+Depends: ${misc:Depends}, ${elpa:Depends}
 Description: thread-based email index, search and tagging (emacs interface)
  Notmuch is a system for indexing, searching, reading, and tagging
  large collections of email messages in maildir or mh format. It uses
diff --git a/debian/elpa-notmuch.elpa b/debian/elpa-notmuch.elpa
new file mode 100644 (file)
index 0000000..b4e9e17
--- /dev/null
@@ -0,0 +1 @@
+emacs/*.el
diff --git a/debian/notmuch-emacs.dirs b/debian/notmuch-emacs.dirs
deleted file mode 100644 (file)
index caeb400..0000000
+++ /dev/null
@@ -1 +0,0 @@
-usr/share/emacs/site-lisp/notmuch
diff --git a/debian/notmuch-emacs.emacsen-compat b/debian/notmuch-emacs.emacsen-compat
deleted file mode 100644 (file)
index 573541a..0000000
+++ /dev/null
@@ -1 +0,0 @@
-0
diff --git a/debian/notmuch-emacs.emacsen-install b/debian/notmuch-emacs.emacsen-install
deleted file mode 100755 (executable)
index cce95c3..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-#!/bin/sh
-# /usr/lib/emacsen-common/packages/install/notmuch-emacs
-set -e
-
-FLAVOR=$1
-PACKAGE=notmuch
-
-case "${FLAVOR}" in
-    emacs)
-       return 0
-       ;;
-    xemacs*|emacs2[12])
-       # patches welcome.
-       echo install/${PACKAGE}: skipping install for unsupported emacsen flavor ${FLAVOR}
-       exit 0
-       ;;
-    *)
-       echo install/${PACKAGE}: Handling install for emacsen flavor ${FLAVOR}
-esac
-
-
-elc_dir=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
-el_dir=/usr/share/emacs/site-lisp/${PACKAGE}
-
-byte_compile_options="--quick --directory=${el_dir} -batch -f batch-byte-compile"
-
-echo install/${PACKAGE}: byte-compiling for ${FLAVOR}
-
-[ -d ${elc_dir} ] || mkdir ${elc_dir}
-
-# Create symlinks to the .el files (see section 6E in debian-emacs
-# polcy).  This makes complation easy, and also allows find-function
-# and find-library to work properly.
-(cd ${elc_dir} && ln -sf ${el_dir}/*.el .)
-
-# Byte compile them
-(cd ${elc_dir}
- set +e
- ${FLAVOR} ${byte_compile_options} *.el > Install.log 2>&1
- if test $? -ne 0
- then
-   cat Install.log
-   exit 1
- fi
- set -e
- gzip -9f Install.log)
-
-exit 0;
diff --git a/debian/notmuch-emacs.emacsen-remove b/debian/notmuch-emacs.emacsen-remove
deleted file mode 100755 (executable)
index a555320..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-#!/bin/sh
-# /usr/lib/emacsen-common/packages/remove/notmuch
-
-set -e
-
-FLAVOR=$1
-PACKAGE=notmuch
-elc_dir=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
-
-case "${FLAVOR}" in
-    emacs)
-       return 0
-       ;;
-    xemacs*|emacs2[12])
-       # patches welcome.
-       echo install/${PACKAGE}: skipping removal for unsupported emacsen flavor ${FLAVOR}
-       exit 0
-       ;;
-    *)
-       echo remove/${PACKAGE}: Handling removal for emacsen flavor ${FLAVOR}
-esac
-
-echo remove/${PACKAGE}: Handling removal of emacsen flavor ${FLAVOR}
-
-echo emacsen-common: purging byte-compiled files for ${FLAVOR}
-rm -f ${elc_dir}/*.elc
-rm -f ${elc_dir}/*.el
-rm -f ${elc_dir}/Install.log*
-if test -e "${elc_dir}"
-then
-  rmdir --ignore-fail-on-non-empty "${elc_dir}"
-fi
-
-exit 0;
diff --git a/debian/notmuch-emacs.install b/debian/notmuch-emacs.install
deleted file mode 100644 (file)
index c73aece..0000000
+++ /dev/null
@@ -1 +0,0 @@
-usr/share/emacs/site-lisp/notmuch/*.el
diff --git a/debian/notmuch-emacs.postinst b/debian/notmuch-emacs.postinst
deleted file mode 100644 (file)
index 1237237..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-dir="/var/lib/emacsen-common/state/package/installed"
-mkdir -p -m 0755 ${dir}
-touch ${dir}/notmuch-emacs
-#DEBHELPER#
-if [ -d /0755 ]; then
-   rmdir /0755 || true
-fi
diff --git a/debian/notmuch-emacs.prerm b/debian/notmuch-emacs.prerm
deleted file mode 100644 (file)
index 5e2758d..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-#DEBHELPER#
-dir="/var/lib/emacsen-common/state/package/installed"
-rm -f ${dir}/notmuch-emacs
index 04f0062a53ab992eb8f0f927a7644ab1a48d128a..15710a895946b79e59bd7c24fba27ea12dbdf65a 100755 (executable)
@@ -3,7 +3,7 @@
 python3_all = py3versions -s | xargs -n1 | xargs -t -I {} env {}
 
 %:
-       dh $@ --with python2,python3
+       dh $@ --with python2,python3,elpa
 
 override_dh_auto_configure:
        ./configure --prefix=/usr \
index 9fa1c44e5b2d347b6043acf40935a3edffa91a42..8e15eed7111806cad24eaa0185d73cea6b23e83a 100644 (file)
@@ -1,3 +1,4 @@
 .eldeps*
 *.elc
 notmuch-version.el
+notmuch-pkg.el
index 6896ff90210202a429b48311f882186f157f5eb3..90a57cca74ed40e1f56d0b962531a6048b5c64cb 100644 (file)
@@ -3,6 +3,7 @@
 dir := emacs
 emacs_sources := \
        $(dir)/notmuch-lib.el \
+       $(dir)/notmuch-compat.el \
        $(dir)/notmuch-parser.el \
        $(dir)/notmuch.el \
        $(dir)/notmuch-query.el \
@@ -28,6 +29,12 @@ $(dir)/notmuch-version.el: $(srcdir)/$(dir)/notmuch-version.el.tmpl
        @sed -e 's/%AG%/Generated file (from $(<F)) -- do not edit!/' \
             -e 's/%VERSION%/"$(VERSION)"/' $< > $@
 
+$(dir)/notmuch-pkg.el: $(srcdir)/$(dir)/notmuch-pkg.el.tmpl
+       @sed -e 's/%AG%/Generated file (from $(<F)) -- do not edit!/' \
+            -e 's/%VERSION%/"$(ELPA_VERSION)"/' $< > $@
+
+all: $(dir)/notmuch-pkg.el
+install-emacs: $(dir)/notmuch-pkg.el
 
 emacs_images := \
        $(srcdir)/$(dir)/notmuch-logo.png
@@ -85,4 +92,4 @@ endif
        mkdir -p "$(DESTDIR)$(emacsetcdir)"
        install -m0644 $(emacs_images) "$(DESTDIR)$(emacsetcdir)"
 
-CLEAN := $(CLEAN) $(emacs_bytecode) $(dir)/notmuch-version.el
+CLEAN := $(CLEAN) $(emacs_bytecode) $(dir)/notmuch-version.el $(dir)/notmuch-pkg.el
index 5b2beefeb823c906280755ed4da121fe209969ee..b3c56cfaad9dc212b990559171c1df2499b39722 100644 (file)
@@ -147,11 +147,11 @@ toggles the setting in this buffer."
   (interactive)
   (if (local-variable-p 'notmuch-address-command)
       (kill-local-variable 'notmuch-address-command)
-    (setq-local notmuch-address-command 'internal))
+    (notmuch-setq-local notmuch-address-command 'internal))
   (if (boundp 'company-idle-delay)
       (if (local-variable-p 'company-idle-delay)
          (kill-local-variable 'company-idle-delay)
-       (setq-local company-idle-delay nil))))
+       (notmuch-setq-local company-idle-delay nil))))
 
 (defun notmuch-address-matching (substring)
   "Returns a list of completion candidates matching SUBSTRING.
index b0f9782175a0c0d1c78c67045d0030785e8ab7a9..ebe2c0846e1b2108f520023e3198970d7e43410e 100644 (file)
@@ -28,6 +28,7 @@
 ;;; Code:
 
 (eval-when-compile (require 'cl))
+(require 'notmuch-lib)
 
 (defvar notmuch-company-last-prefix nil)
 (make-variable-buffer-local 'notmuch-company-last-prefix)
@@ -53,7 +54,7 @@
   ;; internal completion) can still be accessed via standard company
   ;; functions, e.g., company-complete.
   (unless (eq notmuch-address-command 'internal)
-    (setq-local company-idle-delay nil)))
+    (notmuch-setq-local company-idle-delay nil)))
 
 ;;;###autoload
 (defun notmuch-company (command &optional arg &rest _ignore)
diff --git a/emacs/notmuch-compat.el b/emacs/notmuch-compat.el
new file mode 100644 (file)
index 0000000..c3d827a
--- /dev/null
@@ -0,0 +1,73 @@
+;; Compatibility functions for emacs 23 and 24 pre 24.4
+
+;; The functions in this file are copied from eamcs 24.4 and are
+;; Copyright (C) 1985-1986, 1992, 1994-1995, 1999-2014 Free Software
+;; Foundation, Inc.
+
+(if (fboundp 'setq-local)
+    (defalias 'notmuch-setq-local 'setq-local)
+  (defmacro notmuch-setq-local (var val)
+    "Set variable VAR to value VAL in current buffer.
+
+Backport of setq-local for emacs without setq-local (pre 24.3)."
+    `(set (make-local-variable ',var) ,val)))
+
+(if (fboundp 'read-char-choice)
+    (defalias 'notmuch-read-char-choice 'read-char-choice)
+  (defun notmuch-read-char-choice (prompt chars &optional inhibit-keyboard-quit)
+  "Read and return one of CHARS, prompting for PROMPT.
+Any input that is not one of CHARS is ignored.
+
+If optional argument INHIBIT-KEYBOARD-QUIT is non-nil, ignore
+keyboard-quit events while waiting for a valid input.
+
+This is an exact copy of this function from emacs 24 for use on
+emacs 23, except with the one emacs 24 only function it calls
+inlined."
+  (unless (consp chars)
+    (error "Called `read-char-choice' without valid char choices"))
+  (let (char done show-help (helpbuf " *Char Help*"))
+    (let ((cursor-in-echo-area t)
+          (executing-kbd-macro executing-kbd-macro)
+         (esc-flag nil))
+      (save-window-excursion         ; in case we call help-form-show
+       (while (not done)
+         (unless (get-text-property 0 'face prompt)
+           (setq prompt (propertize prompt 'face 'minibuffer-prompt)))
+         (setq char (let ((inhibit-quit inhibit-keyboard-quit))
+                      (read-key prompt)))
+         (and show-help (buffer-live-p (get-buffer helpbuf))
+              (kill-buffer helpbuf))
+         (cond
+          ((not (numberp char)))
+          ;; If caller has set help-form, that's enough.
+          ;; They don't explicitly have to add help-char to chars.
+          ((and help-form
+                (eq char help-char)
+                (setq show-help t)
+                ;; This is an inlined copy of help-form-show as that
+                ;; was introduced in emacs 24 too.
+                (let ((msg (eval help-form)))
+                  (if (stringp msg)
+                      (with-output-to-temp-buffer " *Char Help*"
+                        (princ msg))))))
+          ((memq char chars)
+           (setq done t))
+          ((and executing-kbd-macro (= char -1))
+           ;; read-event returns -1 if we are in a kbd macro and
+           ;; there are no more events in the macro.  Attempt to
+           ;; get an event interactively.
+           (setq executing-kbd-macro nil))
+          ((not inhibit-keyboard-quit)
+           (cond
+            ((and (null esc-flag) (eq char ?\e))
+             (setq esc-flag t))
+            ((memq char '(?\C-g ?\e))
+             (keyboard-quit))))))))
+    ;; Display the question with the answer.  But without cursor-in-echo-area.
+    (message "%s%s" prompt (char-to-string char))
+    char)))
+
+;; End of compatibility functions
+
+(provide 'notmuch-compat)
index 1f0d1678466479d72cfb65532bb0b15149d0dde4..5dc6797068c876619bc36f57cd2ffa4c9ae5e9ab 100644 (file)
@@ -27,6 +27,7 @@
 (require 'mm-view)
 (require 'mm-decode)
 (require 'cl)
+(require 'notmuch-compat)
 
 (unless (require 'notmuch-version nil t)
   (defconst notmuch-emacs-version "unknown"
index ea75bb9ee8acb722a12b6495d21e333db3f16cbc..a754b60c7ea3d828202b89482cc52c5785cd6599 100644 (file)
@@ -249,7 +249,7 @@ If CREATE is non-nil then create the folder if necessary."
       ;; typo, or just the user want a new folder, let the user decide
       ;; how to deal with it.
       (error
-       (let ((response (read-char-choice
+       (let ((response (notmuch-read-char-choice
                        "Insert failed: (r)etry, (c)reate folder, (i)gnore, or  (e)dit the header? "
                        '(?r ?c ?i ?e))))
         (case response
@@ -335,7 +335,7 @@ if needed."
     ;; fix it in some way.
     (let* ((prompt (format "Fcc %s is not a maildir: (r)etry, (c)reate folder, (i)gnore, or  (e)dit the header? "
                           fcc-header))
-           (response (read-char-choice prompt '(?r ?c ?i ?e))))
+           (response (notmuch-read-char-choice prompt '(?r ?c ?i ?e))))
         (case response
               (?r (notmuch-maildir-fcc-file-fcc fcc-header))
               (?c (if (file-writable-p fcc-header)
diff --git a/emacs/notmuch-pkg.el.tmpl b/emacs/notmuch-pkg.el.tmpl
new file mode 100644 (file)
index 0000000..de97baa
--- /dev/null
@@ -0,0 +1,6 @@
+;; %AG%
+(define-package
+  "notmuch"
+  %VERSION%
+  "Emacs based front-end (MUA) for notmuch"
+  nil)
diff --git a/version b/version
index 610e28725be0c15d7ab0ced6fa2b394233a49f38..fda96dcf630480faba9f7c348e0c757555613e3a 100644 (file)
--- a/version
+++ b/version
@@ -1 +1 @@
-0.23.1
+0.23.2