mirror of
https://github.com/Drop-OSS/drop
synced 2026-08-27 14:23:05 -04:00
chore: replace release.config.js with .releaserc.json for semantic release configuration
This commit is contained in:
parent
2a34adc35f
commit
c177e97857
4 changed files with 153 additions and 52 deletions
|
|
@ -5,6 +5,7 @@ on:
|
||||||
branches: [ main, next ]
|
branches: [ main, next ]
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [ main, next ]
|
branches: [ main, next ]
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build_test_common_os:
|
build_test_common_os:
|
||||||
|
|
@ -24,7 +25,7 @@ jobs:
|
||||||
- uses: extractions/setup-just@v3
|
- uses: extractions/setup-just@v3
|
||||||
- uses: hustcer/setup-nu@v3.19
|
- uses: hustcer/setup-nu@v3.19
|
||||||
with:
|
with:
|
||||||
version: '0.85'
|
version: '0.105.1'
|
||||||
- name: Just version
|
- name: Just version
|
||||||
run: just --version
|
run: just --version
|
||||||
- name: Build
|
- name: Build
|
||||||
|
|
@ -35,7 +36,7 @@ jobs:
|
||||||
name: Release
|
name: Release
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: [build_test_common_os]
|
needs: [build_test_common_os]
|
||||||
if: github.ref == 'refs/heads/main'
|
if: github.ref == 'refs/heads/main' && github.event_name == 'workflow_dispatch'
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
packages: write
|
packages: write
|
||||||
|
|
@ -44,19 +45,21 @@ jobs:
|
||||||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
||||||
with:
|
with:
|
||||||
ref: main
|
ref: main
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
- name: install npm
|
- name: install npm
|
||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version: '16'
|
node-version: '20'
|
||||||
|
|
||||||
- name: install @semantic-release/exec
|
|
||||||
run: npm install @semantic-release/exec
|
|
||||||
|
|
||||||
- name: Semantic Release
|
- name: Semantic Release
|
||||||
uses: cycjimmy/semantic-release-action@v3
|
uses: cycjimmy/semantic-release-action@v4
|
||||||
with:
|
with:
|
||||||
branch: main
|
extra_plugins: |
|
||||||
|
@semantic-release/commit-analyzer
|
||||||
|
@semantic-release/release-notes-generator
|
||||||
|
@semantic-release/exec
|
||||||
|
@semantic-release/github
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.PAT_GLOBAL }}
|
GITHUB_TOKEN: ${{ secrets.PAT_GLOBAL }}
|
||||||
CARGO_TOKEN: ${{ secrets.CARGO_TOKEN }}
|
CARGO_TOKEN: ${{ secrets.CARGO_TOKEN }}
|
||||||
112
libraries/native_model/.releaserc
Normal file
112
libraries/native_model/.releaserc
Normal file
|
|
@ -0,0 +1,112 @@
|
||||||
|
{
|
||||||
|
"branches": [
|
||||||
|
"main"
|
||||||
|
],
|
||||||
|
"tagFormat": "${version}",
|
||||||
|
"plugins": [
|
||||||
|
[
|
||||||
|
"@semantic-release/commit-analyzer",
|
||||||
|
{
|
||||||
|
"releaseRules": [
|
||||||
|
{
|
||||||
|
"breaking": true,
|
||||||
|
"release": "minor"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"revert": true,
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "feat",
|
||||||
|
"release": "minor"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "fix",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "perf",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "docs",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"emoji": ":racehorse:",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"emoji": ":bug:",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"emoji": ":penguin:",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"emoji": ":apple:",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"emoji": ":checkered_flag:",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tag": "BUGFIX",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tag": "FEATURE",
|
||||||
|
"release": "minor"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tag": "SECURITY",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tag": "Breaking",
|
||||||
|
"release": "minor"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tag": "Fix",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tag": "Update",
|
||||||
|
"release": "minor"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tag": "New",
|
||||||
|
"release": "minor"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"component": "perf",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"component": "deps",
|
||||||
|
"release": "patch"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "FEAT",
|
||||||
|
"release": "minor"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "FIX",
|
||||||
|
"release": "patch"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"@semantic-release/release-notes-generator",
|
||||||
|
[
|
||||||
|
"@semantic-release/exec",
|
||||||
|
{
|
||||||
|
"prepareCmd": "bash version_update.sh ${nextRelease.version}",
|
||||||
|
"publishCmd": "bash cargo_publish.sh"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"@semantic-release/github"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -1,38 +0,0 @@
|
||||||
module.exports = {
|
|
||||||
branches: ['main'],
|
|
||||||
tagFormat: '${version}',
|
|
||||||
plugins: [
|
|
||||||
['@semantic-release/commit-analyzer', {
|
|
||||||
releaseRules: [
|
|
||||||
{breaking: true, release: 'minor'},
|
|
||||||
{revert: true, release: 'patch'},
|
|
||||||
{type: 'feat', release: 'minor'},
|
|
||||||
{type: 'fix', release: 'patch'},
|
|
||||||
{type: 'perf', release: 'patch'},
|
|
||||||
{type: 'docs', release: 'patch'},
|
|
||||||
{emoji: ':racehorse:', release: 'patch'},
|
|
||||||
{emoji: ':bug:', release: 'patch'},
|
|
||||||
{emoji: ':penguin:', release: 'patch'},
|
|
||||||
{emoji: ':apple:', release: 'patch'},
|
|
||||||
{emoji: ':checkered_flag:', release: 'patch'},
|
|
||||||
{tag: 'BUGFIX', release: 'patch'},
|
|
||||||
{tag: 'FEATURE', release: 'minor'},
|
|
||||||
{tag: 'SECURITY', release: 'patch'},
|
|
||||||
{tag: 'Breaking', release: 'minor'},
|
|
||||||
{tag: 'Fix', release: 'patch'},
|
|
||||||
{tag: 'Update', release: 'minor'},
|
|
||||||
{tag: 'New', release: 'minor'},
|
|
||||||
{component: 'perf', release: 'patch'},
|
|
||||||
{component: 'deps', release: 'patch'},
|
|
||||||
{type: 'FEAT', release: 'minor'},
|
|
||||||
{type: 'FIX', release: 'patch'},
|
|
||||||
],
|
|
||||||
}],
|
|
||||||
'@semantic-release/release-notes-generator',
|
|
||||||
['@semantic-release/exec', {
|
|
||||||
"prepareCmd": "bash version_update.sh ${nextRelease.version}",
|
|
||||||
"publishCmd": "bash cargo_publish.sh",
|
|
||||||
}],
|
|
||||||
'@semantic-release/github',
|
|
||||||
],
|
|
||||||
};
|
|
||||||
|
|
@ -1,6 +1,8 @@
|
||||||
{
|
{
|
||||||
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
|
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
|
||||||
"extends": ["config:base"],
|
"extends": [
|
||||||
|
"config:base"
|
||||||
|
],
|
||||||
"semanticCommits": "enabled",
|
"semanticCommits": "enabled",
|
||||||
"semanticCommitType": "chore",
|
"semanticCommitType": "chore",
|
||||||
"semanticCommitScope": "deps",
|
"semanticCommitScope": "deps",
|
||||||
|
|
@ -8,14 +10,36 @@
|
||||||
"packageRules": [
|
"packageRules": [
|
||||||
{
|
{
|
||||||
"description": "Automerge non-major updates",
|
"description": "Automerge non-major updates",
|
||||||
"matchUpdateTypes": ["minor", "patch"],
|
"matchUpdateTypes": [
|
||||||
|
"minor",
|
||||||
|
"patch"
|
||||||
|
],
|
||||||
"automerge": true
|
"automerge": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "Automerge actions",
|
"description": "Automerge actions",
|
||||||
"matchDepTypes": ["action"],
|
"matchDepTypes": [
|
||||||
"matchUpdateTypes": ["major", "minor", "patch"],
|
"action"
|
||||||
"automerge": true
|
],
|
||||||
|
"matchUpdateTypes": [
|
||||||
|
"major",
|
||||||
|
"minor",
|
||||||
|
"patch"
|
||||||
|
],
|
||||||
|
"automerge": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"regexManagers": [
|
||||||
|
{
|
||||||
|
"fileMatch": [
|
||||||
|
"^\\.github/workflows/[^/]+\\.ya?ml$"
|
||||||
|
],
|
||||||
|
"matchStrings": [
|
||||||
|
"uses: hustcer/setup-nu@.*?\\n.*?version: '\\s*(?<currentValue>.*?)'"
|
||||||
|
],
|
||||||
|
"depNameTemplate": "nushell",
|
||||||
|
"datasourceTemplate": "github-releases",
|
||||||
|
"packageNameTemplate": "nushell/nushell"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue