From e64259b34c93645dc2eda533ee47e923d6cd5cdc Mon Sep 17 00:00:00 2001 From: jrfnl Date: Fri, 9 Dec 2022 03:02:53 +0100 Subject: [PATCH] GH Actions: minor simplification ... of the bash `date` command in the earlier pulled cache busting. --- .github/workflows/tests.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 79fcdb37c..9ad597321 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -31,8 +31,8 @@ jobs: - name: Install Composer dependencies uses: "ramsey/composer-install@v2" with: - # Bust the cache at least once a month - output format: YYYY-MM-DD. - custom-cache-suffix: $(date -u -d "-0 month -$(($(date +%d)-1)) days" "+%F") + # Bust the cache at least once a month - output format: YYYY-MM. + custom-cache-suffix: $(date -u "+%Y-%m") - name: Check coding standards id: phpcs @@ -71,8 +71,8 @@ jobs: - name: Install Composer dependencies uses: "ramsey/composer-install@v2" with: - # Bust the cache at least once a month - output format: YYYY-MM-DD. - custom-cache-suffix: $(date -u -d "-0 month -$(($(date +%d)-1)) days" "+%F") + # Bust the cache at least once a month - output format: YYYY-MM. + custom-cache-suffix: $(date -u "+%Y-%m") - name: Lint against parse errors if: ${{ matrix.php != '8.3' }} @@ -126,16 +126,16 @@ jobs: if: ${{ matrix.php != '8.3' }} uses: "ramsey/composer-install@v2" with: - # Bust the cache at least once a month - output format: YYYY-MM-DD. - custom-cache-suffix: $(date -u -d "-0 month -$(($(date +%d)-1)) days" "+%F") + # Bust the cache at least once a month - output format: YYYY-MM. + custom-cache-suffix: $(date -u "+%Y-%m") - name: Install PHP packages - ignore-platform-reqs if: ${{ matrix.php == '8.3' }} uses: "ramsey/composer-install@v2" with: composer-options: --ignore-platform-reqs - # Bust the cache at least once a month - output format: YYYY-MM-DD. - custom-cache-suffix: $(date -u -d "-0 month -$(($(date +%d)-1)) days" "+%F") + # Bust the cache at least once a month - output format: YYYY-MM. + custom-cache-suffix: $(date -u "+%Y-%m") # Install postfix and automatically retry if the install failed, which happens reguarly. # @link https://github.com/marketplace/actions/retry-step