Repository navigation
fix(ai): make the committed AI usage prompt a function of the code - #110
Merged
Merged
Conversation
_serialize_connection() never wrote board_id, so a board configured for sprint operations was dropped on every save. It now round-trips like the other optional fields: written when set, omitted when unset. Refs #108
"connect add" rebuilt the connection from the four values it prompts for, so updating a URL, email or project key silently reset Tempo, custom fields, the board, the AI prompt and the cache settings to their defaults. The stored connection is now carried forward and only the given values are changed. Fixes #108
"ai usage-prompt" renders ~/.config/budjira/ai-prompt-template.toml when that file exists, which makes the output machine-dependent. --defaults renders the built-in template instead, so a copy checked into a repository is a function of the installed version. The user template overlay stays the default for interactive use. Refs #105
The freshness hook built its baseline with the same command it recommends, so on a machine with a stale local template it compared one stale rendering against another and reported the file as up to date while it was missing documented features. Both sides now use --defaults, and the reminder text is derived from the command that is actually run. Fixes #105
The option lists for "create issue" and "issue update" were carrying the flag only in the generated file. Putting it in the template makes the generated copy reproducible from the code. Refs #106
f3rdy
changed the base branch from
fix/issue-108-connection-write-path
to
master
August 13, 2026 15:50
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #105.
Stacked on #108, which is stacked on #107; GitHub retargets this to master as the
lower PRs merge.
The defect
ai usage-promptrenders~/.config/budjira/ai-prompt-template.tomlwhen that fileexists, and
load_ai_prompt_template()writes that file on first use. The documentedregeneration command therefore produces different output per machine, and
scripts/check_ai_prompt.pybuilt its baseline with the same command - so on amachine with a stale local template it compared one stale rendering against another
and reported the committed file as up to date while it was missing documented
features.
The change
ai usage-prompt --defaultsrenders the built-in template and never touches thelocal overlay, so a file checked into a repository is a function of the installed
version. The overlay stays the default for interactive use.
--defaults, and its reminder textis derived from the command it actually runs, so the two cannot drift apart again.
CLAUDE.mddocuments the flag as mandatory for regeneration, with the reason.--description-dialectoption oncreate issueand
issue update, so the committed prompt is reproducible from code rather thanhand-maintained.
Verification
On a machine carrying a stale local template:
997 tests pass, all pre-commit hooks green. New tests:
--defaultsdoes not renderthe local template (and the flagless call still does), the built-in template documents
the options the CLI offers, and the hook's baseline command carries
--defaultsandmatches its own reminder text.