Skip to content
This repository has been archived by the owner on Aug 31, 2023. It is now read-only.

Commit

Permalink
splitting rustup target
Browse files Browse the repository at this point in the history
  • Loading branch information
xunilrj committed Dec 1, 2022
1 parent c0db69d commit 5b88d54
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 22 deletions.
24 changes: 10 additions & 14 deletions .github/workflows/release_cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
- os: ubuntu-20.04
target: x86_64-unknown-linux-gnu
code-target: linux-x64
container: quay.io/opencv-ci/opencv-python-manylinux2014_x86_64
container: ghcr.io/rome/rome-ci-x86-64-centos7:latest
- os: ubuntu-20.04
target: aarch64-unknown-linux-gnu
code-target: linux-arm64
Expand All @@ -72,7 +72,10 @@ jobs:

name: Package ${{ matrix.code-target }}
runs-on: ${{ matrix.os }}
container: ${{ matrix.container }}
container:
image: ${{ matrix.container }}
env:
PATH: /root/.cargo/bin:/root/.nvm/versions/node/v14.21.1/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/bin

needs: check
if: needs.check.outputs.version_changed == 'true' || needs.check.outputs.nightly == 'true'
Expand All @@ -83,22 +86,16 @@ jobs:
prerelease: ${{ needs.check.outputs.prerelease }}

steps:
- name: Who Am I
run: whoami && printenv

- name: Checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 1

- name: Install Node.js
uses: actions/setup-node@v3
with:
node-version: 14.x

- name: Install Rustup
uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.target }}
default: true
- name: Install Rust toolchain
run: rustup target add ${{ matrix.target }}

- name: Install arm64 toolchain
if: matrix.code-target == 'linux-arm64'
Expand All @@ -109,7 +106,6 @@ jobs:
- name: Audit crates.io dependencies
if: matrix.code-target == 'linux-x64'
run: |
cargo install cargo-audit
cargo audit
# Build the CLI binary
Expand Down
15 changes: 7 additions & 8 deletions .github/workflows/release_lsp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,10 @@ jobs:
- os: ubuntu-20.04
target: x86_64-unknown-linux-gnu
code-target: linux-x64
container: ghcr.io/rome/rome-ci-x86-64-centos7:latest
- os: ubuntu-20.04
target: aarch64-unknown-linux-gnu
code-target: linux-arm64
container: quay.io/opencv-ci/opencv-python-manylinux2014-aarch64:20220824
- os: macos-11
target: x86_64-apple-darwin
code-target: darwin-x64
Expand All @@ -93,7 +93,9 @@ jobs:

name: Package ${{ matrix.code-target }}
runs-on: ${{ matrix.os }}
container: ${{ matrix.container }}
container:
image: ${{ matrix.container }}
options: --user root

needs: check
env:
Expand All @@ -106,17 +108,14 @@ jobs:
prerelease: ${{ env.prerelease }}

steps:
- name: Who Am I
run: whoami

- name: Checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 1

- name: Install Rustup
if: matrix.code-target == 'linux-x64'
run: |
which rustup || curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
source "$HOME/.cargo/env"
- name: Install Rust toolchain
run: rustup target add ${{ matrix.target }}

Expand Down

0 comments on commit 5b88d54

Please sign in to comment.