From 6c36c0e600ff8a2f329838ab13a64bde2a80b283 Mon Sep 17 00:00:00 2001 From: Jesse de Wit Date: Fri, 10 Nov 2023 21:30:51 +0100 Subject: [PATCH] add react native CI --- .github/workflows/main.yml | 35 +++++++++++++++++++++++++++++- snippets/react-native/package.json | 2 +- 2 files changed, 35 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index f69d3afa..ed6f694d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -38,7 +38,7 @@ jobs: repository: breez/breez-sdk ref: ${{ needs.setup.outputs.sdk-ref }} package-version: ${{ needs.setup.outputs.package-version }} - packages-to-publish: '["csharp", "flutter", "golang"]' + packages-to-publish: '["csharp", "flutter", "golang", "react-native"]' use-dummy-binaries: true check-rust: @@ -156,6 +156,39 @@ jobs: - name: Build the csharp project working-directory: snippets/csharp run: dotnet build + + check-react-native: + needs: + - setup + - build-packages + name: Check react native snippets + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v3 + + - name: Set Node.js 20.x + uses: actions/setup-node@v3 + with: + node-version: 20.x + + - name: Download archived package + uses: actions/download-artifact@v3 + with: + name: react-native-${{ needs.setup.outputs.package-version }} + path: snippets/react-native/packages + + - name: Install dependencies + working-directory: snippets/react-native + run: yarn + + - name: Check syntax + working-directory: snippets/react-native + run: tsc + + - name: Check formatting + working-directory: snippets/react-native + run: yarn run lint check-golang: needs: diff --git a/snippets/react-native/package.json b/snippets/react-native/package.json index a77d45da..4060ac94 100644 --- a/snippets/react-native/package.json +++ b/snippets/react-native/package.json @@ -9,7 +9,7 @@ "format": "eslint . --ext .js,.jsx,.ts,.tsx --fix" }, "dependencies": { - "@breeztech/react-native-breez-sdk": "0.2.7", + "@breeztech/react-native-breez-sdk": "file:./packages/sdk-react-native.tgz", "react": "18.1.0", "react-native": "0.70.6" },