Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tool and dependency updates #45

Merged
merged 12 commits into from
Jan 10, 2025
6 changes: 2 additions & 4 deletions .cz.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
"tag_format": "v$version",
"update_changelog_on_bump": true,
"changelog_incremental": true,
"version_files": [
"package.json"
]
"version_provider": "npm"
}
}
}
16 changes: 8 additions & 8 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,22 @@ on:

jobs:
build-dist:
if: github.event.pull_request.merged == true
name: Build dist package
runs-on: ubuntu-latest
name: "Build dist"
if: github.event.pull_request.merged == true
steps:
- name: Check out
uses: actions/checkout@v3
- name: Checkout source code
uses: actions/checkout@v4
- name: Install node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '16'
node-version: 20
- name: Install packages
run: npm install
- name: Build
run: npm run build
- name: Commit changes
uses: EndBug/add-and-commit@v9
with:
add: 'dist'
message: 'chore: build dist package'
add: dist
message: "chore: build dist package"
16 changes: 8 additions & 8 deletions .github/workflows/bump.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,28 +7,28 @@ on:

jobs:
build-then-bump:
if: "!startsWith(github.event.head_commit.message, 'bump:')"
name: Build dist package, bump version, create changelog
runs-on: ubuntu-latest
name: "Build dist, bump version, create changelog"
if: "!startsWith(github.event.head_commit.message, 'bump:')"
steps:
- name: Check out
uses: actions/checkout@v3
- name: Checkout source code
uses: actions/checkout@v4
with:
token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
fetch-depth: 0
- name: Install node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '16'
node-version: 20
- name: Install packages
run: npm install
- name: Build
run: npm run build
- name: Commit changes
uses: EndBug/add-and-commit@v9
with:
add: 'dist'
message: 'chore: build dist package'
add: dist
message: "chore: build dist package"
push: false
- name: Create bump and changelog
uses: commitizen-tools/commitizen-action@master
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ on:

jobs:
build-pages:
if: "startsWith(github.event.head_commit.message, 'bump:')"
name: Rebuild and deploy docs on version bump
runs-on: ubuntu-latest
name: "Rebuild and deploy docs on version bump"
if: "startsWith(github.event.head_commit.message, 'bump:')"
steps:
- name: Check out
uses: actions/checkout@v3
- name: Checkout source code
uses: actions/checkout@v4
- name: Install node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '16'
node-version: 20
- name: Install packages
run: npm install
- name: Build
Expand Down
14 changes: 8 additions & 6 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,24 @@ name: Upload NPM Package

on:
release:
types: [published]
types:
- published

jobs:
deploy:
name: Publish to NPM
runs-on: ubuntu-latest
steps:
- name: Check out
uses: actions/checkout@v3
- name: Checkout source code
uses: actions/checkout@v4
with:
token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
fetch-depth: 0
- name: Install node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '16'
registry-url: 'https://registry.npmjs.org'
node-version: 20
registry-url: "https://registry.npmjs.org"
- name: Publish package
run: npm publish
env:
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/pull-requests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Validate pull requests

on:
pull_request:
types: [opened, edited, reopened, synchronize]

jobs:
validate-commits:
name: Validate commit messages
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v4
- name: Check commit message format
uses: webiny/[email protected]
with:
allowed-commit-types: 'feat,fix,refactor,perf,docs,style,test,build,ci,chore,new,patch,revert,ui,merge'
pre-commit:
name: Run pre-commit checks
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
- name: Run pre-commit
uses: pre-commit/[email protected]
6 changes: 3 additions & 3 deletions .github/workflows/sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ on:

jobs:
sync-branches:
name: Sync dev and patch branches to latest commit
runs-on: ubuntu-latest
name: "Sync dev and patch branches to latest commit"
steps:
- name: Check out
uses: actions/checkout@v3
- name: Checkout source code
uses: actions/checkout@v4
with:
token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
fetch-depth: 0
Expand Down
10 changes: 5 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
exclude: (vendor|dist)/
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
rev: v5.0.0
hooks:
- id: check-merge-conflict
- id: detect-private-key
- id: end-of-file-fixer
- id: name-tests-test
args: ["--pytest-test-first"]
args: [ '--pytest-test-first' ]
exclude: ^tests/helpers/
- id: trailing-whitespace
- repo: https://github.com/commitizen-tools/commitizen
rev: v2.37.0
rev: v4.1.0
hooks:
- id: commitizen
additional_dependencies: ["cz-nhm"]
additional_dependencies: [ 'cz-nhm' ]
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v3.0.0-alpha.4
rev: v4.0.0-alpha.8
hooks:
- id: prettier
types_or: [ javascript, vue, less, sass, scss, css ]
Expand Down
Loading
Loading