mirror of
https://github.com/ReVanced/revanced-bots.git
synced 2026-01-10 13:26:16 +00:00
73 lines
1.8 KiB
JavaScript
73 lines
1.8 KiB
JavaScript
// @ts-check
|
|
|
|
/**
|
|
* @type {import('semantic-release').Options}
|
|
*/
|
|
const Options = {
|
|
branches: [
|
|
'main',
|
|
{
|
|
name: 'dev',
|
|
prerelease: true,
|
|
},
|
|
],
|
|
plugins: [
|
|
[
|
|
'@semantic-release/commit-analyzer',
|
|
{
|
|
releaseRules: [{ type: 'build', scope: 'Needs bump', release: 'patch' }],
|
|
},
|
|
],
|
|
'@semantic-release/release-notes-generator',
|
|
'@semantic-release/changelog',
|
|
[
|
|
'@semantic-release/npm',
|
|
{
|
|
npmPublish: false,
|
|
},
|
|
],
|
|
[
|
|
'@semantic-release/git',
|
|
{
|
|
assets: ['CHANGELOG.md', 'package.json', '../../bun.lockb'],
|
|
},
|
|
],
|
|
[
|
|
'@semantic-release/github',
|
|
{
|
|
assets: [
|
|
{
|
|
path: 'dist/*',
|
|
},
|
|
],
|
|
successComment: false,
|
|
},
|
|
],
|
|
// This unfortunately has to run multiple times, even though it needs to run only once.
|
|
[
|
|
'@saithodev/semantic-release-backmerge',
|
|
{
|
|
backmergeBranches: [
|
|
{
|
|
from: 'main',
|
|
to: 'dev',
|
|
},
|
|
],
|
|
clearWorkspace: true,
|
|
},
|
|
],
|
|
],
|
|
}
|
|
|
|
/**
|
|
* @param {import('semantic-release').Options} subprojectOptions
|
|
* @returns {import('semantic-release').Options}
|
|
*/
|
|
export default function defineSubprojectReleaseConfig(subprojectOptions) {
|
|
return {
|
|
...Options,
|
|
...subprojectOptions,
|
|
plugins: [...(Options.plugins || []), ...(subprojectOptions.plugins || [])],
|
|
}
|
|
}
|