1 Return-Path: <too@guru-group.fi>
\r
2 X-Original-To: notmuch@notmuchmail.org
\r
3 Delivered-To: notmuch@notmuchmail.org
\r
4 Received: from localhost (localhost [127.0.0.1])
\r
5 by olra.theworths.org (Postfix) with ESMTP id BCF7F431FB6
\r
6 for <notmuch@notmuchmail.org>; Tue, 4 Sep 2012 07:49:16 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]
\r
13 Received: from olra.theworths.org ([127.0.0.1])
\r
14 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
15 with ESMTP id KK4xdBF8ymcy for <notmuch@notmuchmail.org>;
\r
16 Tue, 4 Sep 2012 07:49:14 -0700 (PDT)
\r
17 Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34])
\r
18 by olra.theworths.org (Postfix) with ESMTP id 8C411431FBD
\r
19 for <notmuch@notmuchmail.org>; Tue, 4 Sep 2012 07:49:14 -0700 (PDT)
\r
20 Received: by guru.guru-group.fi (Postfix, from userid 501)
\r
21 id BE7F310014E; Tue, 4 Sep 2012 17:49:20 +0300 (EEST)
\r
22 From: Tomi Ollila <tomi.ollila@iki.fi>
\r
23 To: notmuch@notmuchmail.org
\r
24 Subject: Release checks v3
\r
25 Date: Tue, 4 Sep 2012 17:49:11 +0300
\r
26 Message-Id: <1346770153-14947-1-git-send-email-tomi.ollila@iki.fi>
\r
27 X-Mailer: git-send-email 1.7.1
\r
28 Cc: tomi.ollila@iki.fi
\r
29 X-BeenThere: notmuch@notmuchmail.org
\r
30 X-Mailman-Version: 2.1.13
\r
32 List-Id: "Use and development of the notmuch mail system."
\r
33 <notmuch.notmuchmail.org>
\r
34 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
35 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
36 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
37 List-Post: <mailto:notmuch@notmuchmail.org>
\r
38 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
39 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
40 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
41 X-List-Received-Date: Tue, 04 Sep 2012 14:49:17 -0000
\r
43 This if V3 of release-check.sh patches, displacing
\r
45 id:"1346491928-2356-1-git-send-email-tomi.ollila@iki.fi"
\r
49 Bash kept, mainly for pipefail -- and that possible future pipeline
\r
50 additions have more protection.
\r
52 Added set -o posix lessens drifts to more bashishms -- and somewhere was
\r
53 mentioned that posix mode provides a bit more robust pipefail...
\r
55 Changed that one short circuit & continues to if... elif... fi construct.
\r
57 Used *[^0-9.]*) for matching non-digit and non-dot characters; this
\r
58 was really nice one.
\r
60 One formatting change (added newline).
\r
62 Removed last 'exit 0'.
\r
66 Something related: Some good pages for shell differences can be browsed at
\r
67 http://www.in-ulm.de/~mascheck/
\r
69 Diffdiff of the changes follows:
\r
71 --- v2/release-checks.sh
\r
72 +++ v3/release-checks.sh
\r
73 @@ -10,13 +10,12 @@ then echo
\r
78 set -o pipefail # bash feature
\r
80 # Avoid locale-specific differences in output of executed commands
\r
81 LANG=C LC_ALL=C; export LANG LC_ALL
\r
83 -readonly DEFAULT_IFS="$IFS"
\r
85 readonly PV_FILE='bindings/python/notmuch/version.py'
\r
87 # Using array here turned out to be unnecessarily complicated
\r
88 @@ -28,9 +27,10 @@ append_emsg ()
\r
90 for f in ./version debian/changelog NEWS "$PV_FILE"
\r
92 - test -f $f || { append_emsg "File '$f' is missing"; continue; }
\r
93 - test -r $f || { append_emsg "File '$f' is unreadable"; continue; }
\r
94 - test -s $f || append_emsg "File '$f' is empty"
\r
95 + if [ ! -f "$f" ]; then append_emsg "File '$f' is missing"
\r
96 + elif [ ! -r "$f" ]; then append_emsg "File '$f' is unreadable"
\r
97 + elif [ ! -s "$f" ]; then append_emsg "File '$f' is empty"
\r
102 @@ -62,18 +62,15 @@ verfail ()
\r
105 echo -n "Checking that '$VERSION' is good with digits and periods... "
\r
106 -if [ -z "${VERSION//[0123456789.]/}" ] # bash feature
\r
109 - .*) verfail "'$VERSION' begins with a period" ;;
\r
110 - *.) verfail "'$VERSION' ends with a period" ;;
\r
111 - *..*) verfail "'$VERSION' contains two consecutive periods" ;;
\r
112 - *.*) echo Yes. ;;
\r
113 - *) verfail "'$VERSION' is a single number" ;;
\r
116 - verfail "'$VERSION' contains other characters than digits and periods"
\r
120 + verfail "'$VERSION' contains other characters than digits and periods" ;;
\r
121 + .*) verfail "'$VERSION' begins with a period" ;;
\r
122 + *.) verfail "'$VERSION' ends with a period" ;;
\r
123 + *..*) verfail "'$VERSION' contains two consecutive periods" ;;
\r
124 + *.*) echo Yes. ;;
\r
125 + *) verfail "'$VERSION' is a single number" ;;
\r
129 # In the rest of this file, tests collect list of errors to be fixed
\r
130 @@ -168,7 +165,9 @@ manfiles=`find man -type f | sort`
\r
132 for mp in $manfiles
\r
134 - case $mp in *.[0-9]) ;; # fall below this 'case ... esac'
\r
136 + *.[0-9]) ;; # fall below this 'case ... esac'
\r
138 */Makefile.local | */Makefile ) continue ;;
\r
139 */.gitignore) continue ;;
\r
141 @@ -201,7 +200,6 @@ echo 'All checks this script executed completed successfully.'
\r
142 echo 'Make sure that everything else mentioned in RELEASING'
\r
143 echo 'file is in order, too.'
\r
148 # mode: shell-script
\r