Conversation
- Updated the maxTokens value in the LLM_DEFAULTS from 4,000 to 16,384 to enhance the model's capacity for processing larger inputs, improving overall performance in note-taking applications.
…Strategy - Updated the `createSyncStrategy` function to improve the logic for determining the version source package. - Introduced `versionSourcePath` and `versionSourceName` to allow for more flexible version calculations, especially when no main package is specified. - Enhanced logging to provide clearer feedback on the selected version source, improving user guidance during version determination.
Release Preview — no release
Updated automatically by ReleaseKit |
Greptile SummaryThis PR is a broad configuration rework that replaces the old Key changes:
Confidence Score: 4/5
|
| Filename | Overview |
|---|---|
| packages/config/src/schema.ts | Replaces OutputConfigSchema with ChangelogConfigSchema + ReleaseNotesConfigSchema; renames releaseNotes to body in GitHubReleaseConfigSchema; removes notes.monorepo, notes.templates, notes.llm, notes.input fields from NotesConfigSchema. Schema logic looks correct. |
| packages/notes/src/core/pipeline.ts | Central pipeline refactored: LLM is now gated under releaseNotes.llm; changelog and release-notes each have independent mode/file logic; writeMonorepoFiles helper added. Old notes.output/notes.llm config keys are silently dropped, and detectMonorepo is called twice when both sections use packages mode. |
| packages/notes/src/cli.ts | CLI rewritten with new flags (--changelog-mode, --release-notes-mode, --no-changelog, --no-release-notes); notes init now detects monorepo and writes valid ChangelogConfig shape; previous issue with invalid ChangelogConfig in init is resolved. |
| packages/publish/src/stages/github-release.ts | Replaces old releaseNotes string (including file-path fallback) with typed BodySource enum; removes readFileIfExists; resolveNotes now correctly gates auto-notes behind releaseNotesEnabled. Warning message when LLM-generated notes are absent can be misleading. |
| packages/publish/src/types.ts | Renames releaseNotes: string to body: BodySource enum in GitHubReleaseConfig; updates getDefaultConfig and toPublishConfig. Clean change with no issues. |
| packages/notes/src/core/types.ts | Restructures Config interface: removes output array and top-level llm/templates; adds `changelog?: false |
| packages/version/src/core/versionStrategies.ts | Separates versionSourcePath/versionSourceName from mainPkgPath/mainPkgName; adds first-workspace-package fallback when no mainPackage is configured; fixes spurious ${packageName} in tag templates for multi-package sync mode. |
| packages/release/src/release.ts | Removes getDefaultConfig dependency; passes releaseNotes ?? packageNotes to publish step so LLM-generated notes take precedence over standard changelog entries. Change is intentional and correct. |
| releasekit.config.json | Config updated to new schema: notes.output/llm replaced by notes.changelog + notes.releaseNotes; publish.githubRelease.body: 'auto' added; $schema changed to remote GitHub Pages URL. |
| releasekit.schema.json | JSON schema updated to match new config structure; additionalProperties: false added to many sub-objects; notes.output array replaced with notes.changelog/notes.releaseNotes oneOf schemas; body enum replaces releaseNotes string in githubRelease. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[runPipeline] --> B{config.changelog}
B -- false --> C[Skip changelog]
B -- undefined --> D["changelogConfig = { mode: 'root' }"]
B -- object --> E["changelogConfig = { mode: 'root', ...config.changelog }"]
D --> F{changelogConfig.mode?}
E --> F
F -- root/both --> G[writeMarkdown to root file]
F -- packages/both --> H[writeMonorepoFiles]
H --> I[detectMonorepo]
I -- not monorepo --> J[return empty]
I -- is monorepo --> K[writeMonorepoChangelogs mode:packages]
A --> L{config.releaseNotes}
L -- undefined/false --> M[Skip release notes]
L -- object --> N{has mode or file?}
N -- yes --> O["releaseNotesConfig = { mode: 'root', ...config.releaseNotes }"]
N -- no --> P[releaseNotesConfig = config.releaseNotes]
O --> Q{releaseNotesConfig.llm?}
P --> Q
Q -- yes --> R[processWithLLM contexts]
Q -- no --> S[Skip LLM]
R --> T{releaseNotesConfig.mode?}
S --> T
T -- root/both --> U[writeMarkdown to release notes file]
T -- packages/both --> V[writeMonorepoFiles]
T -- undefined --> W[No file written, LLM result in memory only]
Reviews (18): Last reviewed commit: "fix(release): update publish step to use..." | Re-trigger Greptile
…ration - Added new command-line options to the `generate` command for better control over changelog and release notes generation, including `--no-changelog`, `--changelog-mode`, `--changelog-file`, `--release-notes-mode`, and `--release-notes-file`. - Updated the configuration loading to accommodate the new options, allowing for more flexible user-defined settings. - Refactored the handling of LLM configuration to ensure compatibility with the new release notes structure. - Improved error handling and logging for LLM processing, enhancing user feedback during execution.
- Updated the GitHubReleaseConfig interface to rename the `releaseNotes` property to `body`, reflecting a more accurate description of its purpose. - Adjusted the logic in the `resolveNotes` function to accommodate the new `body` property, enhancing clarity in how release notes are resolved. - Modified related tests to ensure consistency with the updated configuration property name.
- Added new configuration schemas for `ChangelogConfig` and `ReleaseNotesConfig`, allowing for more flexible management of changelog and release notes settings. - Updated the `NotesConfigSchema` to include optional properties for `changelog` and `releaseNotes`, enhancing the configuration capabilities. - Refactored related tests to validate the new schema structures and ensure proper functionality.
- Refactored the `notes` section in `releasekit.config.json` to introduce a new structure for `changelog` and `releaseNotes`, enhancing clarity and usability. - Updated the `releasekit.schema.json` to define a new `MonorepoConfig` schema, streamlining the configuration for monorepo setups. - Improved the `GitHubReleaseConfig` by renaming the `releaseNotes` property to `body`, aligning with its intended purpose. - Added additional properties to various configurations to ensure better validation and flexibility in managing changelog and release notes.
- Updated the logic in the CLI to ensure that the `releaseNotes` configuration is correctly validated as an object, enhancing compatibility with the new structure. - Adjusted the handling of the `llm` property to ensure proper integration with the updated release notes configuration, improving overall functionality.
- Removed the default output configuration logic from the notes step, simplifying the configuration process. - Updated unit tests to reflect changes in the notes configuration structure, ensuring alignment with the new handling of changelog settings.
…-package setups - Integrated monorepo detection into the CLI to determine the appropriate changelog mode, defaulting to 'packages' for monorepos and 'root' for single-package repositories. - Updated the default changelog configuration to reflect the new detection logic. - Enhanced unit tests to validate the correct configuration is written based on the detected project type.
- Changed the default schema URL in the CLI from the previous releasekit.dev to the new goosewobbler.github.io path, ensuring accurate schema validation for release notes configuration.
- Revised the description for the changelog mode in `releasekit.schema.json` to provide clearer guidance on its usage, detailing the options for writing changelog files in different configurations.
- Changed the default anthropic model from 'claude-3-5-haiku-latest' to 'claude-haiku-4-5-20251001' to reflect the latest version.
…tion handling - Introduced a new CLI option `--regenerate` to allow users to regenerate the entire changelog instead of just prepending new entries. - Updated the changelog and release notes configuration to include a mode property, improving clarity on how files are managed based on user-defined settings. - Enhanced the logic to set the update strategy to 'regenerate' when the new option is used, ensuring proper handling of changelog updates.
- Introduced an `updateStrategy` property to the `NotesConfigSchema`, allowing users to specify their preferred method for handling changelog updates, with options for 'prepend' and 'regenerate'. This enhancement improves flexibility in configuration management.
- Modified the conditions for checking the `updateStrategy` in `writeMonorepoChangelogs` and `writeMarkdown` functions to ensure that the 'regenerate' strategy is correctly handled, preventing unintended prepending of changelog entries. - Added unit tests to verify default behavior for changelog and release notes modes when specific CLI flags are set, enhancing overall configuration management.
- Updated the `writeMonorepoFiles` function to always set the mode to 'packages', regardless of the input location. - Added unit tests to ensure that the changelog writing process correctly uses the 'packages' mode when the changelog mode is set to 'both', preventing unintended behavior.
…tions - Updated the CLI logic to maintain the disabled state of the changelog when both `--no-changelog` and `--template` or `--engine` options are used. - Added unit tests to verify that the changelog configuration is correctly handled under these conditions, enhancing the robustness of the command behavior.
- Updated the documentation in `github-release.ts` to replace the term 'github' with 'generated' for clarity on the notes body options, ensuring accurate representation of the functionality.
- Refactored the logic in the CLI to streamline the configuration of changelog and release notes, ensuring that an empty changelog config is treated the same as undefined, defaulting to 'root' mode. - Updated unit tests to verify the handling of edge cases for changelog configuration, enhancing the robustness of the pipeline.
- Enhanced the logic for handling changelog and release notes configurations to ensure that file-only settings default to 'root' mode, improving clarity and consistency. - Updated unit tests to validate the behavior of the pipeline when configurations omit the mode, ensuring correct file generation for changelog and release notes.
- Updated the `writeMonorepoFiles` and `writeMonorepoChangelogs` functions to accept a customizable file name for changelogs and release notes, improving flexibility in configuration. - Modified unit tests to ensure that the correct file names are passed during the pipeline execution, validating the new behavior for both changelog and release notes modes.
…s disabled - Enhanced the CLI to issue warnings when the `--template` or `--engine` options are used while the changelog is disabled via `--no-changelog`. - Updated unit tests to verify that the appropriate warnings are triggered under these conditions, ensuring clear communication of configuration constraints.
…guration - Enhanced the CLI to propagate the --monorepo mode to both changelog and release notes configurations, ensuring consistent file output based on user-defined settings. - Implemented logic to allow explicit --changelog-mode and --release-notes-mode options to take priority over --monorepo when both are specified. - Added unit tests to verify the correct behavior of the new configuration handling, ensuring that the pipeline respects the intended modes for changelog and release notes.
- Updated the logic in the pipeline to ensure that release notes are not written when only LLM configuration is set without specifying a mode or file, enhancing clarity in file generation behavior. - Modified unit tests to verify that the pipeline correctly handles scenarios where release notes should not be generated, ensuring consistent output based on user-defined settings.
- Updated the CLI to inherit the top-level monorepo path configuration when the notes configuration does not specify a monorepo key, simplifying the configuration process. - This change removes the need for a duplicate notes.monorepo key, ensuring that path overrides work as intended.
…json - Removed the $defs reference for MonorepoConfig and inlined its properties directly under the monorepo key, simplifying the schema structure. - This change enhances clarity and accessibility of the monorepo configuration within the schema.
…ling - Refactored the CLI logic to simplify the configuration of changelog and release notes by consolidating mode and file settings. - Updated unit tests to ensure that the correct modes and files are preserved when both options are specified, enhancing the reliability of the command behavior.
- Introduced new properties for retry logic, including maxAttempts, initialDelay, maxDelay, and backoffFactor, to enhance error handling capabilities. - Added prompts configuration with instructions and templates for per-task customization, improving user experience and flexibility in task execution. - Included an updateStrategy option to define how existing changelog files are updated, offering users more control over changelog management.
- Updated the CLI logic to ensure that LLM configuration options are ignored when release notes are disabled via the `--no-release-notes` flag, providing clearer user feedback. - Enhanced the configuration loading to inherit monorepo settings correctly, ensuring consistent behavior across different entry points. - Added unit tests to verify the correct behavior when combining `--no-release-notes` with LLM options, ensuring that warnings are issued appropriately.
…onfiguration handling - Refactored tests to use non-null assertions for entries, enhancing type safety and preventing potential runtime errors. - Updated configuration objects to use `as const` for better type inference, ensuring consistent behavior across test cases. - Simplified the handling of optional chaining in test cases, improving code readability and maintainability.
- Updated the CLI to ensure that the LLM processing is only disabled when the `--no-llm` flag is used and the release notes configuration allows for LLM processing, improving clarity in configuration handling. - Enhanced the logic to prevent unnecessary warnings when LLM processing is disabled, ensuring a more intuitive user experience.
- Modified the publish step to utilize `releaseNotes` when provided, ensuring that the correct notes are published alongside the version output. - This change enhances the flexibility of the release process by allowing for more accurate note handling.
No description provided.