diff --git a/.github/workflows/on-push.yml b/.github/workflows/on-push.yml index d9725e5c4..5ce5f250c 100644 --- a/.github/workflows/on-push.yml +++ b/.github/workflows/on-push.yml @@ -43,6 +43,18 @@ jobs: npm ci npm run build + - name: Try publishing infoview-api + if: ${{ startsWith(github.ref, 'refs/tags/v') && !endsWith(github.ref, '-pre') && matrix.os == 'ubuntu-latest' }} + continue-on-error: true + run: | + npm publish --workspace=lean4-infoview-api --access=public + + - name: Try publishing infoview + if: ${{ startsWith(github.ref, 'refs/tags/v') && !endsWith(github.ref, '-pre') && matrix.os == 'ubuntu-latest' }} + continue-on-error: true + run: | + npm publish --workspace=lean4-infoview --access=public + - name: Package run: npm run package --workspace=lean4 if: ${{ !startsWith(github.ref, 'refs/tags/v') || !endsWith(github.ref, '-pre') }} @@ -111,3 +123,6 @@ jobs: uses: GabrielBB/xvfb-action@v1.0 with: run: npm run test + + env: + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} diff --git a/.npmrc b/.npmrc new file mode 100644 index 000000000..ae643592e --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +//registry.npmjs.org/:_authToken=${NPM_TOKEN} diff --git a/lean4-infoview/package.json b/lean4-infoview/package.json index 55b9fb958..20f9e5a97 100644 --- a/lean4-infoview/package.json +++ b/lean4-infoview/package.json @@ -1,6 +1,6 @@ { "name": "@leanprover/infoview", - "version": "0.7.0", + "version": "0.7.1", "description": "An interactive display for the Lean 4 theorem prover.", "scripts": { "watch": "rollup --config --environment NODE_ENV:development --watch", @@ -39,7 +39,7 @@ "@types/marked": "^4.3.1", "@types/react": "^18.2.15", "@types/react-dom": "^18.2.7", - "current-release": "npm:@leanprover/infoview@^0.7.0", + "current-release": "npm:@leanprover/infoview@latest", "react": "^18.2.0", "react-dom": "^18.2.0", "rollup": "^3.26.2", diff --git a/package-lock.json b/package-lock.json index e91d114a0..71e4f771e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -28,7 +28,7 @@ }, "lean4-infoview": { "name": "@leanprover/infoview", - "version": "0.7.0", + "version": "0.7.1", "license": "Apache-2.0", "dependencies": { "@leanprover/infoview-api": "~0.4.0", @@ -51,7 +51,7 @@ "@types/marked": "^4.3.1", "@types/react": "^18.2.15", "@types/react-dom": "^18.2.7", - "current-release": "npm:@leanprover/infoview@^0.7.0", + "current-release": "npm:@leanprover/infoview@latest", "react": "^18.2.0", "react-dom": "^18.2.0", "rollup": "^3.26.2",