unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH] perf-test: use command line arguments for directories
@ 2014-03-07 12:03 David Bremner
  2014-03-10 21:58 ` Tomi Ollila
  2014-03-15 18:25 ` David Bremner
  0 siblings, 2 replies; 3+ messages in thread
From: David Bremner @ 2014-03-07 12:03 UTC (permalink / raw)
  To: notmuch

It seems that between version 1.26 and 1.27 of gnu tar, directories to
be extracted read with --files-from are no longer recursively extacted.
This patch puts them on the command line instead.
---
 performance-test/perf-test-lib.sh | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/performance-test/perf-test-lib.sh b/performance-test/perf-test-lib.sh
index 44708cf..75e3d87 100644
--- a/performance-test/perf-test-lib.sh
+++ b/performance-test/perf-test-lib.sh
@@ -63,8 +63,9 @@ add_email_corpus ()
     fi
 
     file_list=$(mktemp file_listXXXXXX)
+    declare -a extract_dirs
     if [ ! -d "$TAG_CORPUS" ] ; then
-	echo "notmuch-email-corpus/tags" >> $file_list
+	extract_dirs=("${extract_dirs[@]}" notmuch-email-corpus/tags)
     fi
 
     if [ ! -d "$MAIL_CORPUS" ] ; then
@@ -72,11 +73,11 @@ add_email_corpus ()
 	    sed s,^,notmuch-email-corpus/, < \
 		${TEST_DIRECTORY}/corpus/manifest/MANIFEST.${corpus_size} >> $file_list
 	else
-	    echo "notmuch-email-corpus/mail" >> $file_list
+	    extract_dirs=("${extract_dirs[@]}" notmuch-email-corpus/mail)
 	fi
     fi
 
-    if [[ -s $file_list ]]; then
+    if [[ -s $file_list || -n "${extract_dirs[*]}" ]]; then
 
 	printf "Unpacking corpus\n"
 	tar --checkpoint=.5000 --extract --strip-components=1 \
@@ -84,7 +85,7 @@ add_email_corpus ()
 	    --use-compress-program ${XZ} \
 	    --file ../download/notmuch-email-corpus-${PERFTEST_VERSION}.tar.xz \
 	    --anchored --recursion \
-	    --files-from $file_list
+	    --files-from $file_list "${extract_dirs[@]}"
 
 	printf "\n"
 
-- 
1.8.5.3

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] perf-test: use command line arguments for directories
  2014-03-07 12:03 [PATCH] perf-test: use command line arguments for directories David Bremner
@ 2014-03-10 21:58 ` Tomi Ollila
  2014-03-15 18:25 ` David Bremner
  1 sibling, 0 replies; 3+ messages in thread
From: Tomi Ollila @ 2014-03-10 21:58 UTC (permalink / raw)
  To: David Bremner, notmuch

On Fri, Mar 07 2014, David Bremner <david@tethera.net> wrote:

> It seems that between version 1.26 and 1.27 of gnu tar, directories to
> be extracted read with --files-from are no longer recursively extacted.
> This patch puts them on the command line instead.
> ---

LGTM.

Tomi

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] perf-test: use command line arguments for directories
  2014-03-07 12:03 [PATCH] perf-test: use command line arguments for directories David Bremner
  2014-03-10 21:58 ` Tomi Ollila
@ 2014-03-15 18:25 ` David Bremner
  1 sibling, 0 replies; 3+ messages in thread
From: David Bremner @ 2014-03-15 18:25 UTC (permalink / raw)
  To: notmuch

David Bremner <david@tethera.net> writes:

> It seems that between version 1.26 and 1.27 of gnu tar, directories to
> be extracted read with --files-from are no longer recursively extacted.
> This patch puts them on the command line instead.

pushed. 

Hopfully this unbreaks the test suite for people using gnu tar 1.27

d

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-03-15 18:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-07 12:03 [PATCH] perf-test: use command line arguments for directories David Bremner
2014-03-10 21:58 ` Tomi Ollila
2014-03-15 18:25 ` David Bremner

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).