From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-3.7 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,RDNS_NONE,SPF_HELO_NONE,SPF_NONE shortcircuit=no autolearn=no autolearn_force=no version=3.4.2 Received: from vger.kernel.org (unknown [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id 101E01F5AD for ; Sun, 12 Apr 2020 22:25:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726171AbgDLWZN (ORCPT ); Sun, 12 Apr 2020 18:25:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.18]:57160 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725954AbgDLWZN (ORCPT ); Sun, 12 Apr 2020 18:25:13 -0400 Received: from pb-smtp1.pobox.com (pb-smtp1.pobox.com [64.147.108.70]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7703BC0A88B5 for ; Sun, 12 Apr 2020 15:25:13 -0700 (PDT) Received: from pb-smtp1.pobox.com (unknown [127.0.0.1]) by pb-smtp1.pobox.com (Postfix) with ESMTP id C217C5A543; Sun, 12 Apr 2020 18:25:12 -0400 (EDT) (envelope-from junio@pobox.com) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=sasl; bh=6kT+EZ0QxQlxG5WNj2jJ9HgFGyI=; b=raF27Y JUWzeA+ZgF6GvoM6+KOta+pVSINgWr338DOmqcE+cigG4+GhCGoANaYyIEwl6tJY AK3UXB+d3BPqwjHMETg02mxBHsZ5Sd+NXtkDx3MBmbHxT95hXRm0cldujF1BfQgM ZG2F//tZs+RqLq9lWUi+NBJzN3hxGC02gjGoo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; q=dns; s=sasl; b=BmJdvYdW+rj+SkkzDOIUEkKRRtXQktS9 WcirRYIVta8AUwAG6jlD/DOb7Wul8vcdOGjTNDibHp6ohGSpYrASuuCDkMre2goP m2ZMH+PcmcbEhjXFpiLrj/AjQjWUzGaiIhRYfv6UdmKVrbGd2jLAhx7OnmNOUG3S RUtECJEhY/s= Received: from pb-smtp1.nyi.icgroup.com (unknown [127.0.0.1]) by pb-smtp1.pobox.com (Postfix) with ESMTP id B95D55A542; Sun, 12 Apr 2020 18:25:12 -0400 (EDT) (envelope-from junio@pobox.com) Received: from pobox.com (unknown [34.74.119.39]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pb-smtp1.pobox.com (Postfix) with ESMTPSA id 451C15A541; Sun, 12 Apr 2020 18:25:12 -0400 (EDT) (envelope-from junio@pobox.com) From: Junio C Hamano To: Johannes Schindelin Cc: SZEDER =?utf-8?Q?G=C3=A1bor?= , Johannes Schindelin via GitGitGadget , git@vger.kernel.org Subject: Re: [PATCH 2/5] ci/lib: allow running in GitHub Actions References: <20200403084654.GK2224@szeder.dev> <20200410153131.GM2224@szeder.dev> Date: Sun, 12 Apr 2020 15:25:11 -0700 In-Reply-To: (Junio C. Hamano's message of "Sun, 12 Apr 2020 15:12:16 -0700") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Pobox-Relay-ID: 79B1F118-7D0C-11EA-955B-C28CBED8090B-77302942!pb-smtp1.pobox.com Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org Junio C Hamano writes: > ... Two 'test' before && may yield > success or failure and they may control whether the assignment to > CI_OS_NAME is done or skipped, but I expect that they do not affect > how "set -e" behaves. Heh, I should just have quoted from https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_09 Look for "set -e" where three bullet points are there. The relevant is the second one. 2. The -e setting shall be ignored when executing the compound list following the while, until, if, or elif reserved word, a pipeline beginning with the ! reserved word, or any command of an AND-OR list other than the last. The test to see what the current value of CI_OS_NAME is is a command of an AND list that is not the last one (the last one being the assignment), so its failure does not allow "set -e" to abort the shell.