From 4c76bc0ef8e42211fd30bbbd3966180023090319 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20de=20Courville?= Date: Mon, 6 Feb 2023 15:52:31 +0100 Subject: [PATCH 1/4] Set release tag from time and date Set tag from time and date --- .github/workflows/deploy.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 05ce9cf0..d48bbe80 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -35,6 +35,9 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Make reference.zip run: npm run zip + - name: Set Tag Name + run: | + echo ::set-env name=TAG_NAME::$(date '+%Y-%m-%d-%H%M') - name: Create release uses: softprops/action-gh-release@v1 if: ${{ inputs.make_release }} @@ -42,4 +45,4 @@ jobs: files: reference.zip body: ${{ inputs.description }} name: 'Website ${{ inputs.version }}' - tag_name: ${{ inputs.version }} + tag_name: ${{ env.TAG_NAME }} From 279e59a48ec92c7ffef61559ac0649419ea65f1b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20de=20Courville?= Date: Mon, 6 Feb 2023 15:57:24 +0100 Subject: [PATCH 2/4] Added seconds to release tag timestamp --- .github/workflows/deploy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index d48bbe80..7d96f833 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -37,7 +37,7 @@ jobs: run: npm run zip - name: Set Tag Name run: | - echo ::set-env name=TAG_NAME::$(date '+%Y-%m-%d-%H%M') + echo ::set-env name=TAG_NAME::$(date '+%Y-%m-%d-%H%M%S') - name: Create release uses: softprops/action-gh-release@v1 if: ${{ inputs.make_release }} From 930d06e0e6a3ed60c235871ee4e3f889b08ff3a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20de=20Courville?= Date: Mon, 6 Feb 2023 22:37:52 +0100 Subject: [PATCH 3/4] Update deploy.yml Changed version to title and tweaked input descriptions --- .github/workflows/deploy.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 7d96f833..d2877ccc 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -3,12 +3,12 @@ name: Deploy Website on: workflow_dispatch: inputs: - version: - description: 'The version of the website used for the GitHub release' + title: + description: 'The name of the GitHub release' type: string required: true description: - description: 'The description of changes used in the GitHub release changelog' + description: 'The description used in the GitHub release (typically a changelog)' type: string required: true make_release: @@ -44,5 +44,5 @@ jobs: with: files: reference.zip body: ${{ inputs.description }} - name: 'Website ${{ inputs.version }}' + name: ${{ inputs.title }} tag_name: ${{ env.TAG_NAME }} From 89b82e09238ef1a39a50d205f0871709b021c553 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20de=20Courville?= Date: Tue, 7 Feb 2023 12:04:59 +0100 Subject: [PATCH 4/4] Update deploy.yml properly set the GitHub environment variable (untested) --- .github/workflows/deploy.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index d2877ccc..879a926b 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -37,7 +37,7 @@ jobs: run: npm run zip - name: Set Tag Name run: | - echo ::set-env name=TAG_NAME::$(date '+%Y-%m-%d-%H%M%S') + echo "RELEASE_DATE=$(date '+%Y-%m-%d-%H%M%S')" >> ${GITHUB_ENV} - name: Create release uses: softprops/action-gh-release@v1 if: ${{ inputs.make_release }} @@ -45,4 +45,4 @@ jobs: files: reference.zip body: ${{ inputs.description }} name: ${{ inputs.title }} - tag_name: ${{ env.TAG_NAME }} + tag_name: ${{ env.RELEASE_DATE }}