-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathrelease.config.js
More file actions
75 lines (70 loc) · 2.48 KB
/
release.config.js
File metadata and controls
75 lines (70 loc) · 2.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
/**
* Semantic Release Configuration
*
* Conservative versioning for 0.x development:
* - fix: → patch (0.1.2 → 0.1.3)
* - feat: → patch (0.1.2 → 0.1.3) - conservative until 1.0
* - feat!: or BREAKING CHANGE: → minor (0.1.x → 0.2.0) - not major while 0.x
* - perf:, refactor: → patch
* - docs:, chore:, test:, ci: → no release
*/
export default {
branches: ['master'],
repositoryUrl: 'https://github.com/framersai/agentos',
tagFormat: 'v${version}',
plugins: [
// Analyze commits to determine release type
['@semantic-release/commit-analyzer', {
preset: 'conventionalcommits',
releaseRules: [
{ type: 'feat', release: 'patch' }, // Conservative: feat = patch until 1.0
{ type: 'fix', release: 'patch' },
{ type: 'perf', release: 'patch' },
{ type: 'refactor', release: 'patch' },
{ type: 'revert', release: 'patch' },
{ breaking: true, release: 'minor' }, // BREAKING = minor while 0.x
// These don't trigger releases: docs, style, chore, test, ci, build
],
parserOpts: {
noteKeywords: ['BREAKING CHANGE', 'BREAKING CHANGES', 'BREAKING']
}
}],
// Generate release notes from commits
['@semantic-release/release-notes-generator', {
preset: 'conventionalcommits',
presetConfig: {
types: [
{ type: 'feat', section: 'Features' },
{ type: 'fix', section: 'Bug Fixes' },
{ type: 'perf', section: 'Performance' },
{ type: 'refactor', section: 'Code Refactoring' },
{ type: 'revert', section: 'Reverts' },
{ type: 'docs', section: 'Documentation', hidden: true },
{ type: 'chore', section: 'Maintenance', hidden: true },
{ type: 'test', section: 'Tests', hidden: true },
{ type: 'ci', section: 'CI/CD', hidden: true },
{ type: 'build', section: 'Build', hidden: true },
]
}
}],
// Update CHANGELOG.md
['@semantic-release/changelog', {
changelogFile: 'CHANGELOG.md'
}],
// Publish to npm
['@semantic-release/npm', {
npmPublish: true
}],
// Commit version bump and changelog
['@semantic-release/git', {
assets: ['CHANGELOG.md', 'package.json'],
message: 'chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}'
}],
// Create GitHub release
['@semantic-release/github', {
successComment: false,
failComment: false,
releasedLabels: false
}]
]
};