Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update GitHub Actions actions to the latest versions #15619

Merged
merged 28 commits into from
Apr 11, 2024
Merged
Show file tree
Hide file tree
Changes from 25 commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
51f7676
Update Workflow actions to the latest versions
MikeAlhayek Mar 28, 2024
cc688ee
Update WF
MikeAlhayek Mar 29, 2024
cc1ca92
Automated Change
MikeAlhayek Mar 29, 2024
fdc5a08
Fix assets validation
MikeAlhayek Mar 29, 2024
093eb66
fix syntax
MikeAlhayek Mar 29, 2024
8f2f820
try to target the correct branch
MikeAlhayek Mar 29, 2024
63c3309
update wf
MikeAlhayek Mar 29, 2024
f630289
restore
MikeAlhayek Mar 29, 2024
4ddb243
Merge branch 'main' into ma/update-workflows
Piedone Apr 10, 2024
999a69b
Using safe commit hash for eps1lon/actions-label-merge-conflict
Piedone Apr 10, 2024
dbd1e3f
Removing depdendency on outdated UnicornGlobal/has-changes-action
Piedone Apr 10, 2024
9b7da7a
Displaying the output of assets_validation too
Piedone Apr 10, 2024
8595968
Renaming the issue-metrics workflow because it's not just about issues
Piedone Apr 10, 2024
458a68b
Updating peter-evans/create-issue-from-file
Piedone Apr 10, 2024
ba789ef
Temporarily running Community Metrics on push
Piedone Apr 10, 2024
0368301
Removing unnecessary "Monthly" from workflow name
Piedone Apr 10, 2024
afef9d3
Docs hint
Piedone Apr 10, 2024
5599dde
Revert "Temporarily running Community Metrics on push"
Piedone Apr 10, 2024
fbbdef1
Typo
Piedone Apr 10, 2024
e42766d
Temporarily running other workflows on pull_request too
Piedone Apr 10, 2024
7bb23b4
Removing Preview workflow check so it'll run
Piedone Apr 10, 2024
cbd1f51
Removing even more checks
Piedone Apr 10, 2024
3ccd618
Fixing Release build output
Piedone Apr 10, 2024
eaa3c6c
Reverting temporary changes
Piedone Apr 10, 2024
f94ec35
Reverting more temporary changes
Piedone Apr 10, 2024
d1d06ea
Updating tunaitis/contributor-map to the latest too
Piedone Apr 11, 2024
8216742
Automated Change
Piedone Apr 11, 2024
4089e0a
Punctuation
Piedone Apr 11, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 19 additions & 12 deletions .github/workflows/assets_validation.yml
Piedone marked this conversation as resolved.
Show resolved Hide resolved
Piedone marked this conversation as resolved.
Show resolved Hide resolved
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This rightfully fails since it notices issues, but otherwise works correctly: #15726

Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
name: Frontend Assets build validation
name: Frontend Assets Build Validation
on:
# manual trigger
# Manual trigger.
workflow_dispatch:
jobs:
test-npm-build:
name: Test building assets
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
Expand All @@ -19,11 +19,18 @@ jobs:
npm install
npm run rebuild
- name: Check if git has changes
id: changes
uses: UnicornGlobal/[email protected]
- name: Changes detected after building assets
if: steps.changes.outputs.changed == 1
run: |
git status
echo "Please make sure to build them properly before pushing"
exit -1
shell: pwsh
run: |
$changes = git status --porcelain

