Skip to content

Commit

Permalink
chore(cli): update CI template (#1416)
Browse files Browse the repository at this point in the history
  • Loading branch information
Brooooooklyn committed Jan 3, 2023
1 parent c58972e commit abc4566
Showing 1 changed file with 8 additions and 66 deletions.
74 changes: 8 additions & 66 deletions cli/src/new/ci-template.ts
Expand Up @@ -77,21 +77,11 @@ jobs:
- host: ubuntu-latest
target: 'aarch64-linux-android'
build: |
export CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android24-clang"
export CC="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android24-clang"
export CXX="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android24-clang++"
export AR="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/llvm-ar"
export PATH="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin:\${PATH}"
yarn build --target aarch64-linux-android
\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/llvm-strip *.node
- host: ubuntu-latest
target: 'armv7-linux-androideabi'
build: |
export CARGO_TARGET_ARMV7_LINUX_ANDROIDEABI_LINKER="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi24-clang"
export CC="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi24-clang"
export CXX="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi24-clang++"
export AR="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/llvm-ar"
export PATH="\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin:\${PATH}"
yarn build --target armv7-linux-androideabi
\${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/llvm-strip *.node
- host: ubuntu-latest
Expand All @@ -106,7 +96,7 @@ jobs:
target: 'aarch64-pc-windows-msvc'
build: yarn build --target aarch64-pc-windows-msvc
name: stable - \${{ matrix.settings.target }} - node@16
name: stable - \${{ matrix.settings.target }} - node@18
runs-on: \${{ matrix.settings.host }}
steps:
Expand All @@ -116,18 +106,16 @@ jobs:
uses: actions/setup-node@v3
if: \${{ !matrix.settings.docker }}
with:
node-version: 16
node-version: 18
check-latest: true
cache: yarn
- name: Install
uses: actions-rs/toolchain@v1
uses: dtolnay/rust-toolchain@stable
if: \${{ !matrix.settings.docker }}
with:
profile: minimal
override: true
toolchain: stable
target: \${{ matrix.settings.target }}
targets: \${{ matrix.settings.target }}
- name: Cache cargo
uses: actions/cache@v3
Expand Down Expand Up @@ -162,7 +150,7 @@ jobs:
uses: actions/setup-node@v3
if: matrix.settings.target == 'i686-pc-windows-msvc'
with:
node-version: 16
node-version: 18
check-latest: true
cache: yarn
architecture: x86
Expand Down Expand Up @@ -230,6 +218,7 @@ jobs:
yarn test
rm -rf node_modules
rm -rf target
rm -rf .yarn/cache
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -262,12 +251,6 @@ jobs:
check-latest: true
cache: 'yarn'
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
path: .yarn/cache
key: npm-cache-test-\${{ matrix.settings.target }}-\${{ matrix.node }}-\${{ hashFiles('yarn.lock') }}
- name: 'Install dependencies'
run: yarn install
Expand Down Expand Up @@ -304,12 +287,6 @@ jobs:
check-latest: true
cache: 'yarn'
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
path: .yarn/cache
key: npm-cache-test-linux-x64-gnu-\${{ matrix.node }}
- name: 'Install dependencies'
run: yarn install
Expand Down Expand Up @@ -346,12 +323,6 @@ jobs:
check-latest: true
cache: 'yarn'
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
path: .yarn/cache
key: npm-cache-test-x86_64-unknown-linux-musl-\${{ matrix.node }}
- name: 'Install dependencies'
run: |
yarn config set supportedArchitectures.libc "musl"
Expand Down Expand Up @@ -395,12 +366,6 @@ jobs:
run: ls -R .
shell: bash
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
path: .yarn/cache
key: npm-cache-test-linux-aarch64-gnu-\${{ matrix.node }}
- name: Install dependencies
run: |
yarn config set supportedArchitectures.cpu "arm64"
Expand Down Expand Up @@ -439,12 +404,6 @@ jobs:
run: ls -R .
shell: bash
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
path: .yarn/cache
key: npm-cache-test-linux-aarch64-musl-\${{ matrix.node }}
- name: Install dependencies
run: |
yarn config set supportedArchitectures.cpu "arm64"
Expand Down Expand Up @@ -486,12 +445,6 @@ jobs:
run: ls -R .
shell: bash
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
path: .yarn/cache
key: npm-cache-test-linux-arm-gnueabihf-\${{ matrix.node }}
- name: Install dependencies
run: |
yarn config set supportedArchitectures.cpu "arm"
Expand Down Expand Up @@ -519,16 +472,10 @@ jobs:
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
check-latest: true
cache: yarn
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
path: .yarn/cache
key: npm-cache-test-x86_64-apple-darwin-16-\${{ hashFiles('yarn.lock') }}
- name: 'Install dependencies'
run: yarn install
Expand Down Expand Up @@ -571,15 +518,10 @@ jobs:
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
check-latest: true
cache: 'yarn'
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
path: .yarn/cache
key: npm-cache-ubuntu-latest-publish
- name: 'Install dependencies'
run: yarn install
Expand Down

0 comments on commit abc4566

Please sign in to comment.