From 27e8d099722568f7349889627f00b185cdb70ff6 Mon Sep 17 00:00:00 2001 From: Michael Tautschnig Date: Sat, 2 Sep 2023 20:14:49 +0000 Subject: [PATCH] De-dup issues --- .github/workflows/toolchain-upgrade.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/toolchain-upgrade.yml b/.github/workflows/toolchain-upgrade.yml index 22895f9b6789..d6951fbe4d1a 100644 --- a/.github/workflows/toolchain-upgrade.yml +++ b/.github/workflows/toolchain-upgrade.yml @@ -31,7 +31,11 @@ jobs: current_toolchain_epoch=$(date --date $current_toolchain_date +%s) next_toolchain_date=$(date --date "@$(($current_toolchain_epoch + 86400))" +%Y-%m-%d) echo "next_toolchain_date=$next_toolchain_date" >> $GITHUB_ENV - if ! git ls-remote --exit-code origin toolchain-$next_toolchain_date ; then + if gh issue list -S \ + "Toolchain upgrade to nightly-$next_toolchain_date failed" \ + --json number,title | grep title ; then + echo "next_step=none" >> $GITHUB_ENV + elif ! git ls-remote --exit-code origin toolchain-$next_toolchain_date ; then echo "next_step=create_pr" >> $GITHUB_ENV sed -i "/^channel/ s/$current_toolchain_date/$next_toolchain_date/" rust-toolchain.toml git diff