Merge pull request #6 from selsa-inube/cm/ids1534/add-auto-publish #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Auto Release | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
autorelease: | |
runs-on: ubuntu-latest | |
if: ${{ !contains(github.event.head_commit.message, 'ci skip') && !contains(github.event.head_commit.message, 'skip ci') }} | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v3 | |
with: | |
token: ${{ secrets.GH_TOKEN }} | |
fetch-depth: 0 | |
- name: Setup Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: "20" | |
registry-url: "https://registry.npmjs.org/" | |
scope: "@inubekit" | |
always-auth: true | |
- name: Configure Git | |
run: | | |
git config --global user.email YOUR_EMAIL | |
git config --global user.name YOUR_NAME | |
- name: Configure npm | |
run: | | |
echo "@inubekit:registry=https://registry.npmjs.org/" >> .npmrc | |
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" >> .npmrc | |
- name: Install Dependencies | |
run: npm install | |
- name: Run auto shipit | |
run: npx auto shipit | |
env: | |
GH_TOKEN: ${{ secrets.GH_TOKEN }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} |