Skip to content

Commit

Permalink
ci: use newer artifact actions (#13991)
Browse files Browse the repository at this point in the history
* ci: use newer artifact actions

* ci: remove unused backport action
  • Loading branch information
ewanharris authored Sep 17, 2024
1 parent 50d8604 commit c5e553b
Show file tree
Hide file tree
Showing 11 changed files with 58 additions and 77 deletions.
10 changes: 5 additions & 5 deletions .github/actions/build-android/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@ runs:
shell: bash

- name: Setup Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ inputs.node-version }}
cache: 'npm'

- name: Setup Java
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: ${{ inputs.java-version }}
Expand All @@ -36,7 +36,7 @@ runs:
shell: bash

- name: Cache Gradle packages
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: |
~/.gradle/caches
Expand All @@ -58,7 +58,7 @@ runs:
${{ runner.os }}-ccache-
- name: Cache V8
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: dist/android/libv8
key: libv8-${{ hashFiles('dist/android/libv8/**') }}
Expand All @@ -84,7 +84,7 @@ runs:
dist/tmp/common
shell: bash

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: android-build
retention-days: 1
Expand Down
8 changes: 4 additions & 4 deletions .github/actions/build-ios/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ inputs:
runs:
using: composite
steps:
- name: Use Node.js 16.x
uses: actions/setup-node@v3
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: '16.x'
node-version: ${{ inputs.node-version }}
cache: 'npm'

- name: Install dependencies
Expand All @@ -34,7 +34,7 @@ runs:
iphone/TitaniumKit/build/TitaniumKit.xcframework
shell: bash

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: ios-build
retention-days: 1
Expand Down
24 changes: 12 additions & 12 deletions .github/actions/package/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ inputs:
runs:
using: composite
steps:
- name: Use Node.js 16.x
uses: actions/setup-node@v3
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ inputs.node-version }}
cache: 'npm'

- name: Use JDK 11
uses: actions/setup-java@v3
- name: Use JDK
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: ${{ inputs.java-version }}
Expand All @@ -32,7 +32,7 @@ runs:
shell: bash

- name: Cache Gradle packages
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: |
~/.gradle/caches
Expand All @@ -41,15 +41,15 @@ runs:
restore-keys: |
${{ runner.os }}-gradle-
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v4
with:
name: android-build

- name: Extract Android build output
run: tar -xzvf android-build.tar.gz
shell: bash

- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v4
with:
name: ios-build

Expand All @@ -58,7 +58,7 @@ runs:
shell: bash

- name: Cache Native Modules
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ${{ env.SDK_BUILD_CACHE_DIR }}
key: native-modules-${{ github.sha }}
Expand All @@ -70,21 +70,21 @@ runs:
shell: bash

- name: Archive OSX artifact
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: mobilesdk-${{ inputs.vtag }}-osx
path: |
dist/mobilesdk-*-osx.zip
- name: Archive win32 artifact
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: mobilesdk-${{ inputs.vtag }}-win32
path: |
dist/mobilesdk-*-win32.zip
- name: Archive Linux artifact
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: mobilesdk-${{ inputs.vtag }}-linux
path: |
Expand All @@ -98,7 +98,7 @@ runs:
rm -f ~/.gradle/caches/modules-2/gc.properties
shell: bash

- uses: geekyeggo/delete-artifact@v2
- uses: geekyeggo/delete-artifact@v5
with:
name: |
android-build
Expand Down
19 changes: 0 additions & 19 deletions .github/workflows/backport.yml

This file was deleted.

18 changes: 9 additions & 9 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ jobs:
USE_CCACHE: 1
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Android build
uses: ./.github/actions/build-android
with:
node-version: '18.x'
node-version: '20.x'
java-version: '17'

ios:
Expand All @@ -33,27 +33,27 @@ jobs:
DEVELOPER_DIR: /Applications/Xcode_14.3.app/Contents/Developer
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: iOS build
uses: ./.github/actions/build-ios
with:
node-version: '18.x'
node-version: '20.x'

js:
runs-on: ubuntu-latest
name: JavaScript
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Use Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '18.x'
node-version: '20.x'
cache: 'npm'

- name: Install dependencies
Expand All @@ -71,7 +71,7 @@ jobs:
needs: [android, ios, js]
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Create version tag
Expand All @@ -83,6 +83,6 @@ jobs:
- name: Package
uses: ./.github/actions/package
with:
node-version: '16.x'
node-version: '20.x'
java-version: '17'
vtag: ${{ env.vtag }}
8 changes: 4 additions & 4 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ jobs:
name: Docs
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Use Node.js 16.x
uses: actions/setup-node@v3
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: '16.x'
node-version: '20.x'
cache: 'npm'
- run: npm ci
name: Install dependencies
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/regen-builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
steps:
- name: Repository Dispatch
if: github.event.workflow_run.conclusion == 'success'
uses: peter-evans/repository-dispatch@v2
uses: peter-evans/repository-dispatch@v3
with:
event-type: regen-builds
repository: tidev/downloads-www
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/regen-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '16'
registry-url: 'https://registry.npmjs.org'
Expand All @@ -32,7 +32,7 @@ jobs:
name: Lint

- name: Repository Dispatch
uses: peter-evans/repository-dispatch@v2
uses: peter-evans/repository-dispatch@v3
with:
event-type: regen-api-docs
token: ${{ secrets.REGEN_DOCS_GITHUB_TOKEN }}
Expand Down
Loading

0 comments on commit c5e553b

Please sign in to comment.