Skip to content

Commit

Permalink
chore: release 4.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
RaunoT authored Aug 19, 2024
2 parents 700cd93 + e6d2eae commit 6d3e034
Show file tree
Hide file tree
Showing 23 changed files with 401 additions and 40 deletions.
38 changes: 38 additions & 0 deletions .cz-config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
module.exports = {
types: [
{ value: 'feat', name: 'feat: A new feature' },
{ value: 'fix', name: 'fix: A bug fix' },
{ value: 'ui', name: 'ui: Changes related to the UI' },
{
value: 'perf',
name: 'perf: A code change that improves performance',
},
{ value: 'docs', name: 'docs: Documentation only changes' },
{ value: 'revert', name: 'revert: Revert a previous commit' },
{
value: 'chore',
name: 'chore: Changes to auxiliary tools such as libraries and dependencies',
},
{
value: 'refactor',
name: 'refactor: A code change that neither fixes a bug nor adds a feature',
},
{
value: 'build',
name: 'build: Changes that affect the build system or external dependencies\n (example scopes: docker, pnpm)',
},
{
value: 'ci',
name: 'ci: Changes to our CI configuration files and scripts\n (example scope: gh-actions)',
},
{
value: 'style',
name: 'style: Changes that do not affect the meaning of the code\n (white-space, formatting, missing semi-colons, etc)',
},
{
value: 'test',
name: 'test: Adding missing tests or correcting existing tests',
},
],
scopes: [{ name: 'rewind' }, { name: 'dashboard' }, { name: 'config' }],
}
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/public
10 changes: 8 additions & 2 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,14 @@
"rules": {
"@stylistic/js/padding-line-between-statements": [
"error",
{ "blankLine": "always", "prev": "const", "next": "*" },
{ "blankLine": "any", "prev": "const", "next": "const" },
{ "blankLine": "always", "prev": "return", "next": "*" },
{ "blankLine": "always", "prev": "*", "next": "return" },
{ "blankLine": "always", "prev": ["const", "let", "var"], "next": "*" },
{
"blankLine": "any",
"prev": ["const", "let", "var"],
"next": ["const", "let", "var"]
},
{ "blankLine": "always", "prev": "*", "next": "if" },
{ "blankLine": "always", "prev": "if", "next": "*" }
]
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ jobs:
with:
fetch-depth: 0

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

Expand All @@ -33,3 +36,5 @@ jobs:
ghcr.io/raunot/plex-rewind:${{ github.sha }}
build-args: |
NEXT_PUBLIC_VERSION_TAG=${{ github.sha }}
cache-from: type=gha
cache-to: type=gha,mode=max
16 changes: 11 additions & 5 deletions .github/workflows/pre-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,17 @@ jobs:
with:
fetch-depth: 0

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

- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: 9

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'

- name: Install dependencies
run: pnpm install

Expand All @@ -33,6 +34,9 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: npx semantic-release --dry-run

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

Expand All @@ -55,6 +59,8 @@ jobs:
ghcr.io/raunot/plex-rewind:${{ env.NEXT_VERSION_TAG }}
build-args: |
NEXT_PUBLIC_VERSION_TAG=${{ env.NEXT_VERSION_TAG }}
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Run Semantic Release publish
env:
Expand Down
16 changes: 11 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,17 @@ jobs:
fetch-depth: 0
persist-credentials: false

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

- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: 9

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'

- name: Install dependencies
run: pnpm install

Expand All @@ -34,6 +35,9 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
run: npx semantic-release --dry-run

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

Expand All @@ -56,6 +60,8 @@ jobs:
ghcr.io/raunot/plex-rewind:${{ env.NEXT_VERSION_TAG }}
build-args: |
NEXT_PUBLIC_VERSION_TAG=${{ env.NEXT_VERSION_TAG }}
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Run Semantic Release publish
env:
Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,17 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

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

- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: 9

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'

- name: Install dependencies
run: pnpm install

Expand Down
2 changes: 1 addition & 1 deletion .lintstagedrc.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"**/*.{js,jsx,ts,tsx}": [
"prettier --write",
"prettier --write --cache",
"eslint --cache --fix",
"bash -c tsc --noEmit --skipLibCheck"
],
Expand Down
52 changes: 50 additions & 2 deletions .releaserc.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,55 @@
{
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
[
"@semantic-release/commit-analyzer",
{
"preset": "conventionalcommits",
"releaseRules": [
{ "type": "feat", "release": "minor" },
{ "type": "fix", "release": "patch" },
{ "type": "ui", "release": "patch" },
{ "type": "perf", "release": "patch" },
{ "type": "docs", "release": false },
{ "type": "revert", "release": "patch" },
{ "type": "chore", "release": "patch" },
{ "type": "refactor", "release": "patch" },
{ "type": "build", "release": "patch" },
{ "type": "ci", "release": "patch" },
{ "type": "style", "release": false },
{ "type": "test", "release": false }
]
}
],
[
"@semantic-release/release-notes-generator",
{
"preset": "conventionalcommits",
"presetConfig": {
"types": [
{ "type": "feat", "section": "🚀 Features", "hidden": false },
{ "type": "fix", "section": "🐛 Bug Fixes", "hidden": false },
{ "type": "ui", "section": "🎨 UI Changes", "hidden": false },
{
"type": "perf",
"section": "⚡ Performance Improvements",
"hidden": false
},
{ "type": "docs", "section": "📝 Documentation", "hidden": false },
{ "type": "revert", "section": "⏪ Reverts", "hidden": false },
{ "type": "chore", "section": "🛠️ Other Changes", "hidden": false },
{
"type": "refactor",
"section": "🛠️ Other Changes",
"hidden": false
},
{ "type": "build", "section": "🛠️ Other Changes", "hidden": false },
{ "type": "ci", "section": "🛠️ Other Changes", "hidden": false },
{ "type": "style", "section": "🛠️ Other Changes", "hidden": true },
{ "type": "test", "section": "🛠️ Other Changes", "hidden": true }
]
}
}
],
"@semantic-release/github",
[
"@semantic-release/exec",
Expand Down
24 changes: 23 additions & 1 deletion commitlint.config.js
Original file line number Diff line number Diff line change
@@ -1 +1,23 @@
module.exports = { extends: ['@commitlint/config-conventional'] }
module.exports = {
extends: ['@commitlint/config-conventional'],
rules: {
'type-enum': [
2,
'always',
[
'feat',
'fix',
'ui',
'perf',
'docs',
'revert',
'chore',
'refactor',
'build',
'ci',
'style',
'test',
],
],
},
}
14 changes: 5 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,19 @@
"dev": "next dev",
"start": "next start",
"build": "next build",
"lint": "next lint",
"lint": "eslint --cache .",
"lint:types": "tsc --noEmit",
"lint:css": "stylelint --cache \"**/*.css\"",
"lint:all": "pnpm lint && pnpm lint:types && pnpm lint:css && pnpm format:check",
"lint:all:fix": "next lint --fix && pnpm lint:types && stylelint --cache --fix \"**/*.css\" && pnpm format",
"lint:all:fix": "eslint --cache --fix . && pnpm lint:types && stylelint --cache --fix \"**/*.css\" && pnpm format",
"format": "prettier --write --cache .",
"format:check": "prettier --check --cache .",
"prepare": "husky",
"commit": "git-cz"
},
"config": {
"commitizen": {
"path": "./node_modules/cz-conventional-changelog"
"path": "./node_modules/cz-customizable"
}
},
"dependencies": {
Expand Down Expand Up @@ -57,7 +57,8 @@
"autoprefixer": "^10.4.20",
"clsx": "^2.1.1",
"commitizen": "^4.3.0",
"cz-conventional-changelog": "^3.3.0",
"conventional-changelog-conventionalcommits": "^8.0.0",
"cz-customizable": "7.2.1",
"eslint": "^8.57.0",
"eslint-config-next": "^14.2.5",
"eslint-config-prettier": "^9.1.0",
Expand All @@ -73,10 +74,5 @@
"stylelint-config-standard": "^36.0.1",
"tailwindcss": "^3.4.9",
"typescript": "^5.5.4"
},
"pnpm": {
"overrides": {
"conventional-changelog-conventionalcommits": ">= 8.0.0"
}
}
}
Loading

0 comments on commit 6d3e034

Please sign in to comment.