From: David Bremner <david@tethera.net>
To: notmuch@notmuchmail.org, notmuch@freelists.org
Subject: [PATCH 01/23] emacs: convert to use format-version 3
Date: Sat, 3 Jun 2017 14:47:32 -0300 [thread overview]
Message-ID: <20170603174754.16911-2-david@tethera.net> (raw)
In-Reply-To: <20170603174754.16911-1-david@tethera.net>
Keeping the emacs interface running old format-versions makes it
impossible to test new format-versions or deprecate old ones.
---
emacs/notmuch-address.el | 2 +-
emacs/notmuch-mua.el | 2 +-
emacs/notmuch-query.el | 2 +-
emacs/notmuch-show.el | 3 ++-
emacs/notmuch-tree.el | 2 +-
emacs/notmuch.el | 2 +-
test/T310-emacs.sh | 2 +-
test/T450-emacs-show.sh | 2 +-
8 files changed, 9 insertions(+), 8 deletions(-)
diff --git a/emacs/notmuch-address.el b/emacs/notmuch-address.el
index d504ff2d..74a4584f 100644
--- a/emacs/notmuch-address.el
+++ b/emacs/notmuch-address.el
@@ -317,7 +317,7 @@ execution, CALLBACK is called when harvesting finishes."
(when config-query
(format " and (%s)" config-query)))
from-or-to-me-query))
- (args `("address" "--format=sexp" "--format-version=2"
+ (args `("address" "--format=sexp" "--format-version=3"
,(if sent "--output=recipients" "--output=sender")
"--deduplicate=address"
,query)))
diff --git a/emacs/notmuch-mua.el b/emacs/notmuch-mua.el
index 93747b1c..ddfb9811 100644
--- a/emacs/notmuch-mua.el
+++ b/emacs/notmuch-mua.el
@@ -176,7 +176,7 @@ mutiple parts get a header."
(unless (bolp) (insert "\n")))
(defun notmuch-mua-reply (query-string &optional sender reply-all)
- (let ((args '("reply" "--format=sexp" "--format-version=1"))
+ (let ((args '("reply" "--format=sexp" "--format-version=3"))
(process-crypto notmuch-show-process-crypto)
reply
original)
diff --git a/emacs/notmuch-query.el b/emacs/notmuch-query.el
index 436ad160..48acb551 100644
--- a/emacs/notmuch-query.el
+++ b/emacs/notmuch-query.el
@@ -30,7 +30,7 @@ A thread is a forest or list of trees. A tree is a two element
list where the first element is a message, and the second element
is a possibly empty forest of replies.
"
- (let ((args '("show" "--format=sexp" "--format-version=1")))
+ (let ((args '("show" "--format=sexp" "--format-version=3")))
(if notmuch-show-process-crypto
(setq args (append args '("--decrypt"))))
(setq args (append args search-terms))
diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
index e7c22da0..21fcc036 100644
--- a/emacs/notmuch-show.el
+++ b/emacs/notmuch-show.el
@@ -1660,9 +1660,10 @@ current thread."
;; dme: Would it make sense to use a macro for many of these?
+;; XXX TODO figure out what to do about multiple filenames
(defun notmuch-show-get-filename ()
"Return the filename of the current message."
- (notmuch-show-get-prop :filename))
+ (car (notmuch-show-get-prop :filename)))
(defun notmuch-show-get-header (header &optional props)
"Return the named header of the current message, if any."
diff --git a/emacs/notmuch-tree.el b/emacs/notmuch-tree.el
index d4d40761..6812d7e9 100644
--- a/emacs/notmuch-tree.el
+++ b/emacs/notmuch-tree.el
@@ -917,7 +917,7 @@ the same as for the function notmuch-tree."
(notmuch-tag-clear-cache)
(let ((proc (notmuch-start-notmuch
"notmuch-tree" (current-buffer) #'notmuch-tree-process-sentinel
- "show" "--body=false" "--format=sexp" "--format-version=2"
+ "show" "--body=false" "--format=sexp" "--format-version=3"
message-arg search-args))
;; Use a scratch buffer to accumulate partial output.
;; This buffer will be killed by the sentinel, which
diff --git a/emacs/notmuch.el b/emacs/notmuch.el
index 40b9fabd..a4a7fd8b 100644
--- a/emacs/notmuch.el
+++ b/emacs/notmuch.el
@@ -990,7 +990,7 @@ the configured default sort order."
(save-excursion
(let ((proc (notmuch-start-notmuch
"notmuch-search" buffer #'notmuch-search-process-sentinel
- "search" "--format=sexp" "--format-version=2"
+ "search" "--format=sexp" "--format-version=3"
(if oldest-first
"--sort=oldest-first"
"--sort=newest-first")
diff --git a/test/T310-emacs.sh b/test/T310-emacs.sh
index ef599849..8a881941 100755
--- a/test/T310-emacs.sh
+++ b/test/T310-emacs.sh
@@ -1014,7 +1014,7 @@ YYY/notmuch_fail exited with status 1 (see *Notmuch errors* for more details)
=== ERROR ===
[XXX]
YYY/notmuch_fail exited with status 1
-command: YYY/notmuch_fail search --format\=sexp --format-version\=2 --sort\=newest-first tag\:inbox
+command: YYY/notmuch_fail search --format\=sexp --format-version\=3 --sort\=newest-first tag\:inbox
exit status: 1"
test_begin_subtest "Search handles subprocess warnings"
diff --git a/test/T450-emacs-show.sh b/test/T450-emacs-show.sh
index 74d546bd..d302efb6 100755
--- a/test/T450-emacs-show.sh
+++ b/test/T450-emacs-show.sh
@@ -191,7 +191,7 @@ This is an error (see *Notmuch errors* for more details)
=== ERROR ===
[XXX]
This is an error
-command: YYY/notmuch_fail show --format\\=sexp --format-version\\=1 --exclude\\=false \\' \\* \\'
+command: YYY/notmuch_fail show --format\\=sexp --format-version\\=3 --exclude\\=false \\' \\* \\'
exit status: 1
stderr:
This is an error
--
2.11.0
next prev parent reply other threads:[~2017-06-03 17:49 UTC|newest]
Thread overview: 44+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-03 17:47 David Bremner
2017-06-03 17:47 ` David Bremner [this message]
2017-06-03 17:47 ` [PATCH 02/23] devel/schemata: describe version 4 David Bremner
2017-06-03 17:47 ` [PATCH 03/23] cli: implement structured output " David Bremner
2017-07-04 11:37 ` David Bremner
2017-06-03 17:47 ` [PATCH 04/23] test/multipart: reorganize creation of multipart message David Bremner
2017-06-03 17:47 ` [PATCH 05/23] test: mark inclusion of headers as broken in gmime-2.x David Bremner
2017-06-03 17:47 ` [PATCH 06/23] test: mark test as broken in gmime 3.0 David Bremner
2017-06-03 17:47 ` [PATCH 07/23] test/crypto: mark extra space in userid as a bug in gmime-2.6 David Bremner
2017-07-05 20:26 ` Tomi Ollila
2017-07-06 14:15 ` Daniel Kahn Gillmor
2017-06-03 17:47 ` [PATCH 08/23] test: add test for modified pgp/mime signed message David Bremner
2017-06-03 17:47 ` [PATCH 09/23] test/crypto: add test for corrupted signatures David Bremner
2017-07-05 11:03 ` David Bremner
2017-06-03 17:47 ` [PATCH 10/23] test: test parsing of malformed from addresses David Bremner
2017-06-03 17:47 ` [PATCH 11/23] cli: replace use of g_mime_message_get_date_as_string David Bremner
2017-06-03 17:47 ` [PATCH 12/23] cli: replace use of g_mime_message_get_reply_to David Bremner
2017-06-03 17:47 ` [PATCH 13/23] lib/cli: replace use of g_mime_message_get_sender David Bremner
2017-06-03 17:47 ` [PATCH 14/23] cli: replace use of g_mime_message_get_recipients David Bremner
2017-06-03 17:47 ` [PATCH 15/23] util: fake gmime-2.6 compatible API for gmime-3.0 David Bremner
2017-06-03 17:47 ` [PATCH 16/23] cli: generalize use of GMIME_SIGNATURE_{ERROR, STATUS} to gmime-3 David Bremner
2017-07-07 22:18 ` Daniel Kahn Gillmor
2017-06-03 17:47 ` [PATCH 17/23] cli: hide rename of GMimeCertificateTrust David Bremner
2017-06-03 17:47 ` [PATCH 18/23] lib: wrap use of g_mime_utils_header_decode_date David Bremner
2017-06-03 17:47 ` [PATCH 19/23] lib: refactor _notmuch_messsage_file_get_combined_header David Bremner
2017-06-03 17:47 ` [PATCH 20/23] lib: add version of _n_m_f_get_combinded_header for gmime 3.0 David Bremner
2017-06-03 17:47 ` [PATCH 21/23] lib: paper over allocation difference David Bremner
2017-06-03 17:47 ` [PATCH 22/23] cli: make keyid from fingerprint in gmime 3.0 David Bremner
2017-06-03 17:47 ` [PATCH 23/23] cli: wrap getting uid David Bremner
2017-07-14 13:12 ` [PATCH 1/3] config: deprecate/drop crypto.gpg_path under gmime 2.6/3.0 Daniel Kahn Gillmor
2017-07-14 13:12 ` [PATCH 2/3] clean up use of constants in g_mime_multipart_ wrappers Daniel Kahn Gillmor
2017-07-14 13:12 ` [PATCH 3/3] crypto: Avoid explicit handling of GMimeCryptoContext in gmime 3.0 Daniel Kahn Gillmor
2017-07-15 11:55 ` David Bremner
2017-07-15 18:57 ` [PATCH 1/4] cli/crypto: treat failure to create a crypto context as fatal David Bremner
2017-07-15 18:57 ` [PATCH 2/4] cli/crypto: eliminated compiler warnings about unused arguments David Bremner
2017-07-15 18:57 ` [PATCH 3/4] crypto: Avoid explicit handling of GMimeCryptoContext in gmime 3 David Bremner
2017-07-15 22:45 ` Daniel Kahn Gillmor
2017-07-15 23:01 ` [PATCH v2 1/4] cli/crypto: treat failure to create a crypto context as fatal Daniel Kahn Gillmor
2017-07-15 23:01 ` [PATCH v2 2/4] cli/crypto: eliminated compiler warnings about unused arguments Daniel Kahn Gillmor
2017-07-15 23:01 ` [PATCH v2 3/4] crypto: Avoid explicit handling of GMimeCryptoContext in gmime 3 Daniel Kahn Gillmor
2017-07-15 23:01 ` [PATCH v2 4/4] crypto: clean up unused definitions in gmime 3.0 Daniel Kahn Gillmor
2017-07-16 10:53 ` [PATCH v2 1/4] cli/crypto: treat failure to create a crypto context as fatal David Bremner
2017-07-15 18:57 ` [PATCH 4/4] crypto: clean up unused definitions in gmime 3.0 David Bremner
2017-07-14 13:19 ` [PATCH 1/3] config: deprecate/drop crypto.gpg_path under gmime 2.6/3.0 Daniel Kahn Gillmor
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170603174754.16911-2-david@tethera.net \
--to=david@tethera.net \
--cc=notmuch@freelists.org \
--cc=notmuch@notmuchmail.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).