if ($changes)
{
Write-Output 'Please make sure to build the assets properly before pushing, see https://docs.orchardcore.net/en/latest/docs/guides/gulp-pipeline/.'
Write-Output 'The following files changed:'
Write-Output $changes
exit -1
}
else
{
Write-Host "No uncommitted changes found. Repository is clean."
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Monthly Issue and Pull Request Metrics
name: Community Metrics
on:
workflow_dispatch:
schedule:
Expand All @@ -11,7 +11,7 @@ permissions:

jobs:
build:
name: Generate Issue and Pull Request Metrics
name: Generate Community Metrics
runs-on: ubuntu-latest
steps:
- name: Get Dates For Last Month
Expand All @@ -28,7 +28,7 @@ jobs:
Write-Output "LAST_MONTH=$firstDay..$lastDay" >> $env:GITHUB_ENV

- name: Compute Issue Metrics
uses: github/issue-metrics@v2
uses: github/issue-metrics@v3
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SEARCH_QUERY: 'repo:OrchardCMS/OrchardCore is:issue created:${{ env.LAST_MONTH }} -reason:"not planned" -label:"community metrics"'
Expand All @@ -41,7 +41,7 @@ jobs:
Add-Content -Path ./community_metrics.md -Value (Get-Content -Path ./issue_metrics.md -Raw)

- name: Compute Pull Request Metrics
uses: github/issue-metrics@v2
uses: github/issue-metrics@v3
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SEARCH_QUERY: 'repo:OrchardCMS/OrchardCore is:pr created:${{ env.LAST_MONTH }} -label:dontmerge -label:notready -is:draft'
Expand All @@ -54,7 +54,7 @@ jobs:
Add-Content -Path ./community_metrics.md -Value ([Environment]::NewLine + $content)

- name: Compute Q&A Discussion Request Metrics
uses: github/issue-metrics@v2
uses: github/issue-metrics@v3
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SEARCH_QUERY: 'repo:OrchardCMS/OrchardCore type:discussions created:${{ env.LAST_MONTH }} category:Q&A'
Expand All @@ -72,8 +72,8 @@ jobs:
Get-Content ./community_metrics.md >> $env:GITHUB_STEP_SUMMARY

- name: Create Issue
# v4.0.1
uses: peter-evans/create-issue-from-file@433e51abf769039ee20ba1293a088ca19d573b7f
# v5.0.0
uses: peter-evans/create-issue-from-file@24452a72d85239eacf1468b0f1982a9f3fec4c94
with:
title: Monthly community metrics report for ${{ env.LAST_MONTH }}
token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
32 changes: 16 additions & 16 deletions .github/workflows/functional_all_db.yml
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are failing but with this: #15628. Otherwise, the update is good.

Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,20 @@ jobs:
container:
image: cypress/included:9.6.1
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
# We need to install dotnet in the docker container.
- uses: actions/setup-dotnet@v3
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: "15"
- name: Functional Tests
run: |
cd test/OrchardCore.Tests.Functional
npm install
npm run mvc:test
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: failure()
with:
name: functional-mvc-screenshots
Expand All @@ -39,17 +39,17 @@ jobs:
container:
image: cypress/included:9.6.1
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
# We need to install dotnet in the docker container.
- uses: actions/setup-dotnet@v3
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Functional Tests
run: |
cd test/OrchardCore.Tests.Functional
npm install
npm run cms:test
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: failure()
with:
name: functional-cms-sqlite-failure
Expand Down Expand Up @@ -80,17 +80,17 @@ jobs:
OrchardCore__ConnectionString: "User ID=postgres;Password=admin;Host=postgres;Port=5432;Database=app;"
OrchardCore__DatabaseProvider: "Postgres"
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
# We need to install dotnet in the docker container.
- uses: actions/setup-dotnet@v3
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Functional Tests
run: |
cd test/OrchardCore.Tests.Functional
npm install
npm run cms:test
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: failure()
with:
name: functional-cms-postgresql-failure
Expand All @@ -117,17 +117,17 @@ jobs:
OrchardCore__ConnectionString: "server=mysql;uid=root;pwd=test123;database=test"
OrchardCore__DatabaseProvider: "MySql"
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
# We need to install dotnet in the docker container.
- uses: actions/setup-dotnet@v3
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Functional Tests
run: |
cd test/OrchardCore.Tests.Functional
npm install
npm run cms:test
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: failure()
with:
name: functional-cms-mysql-failure
Expand All @@ -153,17 +153,17 @@ jobs:
OrchardCore__ConnectionString: "Server=mssql;Database=tempdb;User Id=sa;Password=Password12!;Encrypt=False"
OrchardCore__DatabaseProvider: "SqlConnection"
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
# We need to install dotnet in the docker container.
- uses: actions/setup-dotnet@v3
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Functional Tests
run: |
cd test/OrchardCore.Tests.Functional
npm install
npm run cms:test
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: failure()
with:
name: functional-cms-mssql-failure
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/mac_unit_test_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
runs-on: macos-latest
name: Unit Tests
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Build and test
run: |
dotnet build -c Release
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/main_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ jobs:
matrix:
os: [ubuntu-latest, windows-latest]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "15"
- uses: actions/setup-dotnet@v3
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Build
Expand All @@ -38,7 +38,7 @@ jobs:
npm install
npm run cms:test
npm run mvc:test
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: matrix.os == 'ubuntu-latest' && failure()
with:
name: Functional Test failure
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/pr_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ jobs:
os: [ubuntu-latest, windows-latest]
name: Build & Test
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "15"
- uses: actions/setup-dotnet@v3
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Build
Expand All @@ -37,7 +37,7 @@ jobs:
npm install
npm run cms:test
npm run mvc:test
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: matrix.os == 'ubuntu-latest' && failure()
with:
name: functional-test-failure
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/preview_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ jobs:
Write-Output "Commits found in the last 24 hours: $hasCommitFromLastDay."
$shouldPublish = $hasCommitFromLastDay -and '${{ github.event_name }}' -eq 'schedule'
"should-publish=$($shouldPublish ? 'true' : 'false')" >> $Env:GITHUB_OUTPUT
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
if: steps.check-publish.outputs.should-publish == 'true'
with:
node-version: "15"
- uses: actions/setup-dotnet@v3
- uses: actions/setup-dotnet@v4
if: steps.check-publish.outputs.should-publish == 'true'
with:
dotnet-version: '8.0.x'
Expand All @@ -47,7 +47,7 @@ jobs:
npm install
npm run cms:test
npm run mvc:test
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: failure()
with:
name: Functional Test failure
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/release_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@ jobs:
VERSION="${arrTag[2]}"
VERSION="${VERSION//v}"
echo VERSION:${VERSION}
echo ::set-output name=VERSION::${VERSION}
echo "VERSION=${VERSION}" >> $GITHUB_OUTPUT
shell: bash
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "15"
- uses: actions/setup-dotnet@v3
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Set build number
Expand All @@ -52,7 +52,7 @@ jobs:
npm install
npm run cms:test
npm run mvc:test
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: matrix.os == 'ubuntu-latest' && failure()
with:
name: Functional Test failure
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/validate_pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ jobs:
timeout-minutes: 3
steps:
- name: Check for Merge Conflict in PR
# releases/2.1.0
uses: eps1lon/actions-label-merge-conflict@92924ba33a60e436034b0ac3838de523bf7df071
# v3.0.0
uses: eps1lon/actions-label-merge-conflict@e62d7a53ff8be8b97684bffb6cfbbf3fc1115e2e
with:
repoToken: ${{ secrets.GITHUB_TOKEN }}
commentOnDirty: "This pull request has merge conflicts. Please resolve those before requesting a review."
Expand Down
Loading
Loading