diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d07d482..1d81c39 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -2,6 +2,11 @@ name: Build sqlite artifact on: workflow_call: + inputs: + ref: + description: "git ref" + type: string + default: master jobs: build: @@ -12,6 +17,9 @@ jobs: steps: - name: Checkout repository uses: actions/checkout@v3 + with: + repository: fluencelabs/sqlite + ref: ${{ inputs.ref }} - name: Setup wasi-sdk run: | @@ -21,10 +29,21 @@ jobs: - name: Setup Rust toolchain uses: actions-rust-lang/setup-rust-toolchain@v1 - - name: Setup marine - uses: fluencelabs/setup-marine@v1 + - name: Download marine artifact + id: marine + uses: actions/download-artifact@v3 + continue-on-error: true with: - version: 0.13.0 + name: marine + path: ~/.local/bin + + - name: Make marine executable + if: steps.marine.outcome == 'success' + run: chmod +x ~/.local/bin/marine + + - name: Setup marine + if: steps.marine.outcome == 'failure' + uses: fluencelabs/setup-marine@v1 - name: Build sqlite-wasm run: make diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index ee9a286..b8be576 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -16,6 +16,8 @@ jobs: build: name: "sqlite" uses: ./.github/workflows/build.yml + with: + ref: ${{ github.ref }} snapshot: needs: build diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 72ba350..0145eec 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -38,6 +38,8 @@ jobs: if: needs.release-please.outputs.release-created needs: release-please uses: ./.github/workflows/build.yml + with: + ref: ${{ github.ref }} publish: runs-on: ubuntu-latest