diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5e478571499541..b35f83efb8b98a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -313,6 +313,7 @@ jobs: env: CROSS_BUILD_WASIX: cross-build/wasix WASMER_PACKAGE: wasmer_package + WASMER_DIR: "/opt/wasmer" name: 'Publish to Wasmer' steps: - uses: actions/checkout@v4 @@ -327,9 +328,14 @@ jobs: - name: "List dirs" run: | ls + - name: "Install Wasmer" + run: | + mkdir ${{ env.WASMER_DIR }} + curl https://get.wasmer.io -sSfL | sh - name: "Publish to wasmer.io" run: | - ./Tools/wasm/wasmer-publish.sh publish "${{ secrets.WASMER_CIUSER_PROD_TOKEN }}" amin "3.14-${{ github.sha }}" + PATH="$PATH:${{ env.WASMER_DIR }}/bin" \ + ./Tools/wasm/wasmer-publish.sh publish "${{ secrets.WASMER_CIUSER_PROD_TOKEN }}" "3.14-${{ github.sha }}" # test_hypothesis: # name: "Hypothesis tests on Ubuntu" diff --git a/Tools/wasm/wasmer-publish.sh b/Tools/wasm/wasmer-publish.sh index ba1a84710e70f3..09cfe5e046e521 100755 --- a/Tools/wasm/wasmer-publish.sh +++ b/Tools/wasm/wasmer-publish.sh @@ -49,19 +49,13 @@ if test -z "$2"; then fi TOKEN=$2 -if test -z "$3"; then - echo "Owner is not specified" - exit 1 -fi -OWNER=$3 - if [ "$1" == "push" ]; then # populate wasmer.toml populate_wasmer_toml wasmer package push --registry "wasmer.io" --token $TOKEN $WASMER_PACKAGE elif [ "$1" == "publish" ]; then - if test -z "$4"; then + if test -z "$3"; then echo "Version is not specified" exit 1 fi @@ -70,5 +64,5 @@ elif [ "$1" == "publish" ]; then # populate wasmer.toml populate_wasmer_toml $VERSION - wasmer package publish --registry "wasmer.io" --token $TOKEN --owner $OWNER $WASMER_PACKAGE + wasmer package publish --registry "wasmer.io" --token $TOKEN --non-interactive $WASMER_PACKAGE fi \ No newline at end of file