Skip to content

Commit

Permalink
fix: force install dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
bonomat committed Feb 20, 2024
1 parent 3fcf01c commit bf0a04f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 26 deletions.
16 changes: 3 additions & 13 deletions .github/workflows/android-fastlane.yml
Original file line number Diff line number Diff line change
Expand Up @@ -95,17 +95,10 @@ jobs:
- uses: actions/cache@v4
id: cache-deps
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
./rust/target
key: ${{ runner.os }}-cargo-build-release-android-${{ hashFiles('**/Cargo.lock') }}

- name: Install just
if: steps.cache-deps.outputs.cache-hit != 'true'
run: cargo install just
run: cargo install just --force

- uses: actions/setup-java@v3
with:
Expand All @@ -121,15 +114,13 @@ jobs:
bundle info fastlane
- name: Install FFI bindings
if: steps.cache-deps.outputs.cache-hit != 'true'
run: just deps-gen
run: just deps-gen --force

- name: Add Rust targets
run: rustup target add armv7-linux-androideabi aarch64-linux-android

# #499, https://github.com/actions/virtual-environments/issues/5595
- name: Configure ndk
if: steps.cache-deps.outputs.cache-hit != 'true'
run: |
ANDROID_HOME=$HOME/Library/Android/sdk
SDKMANAGER=$ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager
Expand All @@ -139,8 +130,7 @@ jobs:
ln -sfn $ANDROID_HOME/ndk/21.4.7075529 $ANDROID_HOME/ndk-bundle
- name: Install cargo ndk
if: steps.cache-deps.outputs.cache-hit != 'true'
run: cargo install cargo-ndk
run: cargo install cargo-ndk --force

- name: Generate FFI bindings
run: just gen
Expand Down
13 changes: 2 additions & 11 deletions .github/workflows/ios-fastlane.yml
Original file line number Diff line number Diff line change
Expand Up @@ -122,16 +122,9 @@ jobs:

- uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
./rust/target
key: ${{ runner.os }}-cargo-build-release-ios-${{ hashFiles('**/Cargo.lock') }}

- name: Install just
if: steps.cache-deps.outputs.cache-hit != 'true'
run: cargo install just --force

- name: Install fastlane
Expand All @@ -142,12 +135,10 @@ jobs:
bundle info fastlane
- name: Install FFI bindings
if: steps.cache-deps.outputs.cache-hit != 'true'
run: just deps-gen
run: just deps-gen --force

- name: Install ios dependencies
if: steps.cache-deps.outputs.cache-hit != 'true'
run: cargo install cargo-lipo
run: cargo install cargo-lipo --force

- name: Set rustup targets
run: rustup target add aarch64-apple-ios x86_64-apple-ios
Expand Down
4 changes: 2 additions & 2 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ precommit: gen lint
# Install missing dependencies.
deps: deps-gen deps-android deps-ios

deps-gen:
cargo install flutter_rust_bridge_codegen@1.78.0
deps-gen args="":
cargo install flutter_rust_bridge_codegen@1.78.0 {{args}}

# Install dependencies for Android (build targets and cargo-ndk)
deps-android:
Expand Down

0 comments on commit bf0a04f

Please sign in to comment.