From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 1F275158094 for ; Sat, 3 Sep 2022 01:24:21 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 3679EE0824; Sat, 3 Sep 2022 01:24:20 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 1DDFFE0824 for ; Sat, 3 Sep 2022 01:24:19 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id DEAEB340E24 for ; Sat, 3 Sep 2022 01:24:18 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 26E82526 for ; Sat, 3 Sep 2022 01:24:17 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1662168184.0d01497249a825e1d39862fd9d9ed6edde9a92bf.sam@gentoo> Subject: [gentoo-commits] proj/qa-scripts:master commit in: / X-VCS-Repository: proj/qa-scripts X-VCS-Files: keyrings-export.bash X-VCS-Directories: / X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: 0d01497249a825e1d39862fd9d9ed6edde9a92bf X-VCS-Branch: master Date: Sat, 3 Sep 2022 01:24:17 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 2f8e63ce-69e8-47f4-b076-05a3c32931a4 X-Archives-Hash: 20d9308023c24eeb92fd4d87eb5bf862 commit: 0d01497249a825e1d39862fd9d9ed6edde9a92bf Author: Sam James gentoo org> AuthorDate: Sat Sep 3 01:23:04 2022 +0000 Commit: Sam James gentoo org> CommitDate: Sat Sep 3 01:23:04 2022 +0000 URL: https://gitweb.gentoo.org/proj/qa-scripts.git/commit/?id=0d014972 keyrings-export.bash: only run weekly for timestamped files Otherwise we'd end up having files like service-keys-20220905.gpg created on 20220830. Signed-off-by: Sam James gentoo.org> keyrings-export.bash | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/keyrings-export.bash b/keyrings-export.bash index 815c50b..39091f4 100755 --- a/keyrings-export.bash +++ b/keyrings-export.bash @@ -51,7 +51,13 @@ for key in service-keys committing-devs active-devs infra-devs retired-devs all- ln -s "${OUTPUT_DIR}"/keys/${key}.gpg "${OUTPUT_DIR}"/${key}.gpg fi - timestamp=$(date -u +%Y%m%d -d "monday") + timestamp=$(date -u +%Y%m%d-%A -d "monday") + + if [[ ${timestamp} != *-Monday ]] ; + break + fi + + timestamp=${timestamp/-Monday/} # Don't clobber existing timestamped keys for this period (weekly) # if we're running several times a day.