Skip to content

Commit

Permalink
chore: update pipeline and docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Dokuqui committed Feb 18, 2024
1 parent 352858a commit 6ae9bcd
Show file tree
Hide file tree
Showing 4 changed files with 2,087 additions and 1,257 deletions.
57 changes: 42 additions & 15 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,37 @@
name: Node.js CI/CD
name: Force Version CI/CD

on:
push:
branches:
- main

pull_request:
branches: [ main ]

permissions:
packages: write

jobs:
lint:
name: Lint Code Base
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Lint Code Base
uses: github/super-linter@v5
env:
VALIDATE_ALL_CODEBASE: false
DEFAULT_BRANCH: master
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VALIDATE_JSCPD: false
VALIDATE_TYPESCRIPT_STANDARD: false
VALIDATE_MARKDOWN: false

install:
runs-on: ubuntu-latest

Expand All @@ -14,15 +40,15 @@ jobs:
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '20.11.1'

- name: Install dependencies
run: npm ci

- name: Cache dependencies
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: |
~/.npm
Expand All @@ -45,12 +71,12 @@ jobs:
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '20.11.1'

- name: Restore dependencies cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: |
~/.npm
Expand All @@ -64,17 +90,18 @@ jobs:
- name: Run unit tests
run: npm run test-coverage

publish:
release:
runs-on: ubuntu-latest
needs: test

needs:
- lint
- test
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
steps:
- name: Install Dependencies
uses: actions/setup-node@v3
- uses: actions/checkout@v3
- uses: actions/setup-node@v4
with:
node-version: '20.11.1'

- name: Publish to npm
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Run Semantic-Release
run: npx semantic-release --debug
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ Documentation:

Created by: `Illia Semenov`

Last Updated: [07/02/2024]
Last Updated: [18/02/2024]

© 2024 `Illia Semenov`. All rights reserved.
Loading

0 comments on commit 6ae9bcd

Please sign in to comment.