@versu/core 0.10.0 → 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +133 -110
- package/dist/changelog/index.d.ts +6 -8
- package/dist/changelog/index.d.ts.map +1 -1
- package/dist/changelog/index.js +52 -39
- package/dist/changelog/index.js.map +1 -1
- package/dist/config/templates/footer.d.ts +1 -1
- package/dist/config/templates/footer.d.ts.map +1 -1
- package/dist/config/templates/footer.js +1 -2
- package/dist/config/templates/footer.js.map +1 -1
- package/dist/config/templates/main-module.d.ts +1 -1
- package/dist/config/templates/main-module.d.ts.map +1 -1
- package/dist/config/templates/main-module.js +4 -2
- package/dist/config/templates/main-module.js.map +1 -1
- package/dist/config/templates/main-release-module.d.ts +1 -1
- package/dist/config/templates/main-release-module.d.ts.map +1 -1
- package/dist/config/templates/main-release-module.js +8 -14
- package/dist/config/templates/main-release-module.js.map +1 -1
- package/dist/config/templates/main-release-root.d.ts +1 -1
- package/dist/config/templates/main-release-root.d.ts.map +1 -1
- package/dist/config/templates/main-release-root.js +16 -7
- package/dist/config/templates/main-release-root.js.map +1 -1
- package/dist/config/templates/main-root.d.ts +1 -1
- package/dist/config/templates/main-root.d.ts.map +1 -1
- package/dist/config/templates/main-root.js +3 -1
- package/dist/config/templates/main-root.js.map +1 -1
- package/dist/config/types.d.ts +8 -8
- package/dist/config/types.d.ts.map +1 -1
- package/dist/git/index.d.ts +38 -3
- package/dist/git/index.d.ts.map +1 -1
- package/dist/git/index.js +61 -11
- package/dist/git/index.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/services/changes-renderer.d.ts +21 -0
- package/dist/services/changes-renderer.d.ts.map +1 -0
- package/dist/services/changes-renderer.js +37 -0
- package/dist/services/changes-renderer.js.map +1 -0
- package/dist/services/commit-analyzer.d.ts +3 -1
- package/dist/services/commit-analyzer.d.ts.map +1 -1
- package/dist/services/commit-analyzer.js +5 -3
- package/dist/services/commit-analyzer.js.map +1 -1
- package/dist/services/versu-runner.d.ts +2 -0
- package/dist/services/versu-runner.d.ts.map +1 -1
- package/dist/services/versu-runner.js +14 -8
- package/dist/services/versu-runner.js.map +1 -1
- package/dist/utils/version.d.ts +1 -1
- package/dist/utils/version.js +1 -1
- package/package.json +2 -1
- package/dist/services/changelog-generator.d.ts +0 -21
- package/dist/services/changelog-generator.d.ts.map +0 -1
- package/dist/services/changelog-generator.js +0 -37
- package/dist/services/changelog-generator.js.map +0 -1
package/README.md
CHANGED
|
@@ -8,6 +8,8 @@
|
|
|
8
8
|
|
|
9
9
|
The core business logic powering Versu. This package is completely framework-agnostic and can be integrated into any TypeScript/JavaScript project, CI/CD system, or custom tooling.
|
|
10
10
|
|
|
11
|
+
For comprehensive documentation, examples, and configuration options, please refer to the our website <https://versuhq.github.io/>.
|
|
12
|
+
|
|
11
13
|
## Installation
|
|
12
14
|
|
|
13
15
|
```bash
|
|
@@ -17,16 +19,14 @@ npm install @versu/core
|
|
|
17
19
|
## Quick Start
|
|
18
20
|
|
|
19
21
|
```typescript
|
|
20
|
-
import { VersuRunner } from
|
|
22
|
+
import { VersuRunner, type RunnerOptions } from "@versu/core";
|
|
23
|
+
|
|
24
|
+
const options: RunnerOptions = {
|
|
25
|
+
repoRoot: "/path/to/repository",
|
|
26
|
+
// ...other options as needed
|
|
27
|
+
};
|
|
21
28
|
|
|
22
|
-
const runner = new VersuRunner(
|
|
23
|
-
repoRoot: '/path/to/repository',
|
|
24
|
-
adapter: 'gradle', // Optional - auto-detected if not specified
|
|
25
|
-
dryRun: false,
|
|
26
|
-
pushTags: true,
|
|
27
|
-
pushChanges: true,
|
|
28
|
-
generateChangelog: true
|
|
29
|
-
});
|
|
29
|
+
const runner = new VersuRunner(options);
|
|
30
30
|
|
|
31
31
|
const result = await runner.run();
|
|
32
32
|
|
|
@@ -35,173 +35,191 @@ console.log(`Changed modules:`, result.changedModules);
|
|
|
35
35
|
console.log(`Created tags:`, result.createdTags);
|
|
36
36
|
```
|
|
37
37
|
|
|
38
|
-
For detailed pre-release configuration and examples, see [PRERELEASE.md](./PRERELEASE.md).
|
|
39
|
-
|
|
40
38
|
## VersuRunner API
|
|
41
39
|
|
|
42
40
|
### Options
|
|
43
41
|
|
|
44
42
|
```typescript
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
pushChanges
|
|
57
|
-
|
|
58
|
-
|
|
43
|
+
type RunnerOptions = {
|
|
44
|
+
// Required
|
|
45
|
+
repoRoot: string; // Absolute path to repository root
|
|
46
|
+
prereleaseMode: boolean; // Generate pre-release versions
|
|
47
|
+
prereleaseId: string; // Pre-release identifier, e.g. 'alpha', 'beta', 'rc'
|
|
48
|
+
bumpUnchanged: boolean; // Bump modules with no changes (prerelease mode only)
|
|
49
|
+
addBuildMetadata: boolean; // Append short SHA as build metadata (+sha)
|
|
50
|
+
timestampVersions: boolean; // Use timestamp-based pre-release identifiers
|
|
51
|
+
appendSnapshot: boolean; // Append -SNAPSHOT suffix (Gradle only)
|
|
52
|
+
createTags: boolean; // Create git tags for bumped modules
|
|
53
|
+
generateChangelog: boolean; // Generate CHANGELOG.md files
|
|
54
|
+
pushChanges: boolean; // Commit and push version changes to remote
|
|
55
|
+
dryRun: boolean; // Preview changes without writing anything
|
|
56
|
+
|
|
57
|
+
// Optional
|
|
58
|
+
adapter?: string; // Language adapter ID (auto-detected if omitted)
|
|
59
|
+
changelogFilename?: string; // Changelog filename (default: 'CHANGELOG.md')
|
|
60
|
+
releaseNotesFilename?: string; // Release notes filename (default: 'RELEASE.md')
|
|
61
|
+
fromRef?: string; // Git ref to use as the lower boundary for commit analysis
|
|
62
|
+
provider?: string; // Version control provider name (auto-detected if omitted)
|
|
63
|
+
};
|
|
59
64
|
```
|
|
60
65
|
|
|
61
66
|
### Result
|
|
62
67
|
|
|
63
68
|
```typescript
|
|
64
|
-
|
|
65
|
-
bumped: boolean;
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
changelogPaths: string[]; // Generated changelog file paths
|
|
73
|
-
}
|
|
69
|
+
type RunnerResult = {
|
|
70
|
+
bumped: boolean; // Whether any version was updated
|
|
71
|
+
discoveredModules: Array<Module>; // All modules found in the repository
|
|
72
|
+
changedModules: Array<ModuleChangeResult>; // Modules whose version changed
|
|
73
|
+
createdTags: string[]; // Git tags that were created
|
|
74
|
+
changelogPaths: string[]; // Generated changelog file paths
|
|
75
|
+
releaseNotesPaths: string[]; // Generated release notes file paths
|
|
76
|
+
};
|
|
74
77
|
```
|
|
75
78
|
|
|
76
79
|
## Configuration
|
|
77
80
|
|
|
78
81
|
Versu core uses [cosmiconfig](https://github.com/davidtheclark/cosmiconfig) for configuration loading and [Zod](https://github.com/colinhacks/zod) for validation.
|
|
79
82
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
1. `package.json` (in a `"versu"` property)
|
|
83
|
-
2. `.versurc.json`
|
|
84
|
-
3. `.versurc.yaml` / `.versurc.yml`
|
|
85
|
-
4. `.versurc.js` or `versu.config.js` (JavaScript)
|
|
83
|
+
You can provide configuration in any of the supported config files (e.g., `.versurc`, `versu.config.js`, etc.) or via `package.json` under the `versu` key. For the full list please refer to [cosmiconfig search places documentation](https://github.com/cosmiconfig/cosmiconfig?tab=readme-ov-file#searchplaces).
|
|
86
84
|
|
|
87
85
|
### Configuration Example
|
|
88
86
|
|
|
89
87
|
```json
|
|
90
88
|
{
|
|
91
|
-
"
|
|
92
|
-
"
|
|
93
|
-
|
|
94
|
-
"
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
"
|
|
89
|
+
"versioning": {
|
|
90
|
+
"breakingChange": {
|
|
91
|
+
"stable": "major",
|
|
92
|
+
"prerelease": "premajor"
|
|
93
|
+
},
|
|
94
|
+
"unknownCommitType": {
|
|
95
|
+
"stable": "patch",
|
|
96
|
+
"prerelease": "prepatch"
|
|
98
97
|
},
|
|
99
|
-
"
|
|
100
|
-
"
|
|
101
|
-
|
|
102
|
-
|
|
98
|
+
"commitTypes": {
|
|
99
|
+
"feat": {
|
|
100
|
+
"stable": "minor",
|
|
101
|
+
"prerelease": "preminor"
|
|
102
|
+
},
|
|
103
|
+
"fix": {
|
|
104
|
+
"stable": "patch",
|
|
105
|
+
"prerelease": "prepatch"
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
"cascadeRules": {
|
|
109
|
+
"stable": {
|
|
110
|
+
"major": "major",
|
|
111
|
+
"minor": "minor",
|
|
112
|
+
"patch": "patch"
|
|
113
|
+
},
|
|
114
|
+
"prerelease": {
|
|
115
|
+
"major": "premajor",
|
|
116
|
+
"minor": "preminor",
|
|
117
|
+
"patch": "prepatch"
|
|
118
|
+
}
|
|
103
119
|
}
|
|
104
120
|
},
|
|
105
121
|
"changelog": {
|
|
106
122
|
"root": {
|
|
107
123
|
"context": {
|
|
108
|
-
"prependPlaceholder": "<!--
|
|
124
|
+
"prependPlaceholder": "<!-- Next Version Placeholder -->"
|
|
109
125
|
}
|
|
110
126
|
},
|
|
111
127
|
"module": {
|
|
112
128
|
"context": {
|
|
113
|
-
"prependPlaceholder": "<!--
|
|
129
|
+
"prependPlaceholder": "<!-- Next Version Placeholder -->"
|
|
114
130
|
}
|
|
115
131
|
}
|
|
116
132
|
}
|
|
117
133
|
}
|
|
118
134
|
```
|
|
119
135
|
|
|
120
|
-
**Changelog Configuration:**
|
|
136
|
+
**Changelog & Release Notes Configuration:**
|
|
121
137
|
|
|
122
138
|
- `changelog.root` - Configuration for root-level CHANGELOG.md generation
|
|
123
139
|
- `changelog.module` - Configuration for per-module CHANGELOG.md generation
|
|
124
|
-
- `context.prependPlaceholder` - Placeholder string in changelog files where new entries are inserted
|
|
125
|
-
- `options` - Advanced changelog generation options (templates, grouping, sorting)
|
|
140
|
+
- `changelog.context.prependPlaceholder` - Placeholder string in changelog files where new entries are inserted
|
|
141
|
+
- `changelog.context.options` - Advanced changelog generation options (templates, grouping, sorting)
|
|
126
142
|
|
|
127
|
-
|
|
143
|
+
Release notes follows the same pattern under `release` key.
|
|
128
144
|
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
### Gradle Adapter
|
|
132
|
-
|
|
133
|
-
Gradle support is provided by the **[@versu/plugin-gradle][plugin-gradle]** package.
|
|
134
|
-
|
|
135
|
-
**Features:**
|
|
136
|
-
|
|
137
|
-
- Multi-module project detection
|
|
138
|
-
- Version management through root `gradle.properties`
|
|
139
|
-
- Dependency detection
|
|
140
|
-
- Both Groovy and Kotlin DSL support
|
|
141
|
-
|
|
142
|
-
**Version Format:**
|
|
145
|
+
Versu uses [conventional-changelog-writer](https://github.com/conventional-changelog/conventional-changelog/tree/master/packages/conventional-changelog-writer) for changelog and release notes generation. You can pass any options supported by conventional-changelog-writer through the `options` field. For advanced customization with functions (like `transform`, `commitsGroupsSort`), use JavaScript configuration files (`.versurc.js` or `versu.config.js`).
|
|
143
146
|
|
|
144
|
-
|
|
145
|
-
# Root module
|
|
146
|
-
version=1.0.0
|
|
147
|
+
## Adapters
|
|
147
148
|
|
|
148
|
-
|
|
149
|
-
core.version=2.1.0
|
|
150
|
-
api.version=1.5.0
|
|
151
|
-
```
|
|
149
|
+
Versu supports multiple language ecosystems through adapters. The core package includes a plugin system for adding new adapter support. In order to support additional ecosystems, you need to implement the required interfaces and register them as plugins.
|
|
152
150
|
|
|
153
151
|
### Creating Custom Adapters
|
|
154
152
|
|
|
155
153
|
To add support for new project types, create a plugin package that implements the adapter interfaces:
|
|
156
154
|
|
|
157
155
|
```typescript
|
|
158
|
-
import {
|
|
156
|
+
import {
|
|
159
157
|
AdapterIdentifier,
|
|
158
|
+
type AdapterMetadata,
|
|
160
159
|
ModuleDetector,
|
|
160
|
+
type ProjectInformation,
|
|
161
161
|
VersionUpdateStrategy,
|
|
162
|
+
type ModuleRegistry,
|
|
162
163
|
ModuleSystemFactory,
|
|
163
|
-
|
|
164
|
-
RawProjectInformation,
|
|
165
|
-
ProcessedModuleChange
|
|
166
|
-
} from '@versu/core';
|
|
164
|
+
} from "@versu/core";
|
|
167
165
|
|
|
168
166
|
// 1. Adapter identifier for auto-detection
|
|
169
167
|
class MyAdapterIdentifier implements AdapterIdentifier {
|
|
170
168
|
readonly metadata: AdapterMetadata = {
|
|
171
|
-
id:
|
|
172
|
-
capabilities: { supportsSnapshots: false }
|
|
169
|
+
id: "my-adapter",
|
|
170
|
+
capabilities: { supportsSnapshots: false },
|
|
173
171
|
};
|
|
174
172
|
|
|
175
173
|
async accept(projectRoot: string): Promise<boolean> {
|
|
176
174
|
// Check for adapter-specific files
|
|
177
|
-
return await fileExists(path.join(projectRoot,
|
|
175
|
+
return await fileExists(path.join(projectRoot, "my-build-file"));
|
|
178
176
|
}
|
|
179
177
|
}
|
|
180
178
|
|
|
181
179
|
// 2. Module detector for discovering project structure
|
|
182
180
|
class MyModuleDetector implements ModuleDetector {
|
|
183
|
-
|
|
181
|
+
constructor(
|
|
182
|
+
readonly repoRoot: string,
|
|
183
|
+
readonly outputFile: string,
|
|
184
|
+
) {}
|
|
185
|
+
|
|
186
|
+
async detect(): Promise<ProjectInformation> {
|
|
184
187
|
// Discover and return modules and dependencies
|
|
185
188
|
return {
|
|
189
|
+
moduleIds: ["root", "module-a"],
|
|
186
190
|
modules: [
|
|
187
|
-
{
|
|
188
|
-
|
|
191
|
+
{
|
|
192
|
+
id: "root",
|
|
193
|
+
name: "root",
|
|
194
|
+
path: this.repoRoot,
|
|
195
|
+
type: "root",
|
|
196
|
+
affectedModules: new Set(["module-a"]),
|
|
197
|
+
version: "1.0.0",
|
|
198
|
+
declaredVersion: false,
|
|
199
|
+
},
|
|
200
|
+
{
|
|
201
|
+
id: "module-a",
|
|
202
|
+
name: "module-a",
|
|
203
|
+
path: join(this.repoRoot, "module-a"),
|
|
204
|
+
type: "module",
|
|
205
|
+
affectedModules: new Set([]),
|
|
206
|
+
version: "2.0.0",
|
|
207
|
+
declaredVersion: true,
|
|
208
|
+
},
|
|
189
209
|
],
|
|
190
|
-
dependencies: [
|
|
191
|
-
{ from: 'module-a', to: 'root' }
|
|
192
|
-
]
|
|
193
210
|
};
|
|
194
211
|
}
|
|
195
212
|
}
|
|
196
213
|
|
|
197
214
|
// 3. Version update strategy for applying changes
|
|
198
215
|
class MyVersionUpdateStrategy implements VersionUpdateStrategy {
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
216
|
+
constructor(private readonly moduleRegistry: ModuleRegistry) {}
|
|
217
|
+
|
|
218
|
+
async writeVersionUpdates(
|
|
219
|
+
moduleVersions: Map<string, string>,
|
|
202
220
|
): Promise<void> {
|
|
203
221
|
// Apply version changes to build files
|
|
204
|
-
for (const
|
|
222
|
+
for (const [moduleId, newVersion] of moduleVersions) {
|
|
205
223
|
// Update version in your project's format
|
|
206
224
|
}
|
|
207
225
|
}
|
|
@@ -209,12 +227,16 @@ class MyVersionUpdateStrategy implements VersionUpdateStrategy {
|
|
|
209
227
|
|
|
210
228
|
// 4. Module system factory to tie it all together
|
|
211
229
|
class MyModuleSystemFactory implements ModuleSystemFactory {
|
|
212
|
-
|
|
213
|
-
|
|
230
|
+
constructor(private readonly repoRoot: string) {}
|
|
231
|
+
|
|
232
|
+
createDetector(outputFile: string): ModuleDetector {
|
|
233
|
+
return new MyModuleDetector(this.repoRoot, outputFile);
|
|
214
234
|
}
|
|
215
|
-
|
|
216
|
-
createVersionUpdateStrategy(
|
|
217
|
-
|
|
235
|
+
|
|
236
|
+
createVersionUpdateStrategy(
|
|
237
|
+
moduleRegistry: ModuleRegistry,
|
|
238
|
+
): VersionUpdateStrategy {
|
|
239
|
+
return new MyVersionUpdateStrategy(moduleRegistry);
|
|
218
240
|
}
|
|
219
241
|
}
|
|
220
242
|
```
|
|
@@ -222,19 +244,20 @@ class MyModuleSystemFactory implements ModuleSystemFactory {
|
|
|
222
244
|
Then create a plugin:
|
|
223
245
|
|
|
224
246
|
```typescript
|
|
225
|
-
import type { PluginContract } from
|
|
247
|
+
import type { PluginContract } from "@versu/core";
|
|
226
248
|
|
|
227
249
|
const myPlugin: PluginContract = {
|
|
228
|
-
id:
|
|
229
|
-
name:
|
|
230
|
-
description:
|
|
231
|
-
version:
|
|
232
|
-
author:
|
|
250
|
+
id: "my-adapter",
|
|
251
|
+
name: "My Adapter",
|
|
252
|
+
description: "Support for my build system",
|
|
253
|
+
version: "1.0.0",
|
|
254
|
+
author: "Your Name",
|
|
233
255
|
adapters: [
|
|
234
256
|
{
|
|
235
|
-
id:
|
|
257
|
+
id: "my-adapter",
|
|
236
258
|
adapterIdentifier: () => new MyAdapterIdentifier(),
|
|
237
|
-
moduleSystemFactory: (repoRoot: string) =>
|
|
259
|
+
moduleSystemFactory: (repoRoot: string) =>
|
|
260
|
+
new MyModuleSystemFactory(repoRoot),
|
|
238
261
|
},
|
|
239
262
|
],
|
|
240
263
|
};
|
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
import { ModuleChangeResult } from "../services/version-applier.js";
|
|
2
2
|
import { Commit } from "conventional-commits-parser";
|
|
3
|
-
import {
|
|
4
|
-
/**
|
|
5
|
-
export declare function
|
|
6
|
-
/** Generate changelog for multiple modules. */
|
|
7
|
-
export declare function generateChangelogsForModules(moduleResults: ModuleChangeResult[], getCommitsForModule: (moduleId: string) => Promise<{
|
|
3
|
+
import { ModuleReleaseChangesConfig } from "../config/types.js";
|
|
4
|
+
/** Generate changes for multiple modules. */
|
|
5
|
+
export declare function renderChangesForModules(moduleResults: ModuleChangeResult[], getCommitsForModule: (moduleId: string) => Promise<{
|
|
8
6
|
commits: Commit[];
|
|
9
7
|
lastTag: string | null;
|
|
10
|
-
}>, repoRoot: string, dryRun: boolean, filename: string, config?:
|
|
11
|
-
export declare function
|
|
8
|
+
}>, repoRoot: string, dryRun: boolean, filename: string, multiModule: boolean, config?: ModuleReleaseChangesConfig, provider?: string): Promise<string[]>;
|
|
9
|
+
export declare function renderRootChanges(moduleResults: ModuleChangeResult[], getCommitsForModule: (moduleId: string) => Promise<{
|
|
12
10
|
commits: Commit[];
|
|
13
11
|
lastTag: string | null;
|
|
14
|
-
}>, repoRoot: string, dryRun: boolean, filename: string, config?:
|
|
12
|
+
}>, repoRoot: string, dryRun: boolean, filename: string, config?: ModuleReleaseChangesConfig, provider?: string): Promise<string | undefined>;
|
|
15
13
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/changelog/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAOpE,OAAO,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/changelog/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAOpE,OAAO,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AASrD,OAAO,EAAE,0BAA0B,EAAE,MAAM,oBAAoB,CAAC;AAgDhE,6CAA6C;AAC7C,wBAAsB,uBAAuB,CAC3C,aAAa,EAAE,kBAAkB,EAAE,EACnC,mBAAmB,EAAE,CACnB,QAAQ,EAAE,MAAM,KACb,OAAO,CAAC;IAAE,OAAO,EAAE,MAAM,EAAE,CAAC;IAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,CAAC,EAC3D,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,OAAO,EACf,QAAQ,EAAE,MAAM,EAChB,WAAW,EAAE,OAAO,EACpB,MAAM,CAAC,EAAE,0BAA0B,EACnC,QAAQ,CAAC,EAAE,MAAM,GAChB,OAAO,CAAC,MAAM,EAAE,CAAC,CAoFnB;AAED,wBAAsB,iBAAiB,CACrC,aAAa,EAAE,kBAAkB,EAAE,EACnC,mBAAmB,EAAE,CACnB,QAAQ,EAAE,MAAM,KACb,OAAO,CAAC;IAAE,OAAO,EAAE,MAAM,EAAE,CAAC;IAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,CAAC,EAC3D,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,OAAO,EACf,QAAQ,EAAE,MAAM,EAChB,MAAM,CAAC,EAAE,0BAA0B,EACnC,QAAQ,CAAC,EAAE,MAAM,GAChB,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CA4E7B"}
|
package/dist/changelog/index.js
CHANGED
|
@@ -3,19 +3,25 @@ import { join } from "path";
|
|
|
3
3
|
import { writeChangelogString, } from "conventional-changelog-writer";
|
|
4
4
|
import { logger } from "../utils/logger.js";
|
|
5
5
|
import { exists } from "../utils/file.js";
|
|
6
|
-
import { getCurrentRepoUrl, parseRepoUrl } from "../git/index.js";
|
|
6
|
+
import { getCurrentRepoUrl, getModuleTagName, parseRepoUrl, parseTagName, } from "../git/index.js";
|
|
7
7
|
import { isReleaseVersion } from "../semver/index.js";
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
8
|
+
import Handlebars from "handlebars";
|
|
9
|
+
Handlebars.registerHelper("eq", (a, b) => a === b);
|
|
10
|
+
Handlebars.registerHelper("ne", (a, b) => a !== b);
|
|
11
|
+
Handlebars.registerHelper("and", (a, b) => a && b);
|
|
12
|
+
Handlebars.registerHelper("or", (a, b) => a || b);
|
|
13
|
+
Handlebars.registerHelper("not", (a) => !a);
|
|
14
|
+
/** Update or create changes file for a module. */
|
|
15
|
+
async function updateRenderFile(content, filePath, prependPlaceholder) {
|
|
16
|
+
let fileContent = content;
|
|
17
|
+
if (await exists(filePath)) {
|
|
18
|
+
logger.info("Updating existing changes", { path: filePath });
|
|
19
|
+
// Try to read existing changes
|
|
20
|
+
const existingContent = await fs.readFile(filePath, "utf8");
|
|
21
|
+
const newContent = `${prependPlaceholder}\n\n${content.trimEnd()}`;
|
|
16
22
|
fileContent = existingContent.replace(prependPlaceholder, newContent);
|
|
17
23
|
}
|
|
18
|
-
await fs.writeFile(
|
|
24
|
+
await fs.writeFile(filePath, fileContent, "utf8");
|
|
19
25
|
}
|
|
20
26
|
async function buildContextRepository(options = {}) {
|
|
21
27
|
const repoUrl = await getCurrentRepoUrl(options);
|
|
@@ -27,32 +33,36 @@ async function buildContextRepository(options = {}) {
|
|
|
27
33
|
repository: repo,
|
|
28
34
|
};
|
|
29
35
|
}
|
|
30
|
-
/** Generate
|
|
31
|
-
export async function
|
|
32
|
-
const
|
|
36
|
+
/** Generate changes for multiple modules. */
|
|
37
|
+
export async function renderChangesForModules(moduleResults, getCommitsForModule, repoRoot, dryRun, filename, multiModule, config, provider) {
|
|
38
|
+
const renderedPaths = [];
|
|
33
39
|
if (!config) {
|
|
34
|
-
throw new Error(`Missing required
|
|
40
|
+
throw new Error(`Missing required changes rendering configuration`);
|
|
35
41
|
}
|
|
36
42
|
const prependPlaceholder = config?.context?.prependPlaceholder;
|
|
37
43
|
if (!prependPlaceholder) {
|
|
38
|
-
throw new Error("Missing required context property 'prependPlaceholder'");
|
|
44
|
+
throw new Error("Missing required changes rendering context property 'prependPlaceholder'");
|
|
39
45
|
}
|
|
40
46
|
const contextRepository = await buildContextRepository({ cwd: repoRoot });
|
|
41
47
|
for (const moduleResult of moduleResults) {
|
|
48
|
+
if (moduleResult.type === "root" && multiModule) {
|
|
49
|
+
logger.info("Skipping root module for individual changes generation since multi-module changes enabled", { moduleId: moduleResult.id });
|
|
50
|
+
continue;
|
|
51
|
+
}
|
|
42
52
|
if (!moduleResult.declaredVersion) {
|
|
43
|
-
logger.debug("Module has no declared version, skipping
|
|
53
|
+
logger.debug("Module has no declared version, skipping changes generation", { moduleId: moduleResult.id });
|
|
44
54
|
continue;
|
|
45
55
|
}
|
|
46
56
|
const { commits, lastTag } = await getCommitsForModule(moduleResult.id);
|
|
47
57
|
if (commits.length === 0) {
|
|
48
|
-
logger.info("No commits found, skipping
|
|
58
|
+
logger.info("No commits found, skipping rendering changes", {
|
|
49
59
|
moduleId: moduleResult.id,
|
|
50
60
|
});
|
|
51
61
|
continue;
|
|
52
62
|
}
|
|
53
|
-
const
|
|
63
|
+
const renderedPath = join(repoRoot, moduleResult.path, filename);
|
|
54
64
|
let prepend = true;
|
|
55
|
-
if (await exists(
|
|
65
|
+
if (await exists(renderedPath)) {
|
|
56
66
|
prepend = false;
|
|
57
67
|
}
|
|
58
68
|
const isRelease = isReleaseVersion(moduleResult.to);
|
|
@@ -61,7 +71,7 @@ export async function generateChangelogsForModules(moduleResults, getCommitsForM
|
|
|
61
71
|
? `${moduleResult.name}@${moduleResult.to}`
|
|
62
72
|
: undefined;
|
|
63
73
|
const previousTag = lastTag || undefined;
|
|
64
|
-
const
|
|
74
|
+
const changesContent = await writeChangelogString(commits, {
|
|
65
75
|
version: version,
|
|
66
76
|
previousTag: previousTag,
|
|
67
77
|
currentTag: currentTag,
|
|
@@ -72,55 +82,58 @@ export async function generateChangelogsForModules(moduleResults, getCommitsForM
|
|
|
72
82
|
provider,
|
|
73
83
|
}, config?.options);
|
|
74
84
|
if (dryRun) {
|
|
75
|
-
logger.info("Dry run enabled, skipping writing
|
|
85
|
+
logger.info("Dry run enabled, skipping writing changes to file", {
|
|
76
86
|
moduleId: moduleResult.id,
|
|
77
87
|
});
|
|
78
|
-
logger.debug("Generated
|
|
88
|
+
logger.debug("Generated changes content", { changesContent });
|
|
79
89
|
}
|
|
80
90
|
else {
|
|
81
|
-
await
|
|
91
|
+
await updateRenderFile(changesContent, renderedPath, prependPlaceholder);
|
|
82
92
|
}
|
|
83
|
-
|
|
93
|
+
renderedPaths.push(renderedPath);
|
|
84
94
|
}
|
|
85
|
-
return
|
|
95
|
+
return renderedPaths;
|
|
86
96
|
}
|
|
87
|
-
export async function
|
|
97
|
+
export async function renderRootChanges(moduleResults, getCommitsForModule, repoRoot, dryRun, filename, config, provider) {
|
|
88
98
|
const moduleResult = moduleResults.find((result) => result.type === "root");
|
|
89
99
|
if (!moduleResult) {
|
|
90
|
-
logger.info("No root module found, skipping root
|
|
100
|
+
logger.info("No root module found, skipping root changes generation");
|
|
91
101
|
return;
|
|
92
102
|
}
|
|
93
103
|
if (!config) {
|
|
94
|
-
throw new Error(`Missing required
|
|
104
|
+
throw new Error(`Missing required changes rendering configuration`);
|
|
95
105
|
}
|
|
96
|
-
logger.info("Loading root
|
|
106
|
+
logger.info("Loading root changes configuration");
|
|
97
107
|
const prependPlaceholder = config?.context?.prependPlaceholder;
|
|
98
108
|
if (!prependPlaceholder) {
|
|
99
|
-
throw new Error("Missing required context property 'prependPlaceholder'");
|
|
109
|
+
throw new Error("Missing required changes rendering context property 'prependPlaceholder'");
|
|
100
110
|
}
|
|
101
111
|
const contextRepository = await buildContextRepository({ cwd: repoRoot });
|
|
102
112
|
const { commits, lastTag } = await getCommitsForModule(moduleResult.id);
|
|
103
113
|
if (commits.length === 0) {
|
|
104
|
-
logger.info("No commits found, skipping root
|
|
114
|
+
logger.info("No commits found, skipping root changes", {
|
|
105
115
|
moduleId: moduleResult.id,
|
|
106
116
|
});
|
|
107
117
|
return;
|
|
108
118
|
}
|
|
109
|
-
const
|
|
119
|
+
const renderedPath = join(repoRoot, moduleResult.path, filename);
|
|
110
120
|
let prepend = true;
|
|
111
|
-
if (await exists(
|
|
121
|
+
if (await exists(renderedPath)) {
|
|
112
122
|
prepend = false;
|
|
113
123
|
}
|
|
114
124
|
const isRelease = isReleaseVersion(moduleResult.to);
|
|
115
125
|
const version = isRelease ? moduleResult.to : undefined;
|
|
116
126
|
const currentTag = isRelease
|
|
117
|
-
?
|
|
127
|
+
? getModuleTagName(moduleResult.name, moduleResult.to)
|
|
118
128
|
: undefined;
|
|
119
129
|
const previousTag = lastTag || undefined;
|
|
120
|
-
const
|
|
130
|
+
const changesContent = await writeChangelogString(commits, {
|
|
121
131
|
moduleResults,
|
|
122
132
|
version: version,
|
|
123
133
|
previousTag: previousTag,
|
|
134
|
+
previousTagVersion: previousTag
|
|
135
|
+
? parseTagName(previousTag).version
|
|
136
|
+
: undefined,
|
|
124
137
|
currentTag: currentTag,
|
|
125
138
|
linkCompare: previousTag && currentTag ? true : false,
|
|
126
139
|
...contextRepository,
|
|
@@ -129,14 +142,14 @@ export async function generateRootChangelog(moduleResults, getCommitsForModule,
|
|
|
129
142
|
provider,
|
|
130
143
|
}, config?.options);
|
|
131
144
|
if (dryRun) {
|
|
132
|
-
logger.info("Dry run enabled, skipping writing root
|
|
145
|
+
logger.info("Dry run enabled, skipping writing root changes to file", {
|
|
133
146
|
moduleId: moduleResult.id,
|
|
134
147
|
});
|
|
135
|
-
logger.debug("Generated root
|
|
148
|
+
logger.debug("Generated root changes content", { changesContent });
|
|
136
149
|
}
|
|
137
150
|
else {
|
|
138
|
-
await
|
|
151
|
+
await updateRenderFile(changesContent, renderedPath, prependPlaceholder);
|
|
139
152
|
}
|
|
140
|
-
return
|
|
153
|
+
return renderedPath;
|
|
141
154
|
}
|
|
142
155
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/changelog/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,IAAI,EAAE,EAAE,MAAM,IAAI,CAAC;AACpC,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAE5B,OAAO,EAGL,oBAAoB,GACrB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAE5C,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAC1C,OAAO,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/changelog/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,IAAI,EAAE,EAAE,MAAM,IAAI,CAAC;AACp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a;QACb,OAAO,EAAE,OAAO;QAChB,WAAW,EAAE,WAAW;QACxB,kBAAkB,EAAE,WAAW;YAC7B,CAAC,CAAC,YAAY,CAAC,WAAW,CAAC,CAAC,OAAO;YACnC,CAAC,CAAC,SAAS;QACb,UAAU,EAAE,UAAU;QACtB,WAAW,EAAE,WAAW,IAAI,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK;QACrD,GAAG,iBAAiB;QACpB,GAAG,MAAM,EAAE,OAAO;QAClB,OAAO;QACP,QAAQ;KACU,EACpB,MAAM,EAAE,OAA0B,CACnC,CAAC;IAEF,IAAI,MAAM,EAAE,CAAC;QACX,MAAM,CAAC,IAAI,CAAC,wDAAwD,EAAE;YACpE,QAAQ,EAAE,YAAY,CAAC,EAAE;SAC1B,CAAC,CAAC;QACH,MAAM,CAAC,KAAK,CAAC,gCAAgC,EAAE,EAAE,cAAc,EAAE,CAAC,CAAC;IACrE,CAAC;SAAM,CAAC;QACN,MAAM,gBAAgB,CAAC,cAAc,EAAE,YAAY,EAAE,kBAAkB,CAAC,CAAC;IAC3E,CAAC;IAED,OAAO,YAAY,CAAC;AACtB,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const footerPartial = "
|
|
1
|
+
export declare const footerPartial = "---\n*Generated by versu*\n";
|
|
2
2
|
//# sourceMappingURL=footer.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"footer.d.ts","sourceRoot":"","sources":["../../../src/config/templates/footer.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,aAAa,
|
|
1
|
+
{"version":3,"file":"footer.d.ts","sourceRoot":"","sources":["../../../src/config/templates/footer.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,aAAa,gCAEzB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"footer.js","sourceRoot":"","sources":["../../../src/config/templates/footer.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,aAAa,GAAG
|
|
1
|
+
{"version":3,"file":"footer.js","sourceRoot":"","sources":["../../../src/config/templates/footer.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,aAAa,GAAG;;CAE5B,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const mainModuleTemplate = "{{~#if prepend}}{{> header}}\n{{prependPlaceholder}}\n\n{{/if~}}\n{{~#if version}}\n{{~#if linkCompare}}\n## [{{version}}]({{repoUrl}}/compare/{{previousTag}}...{{currentTag}}) - {{date}}\n{{~else}}\n## [{{version}}]({{repoUrl}}/releases/tag/{{
|
|
1
|
+
export declare const mainModuleTemplate = "{{~#if prepend}}{{> header}}\n{{prependPlaceholder}}\n\n{{/if~}}\n{{~#if version}}\n{{~#if linkCompare}}\n## [{{version}}]({{repoUrl}}/compare/{{previousTag}}...{{currentTag}}) - {{date}}\n{{~else}}\n## [{{version}}]({{repoUrl}}/releases/tag/{{currentTag}}) - {{date}}\n{{~/if}}\n{{~else}}\n{{~#if previousTag}}\n## [Unreleased]({{repoUrl}}/compare/{{previousTag}}...HEAD) - {{date}}\n{{~else}}\n## Unreleased\n{{~/if}}\n{{~/if}}\n\n{{#each commitGroups}}\n\n### {{title}}\n\n{{#each commits}}\n{{> commit}}\n{{/each}}\n{{/each}}\n{{#if prepend}}\n\n{{> footer}}{{/if}}\n";
|
|
2
2
|
//# sourceMappingURL=main-module.d.ts.map
|