Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
yuzhichang committed Dec 25, 2023
1 parent 6218e9f commit 3af4afa
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,13 @@ jobs:
- name: Check out code
uses: actions/checkout@v3

- name: Set Datetime Variable
run: echo "RELEASE_DATETIME=$(date -d @${{ env.GITHUB_RUN_STARTED }} --rfc-3339=seconds)" >> $GITHUB_ENV
- name: Prepare release body
run: |
RELEASE_DATETIME=$(date -d @${{ env.GITHUB_RUN_STARTED }} --rfc-3339=seconds)"
cat <<EOF > release_template.md
Release created at $RELEASE_DATETIME
EOF
envsubst < release_template.md > release_body.md
- name: Build source tarball
run: git archive --format=tar HEAD | gzip > archive.tgz
Expand All @@ -27,6 +32,7 @@ jobs:
token: ${{ secrets.MY_GITHUB_TOKEN }} # Use the secret as an environment variable
prerelease: true
tag_name: nightly
body: Nightly created at ${{ env.RELEASE_DATETIME }}
# The body field does not support environment variable substitution directly.
body_path: release_body.md
files: |
*.tgz

0 comments on commit 3af4afa

Please sign in to comment.