diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7c9eaf2..e6d9af3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,11 +45,6 @@ jobs: - name: test run: npm run test - - name: echo - env: - NODE_AUTH_TOKEN: ${{ vars.NPM_TOKEN }} - run: echo $NODE_AUTH_TOKEN - release: if: ${{ startsWith(github.ref, 'refs/tags') && startsWith(github.ref_name, 'v') }} runs-on: ubuntu-latest @@ -57,6 +52,6 @@ jobs: environment: release steps: - name: release - run: npm publish --tag beta + run: npm run release env: - NODE_AUTH_TOKEN: ${{ vars.NPM_PUBLISH_TOKEN }} + NPM_AUTH_TOKEN: ${{ vars.NPM_PUBLISH_TOKEN }} diff --git a/.gitignore b/.gitignore index 9bc8152..e2896e5 100644 --- a/.gitignore +++ b/.gitignore @@ -4,4 +4,5 @@ dist node_modules *.o wasm -*.tmp \ No newline at end of file +*.tmp +.npmrc \ No newline at end of file diff --git a/README.md b/README.md index fb09eb9..8051b16 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,4 @@ -# WIP - -# `webp.wasm` +# webp.wasm webp.wasm is a pure Webassembly / Javascript port of libwebp. diff --git a/package.json b/package.json index 675dd98..41dace6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "wasm-webp", - "version": "0.0.1-beta.1", + "version": "0.0.1-beta.2", "description": "", "main": "dist/cjs/index.js", "module": "dist/esm/index.js", @@ -30,7 +30,8 @@ "build-wasm:cjs": "bash ./build.sh", "build:esm": "npm run build-wasm:esm && tsc -m ES6 --outDir ./dist/esm && cp -r src/*.d.ts dist", "build:cjs": "npm run build-wasm:cjs && tsc -m commonjs --outDir ./dist/cjs && cp -r src/*.d.ts dist", - "test": "node --experimental-wasm-modules --experimental-vm-modules ./node_modules/jest/bin/jest.js" + "test": "node --experimental-wasm-modules --experimental-vm-modules ./node_modules/jest/bin/jest.js", + "release": "bash ./release.sh" }, "author": "nieyuyao", "license": "MIT", diff --git a/release.sh b/release.sh new file mode 100644 index 0000000..18323a1 --- /dev/null +++ b/release.sh @@ -0,0 +1,3 @@ +echo -e "registry=https://registry.npmjs.org/\n_authToken=$NPM_AUTH_TOKEN" > .npmrc + +npm publish --tag beta