diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..62c328d --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,20 @@ +name: Publish Package to npmjs +on: + release: + types: [published] +jobs: + build: + runs-on: ubuntu-latest + permissions: + contents: read + id-token: write + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: '20.x' + registry-url: 'https://registry.npmjs.org' + - run: yarn install --frozen-lockfile + - run: npm publish --provenance --access public + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} diff --git a/.npmignore b/.npmignore new file mode 100644 index 0000000..d458a1b --- /dev/null +++ b/.npmignore @@ -0,0 +1,26 @@ +node_modules +npm-debug.log +.DS_Store +*.tgz +*.log +.idea +.vscode +*.sublime-project +*.sublime-workspace +*.swp +*.swo +*.bak +*.tmp +*.temp +*.orig +*.rej +*.patch +*.diff +*.sublime-* +docs* +.github* +.editorconfig +.gitattributes +.markdownlint.json +.prettierrc.js +CODE_OF_CONDUCT.md diff --git a/package.json b/package.json index ca29cbd..73fb284 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "strapi-plugin-redis", + "name": "@strapi-community/plugin-redis", "version": "2.0.0", "description": "Plugin used to centralize management of Redis connections in Strapi", "strapi": {