Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 3A3B9431FBD for ; Wed, 5 Mar 2014 07:40:51 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DYK2xDksSwzB for ; Wed, 5 Mar 2014 07:40:42 -0800 (PST) Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) by olra.theworths.org (Postfix) with ESMTP id 70E05431FAE for ; Wed, 5 Mar 2014 07:40:42 -0800 (PST) Received: from guru.guru-group.fi (localhost [IPv6:::1]) by guru.guru-group.fi (Postfix) with ESMTP id 1E20C100245; Wed, 5 Mar 2014 17:40:34 +0200 (EET) From: Tomi Ollila To: David Bremner , Jani Nikula , notmuch@notmuchmail.org Subject: Re: [PATCH v2 00/13] literal folder: prefix, new path: prefix In-Reply-To: <87d2i0vhbi.fsf@zancas.localnet> References: <87mwh8mn58.fsf@zancas.localnet> <87siqxiwlc.fsf@nikula.org> <8738ix4qeg.fsf@tethera.net> <87fvmwvpbm.fsf@zancas.localnet> <87d2i0vhbi.fsf@zancas.localnet> User-Agent: Notmuch/0.17+112~g4e0c1d5 (http://notmuchmail.org) Emacs/24.3.1 (x86_64-unknown-linux-gnu) X-Face: HhBM'cA~ MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Mar 2014 15:40:51 -0000 On Wed, Mar 05 2014, David Bremner wrote: > Tomi Ollila writes: >> >> (IIRC openssl sha256 is available at least in Mac OS X, probably in other >> BSD:s & Solaris too) >> > > OTOH sha256sum is in coreutils, so everywhere with a gnu userland has > it. Some might not have openssl (it's priority optional on Debian, > e.g.). Aaah these response times are a pleasure... :D cd $TEST_DIRECTORY/test-databases if hash sha256sum 2>/dev/null then sha256sum --quiet --check ${dbtarball}.sha256 || error "checksum of database failed" else # opportunistically try to run openssl sha256 in case sha256sum is not available read sha256sum_exp filename < ${dbtarball}.sha256 sha256sum_act=`openssl sha256 "${dbtarball}" | sed 's/ .*//'` test "$sha256sum_exp" = "$sha256sum_act" || error "checksum of database failed" fi cd - >& /dev/null > > d Tomi