[latex3-commits] [git/LaTeX3-latex3-latex3] main: Update GH Actions (#1167) (0c05aa26d)
GitHub
noreply at github.com
Sun Feb 5 12:37:22 CET 2023
Repository : https://github.com/latex3/latex3
On branch : main
Link : https://github.com/latex3/latex3/commit/0c05aa26db504bc4bb9fc21e5254126f37885a06
>---------------------------------------------------------------
commit 0c05aa26db504bc4bb9fc21e5254126f37885a06
Author: Yukai Chou <muzimuzhi at gmail.com>
Date: Sun Feb 5 19:37:22 2023 +0800
Update GH Actions (#1167)
* Update GH Actions
to versions that use node16 instead of the deprecated node12
* Use GH Actions context `github.ref_name`
hence drop action `frabert/replace-string-action`
>---------------------------------------------------------------
0c05aa26db504bc4bb9fc21e5254126f37885a06
.github/workflows/deploy.yaml | 27 ++++++++-------------------
.github/workflows/main.yaml | 8 ++++----
2 files changed, 12 insertions(+), 23 deletions(-)
diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml
index 9ab9334c4..950528ff0 100644
--- a/.github/workflows/deploy.yaml
+++ b/.github/workflows/deploy.yaml
@@ -16,7 +16,7 @@ jobs:
steps:
# Boilerplate
- name: Checkout repository
- uses: actions/checkout at v2
+ uses: actions/checkout at v3
# We need Ghostscript for dvips and XeTeX tests.
- run: sudo apt-get update && sudo apt-get install ghostscript
- name: Install TeX Live
@@ -37,27 +37,16 @@ jobs:
retention-days: 3
# Now create the release (this only runs if the previous steps were successful)
- name: Create GitHub release
- uses: ncipollo/release-action at 880be3d0a71bc0fa98db60201d2cbdc27324f547
+ uses: ncipollo/release-action at a2e71bdd4e7dab70ca26a852f29600c98b33153e # v1.12.0
id: release
with:
artifacts: "*.zip"
token: ${{ secrets.GITHUB_TOKEN }}
- # Determine the name of the tag we are working on. Sadly GH Actions only provides
- # github.ref which has the name prefixed with github.ref and no way to remove a prefix
- # in normal expressions, so we need an action for that.
- - name: Get name
- uses: frabert/replace-string-action at 9b62dfe3ae936b1cc380f2421c8ac9e63a4a3e85
- id: name
- if: ${{ always() }}
- with:
- pattern: "^refs/(?:heads|tags)/"
- string: ${{ github.ref }}
- replace-with: ""
# While the normal notification job only informs about failed runs, we additionally want to notify about successful releases.
- name: Send mail
# The explicit commit hash ensures that this can't be used by dawidd6 as a
# backdoor to execute arbitrary code during our runs.
- uses: dawidd6/action-send-mail at ceb614a2c5737d913f2d2729e2bcc70ad933382b
+ uses: dawidd6/action-send-mail at 6063705cefe50cb915fc53bb06d4049cae2953b2 # v3.7.1
with:
# Currently using my (Marcel's) mail server for sending mails.
server_address: typesetting.eu
@@ -73,14 +62,14 @@ jobs:
# to send from the mail address.
from: LaTeX CI <github at latex-project.org>
# Determine the subject and body of the mail.
- subject: "Version ${{steps.name.outputs.replaced}} of ${{github.repository}} has been released"
+ subject: "Version ${{github.ref_name}} of ${{github.repository}} has been released"
body: |
- The release ${{steps.name.outputs.replaced}} has been created for ${{github.repository}}.
+ The release ${{github.ref_name}} has been created for ${{github.repository}}.
More information can be found at
${{steps.release.outputs.html_url}}
- name: Send failure notification
- uses: dawidd6/action-send-mail at ceb614a2c5737d913f2d2729e2bcc70ad933382b
+ uses: dawidd6/action-send-mail at 6063705cefe50cb915fc53bb06d4049cae2953b2 # v3.7.1
if: ${{ failure() }}
with:
server_address: typesetting.eu
@@ -91,12 +80,12 @@ jobs:
from: LaTeX CI <github at latex-project.org>
priority: high
# Determine the subject and body of the mail.
- subject: "Test failure while trying to build release ${{steps.name.outputs.replaced}} in ${{github.repository}}"
+ subject: "Test failure while trying to build release ${{github.ref_name}} in ${{github.repository}}"
body: |
Test failure for ${{github.repository}}
-------------------------------------------------------------
- On tag: ${{steps.name.outputs.replaced}} (${{github.sha}})
+ On tag: ${{github.ref_name}} (${{github.sha}})
Initiated by: ${{github.actor}}
Commit URL: https://github.com/${{github.repository}}/commit/${{github.sha}}
More information: https://github.com/${{github.repository}}/actions/runs/${{github.run_id}}
diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml
index c23b432b6..c84f8e1d1 100644
--- a/.github/workflows/main.yaml
+++ b/.github/workflows/main.yaml
@@ -39,7 +39,7 @@ jobs:
steps:
# Boilerplate
- name: Checkout repository
- uses: actions/checkout at v2
+ uses: actions/checkout at v3
# We need Ghostscript for dvips and XeTeX tests.
- run: sudo apt-get update && sudo apt-get install ghostscript
- name: Install TeX Live
@@ -54,7 +54,7 @@ jobs:
# 1. If we failed running tests
- name: Archive failed test output
if: ${{ matrix.artifact_name != 'Documentation' && failure() }}
- uses: actions/upload-artifact at v2
+ uses: actions/upload-artifact at v3
with:
name: ${{ matrix.artifact_name }}
path: build/test*/*.diff
@@ -63,7 +63,7 @@ jobs:
# 2. If we succeed building documentation
- name: Archive documentation
if: ${{ matrix.artifact_name == 'Documentation' && success() }}
- uses: actions/upload-artifact at v2
+ uses: actions/upload-artifact at v3
with:
name: ${{ matrix.artifact_name }}
path: "**/*.pdf"
@@ -86,7 +86,7 @@ jobs:
- name: Send mail
# The explicit commit hash ensures that this can't be used by dawidd6 as a
# backdoor to execute arbitrary code during our runs.
- uses: dawidd6/action-send-mail at ceb614a2c5737d913f2d2729e2bcc70ad933382b
+ uses: dawidd6/action-send-mail at 6063705cefe50cb915fc53bb06d4049cae2953b2 # v3.7.1
with:
# Currently using my (Marcel's) mail server for sending mails.
server_address: typesetting.eu
More information about the latex3-commits
mailing list.