menggunakan css #21
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: Publish package nodejs | |
on: | |
push: | |
branches: [master] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: '18.4.0' | |
- uses: actions/cache@v2 | |
id: yarn-cache | |
with: | |
path: node_modules | |
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/yarn.lock') }} | |
- name: Install dependencies | |
if: steps.yarn-cache.outputs.cache-hit != 'true' | |
run: yarn install --frozen-lockfile | |
publish-npm: | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: '18.4.0' | |
registry-url: https://registry.npmjs.org/ | |
- uses: actions/cache@v2 | |
id: yarn-cache | |
with: | |
path: node_modules | |
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/yarn.lock') }} | |
- name: Install dependencies | |
if: steps.yarn-cache.outputs.cache-hit != 'true' | |
run: yarn install --frozen-lockfile | |
- name: Install dependencies | |
run: yarn build | |
- run: npm publish --access=public | |
env: | |
NODE_AUTH_TOKEN: ${{secrets.NPM_SECRET}} |