Rename init() to connect() #194
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
# Controls when the workflow will run | |
on: | |
# Triggers the workflow on push events but only for the "main" branch | |
push: | |
branches: [ main ] | |
pull_request: | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
fmt: | |
name: Cargo Format | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Check Rust Formatting | |
run: | | |
cd lib | |
cargo fmt -- --check | |
cd ../cli | |
cargo fmt -- --check | |
clippy: | |
name: Cargo Clippy | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Check Rust Clippy | |
run: | | |
cd lib | |
cargo clippy -- -D warnings | |
cd ../cli | |
cargo clippy -- -D warnings | |
build-bindings: | |
name: Test ls-sdk-bindings | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
- name: Build ls-sdk-bindings | |
working-directory: lib/ls-sdk-bindings | |
run: cargo build | |
- name: Setup python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.11' | |
- name: Run ls-sdk-bindings tests | |
run: | | |
curl -o jna-5.12.1.jar https://repo1.maven.org/maven2/net/java/dev/jna/jna/5.12.1/jna-5.12.1.jar | |
export CLASSPATH=$(pwd)/jna-5.12.1.jar; | |
cd lib/ls-sdk-bindings | |
cargo test | |
react-native: | |
name: Check react native bindings | |
runs-on: macOS-14 | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
- name: React native codegen | |
working-directory: lib/ls-sdk-react-native | |
run: | | |
yarn global add tslint typescript | |
brew update | |
brew install kotlin ktlint swiftformat | |
make react-native | |
- name: Check git status | |
env: | |
GIT_PAGER: cat | |
run: | | |
status=$(git status --porcelain) | |
if [[ -n "$status" ]]; then | |
echo "Git status has changes" | |
echo "$status" | |
git diff | |
exit 1 | |
else | |
echo "No changes in git status" | |
fi |