diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 86470d0..911c6f3 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,18 +1,21 @@ -name: Publish Package to npmjs +name: Publish package on: - release: - types: [published] + push: + branches: + - main jobs: build: runs-on: ubuntu-latest + permissions: + contents: read + packages: write steps: - uses: actions/checkout@v4 - # Setup .npmrc file to publish to npm - uses: actions/setup-node@v4 with: node-version: "20.x" - registry-url: "https://registry.npmjs.org" + registry-url: "https://npm.pkg.github.com" - run: npm ci - - run: npm publish --provenance --access public + - run: npm publish env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} + NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/package.json b/package.json index 804cb25..4f58d9f 100644 --- a/package.json +++ b/package.json @@ -3,6 +3,10 @@ "version": "1.0.0", "private": true, "main": "eslint.config.mjs", + "repository": { + "type": "git", + "url": "https://github.com/Disruptive-Industries/eslint-config.git" + }, "peerDependencies": { "eslint": ">= 9" },