feat: Add --project flag to tmpo milestone [start | finish | status]#108
Merged
DylanDevelops merged 2 commits intomainfrom Apr 3, 2026
Merged
feat: Add --project flag to tmpo milestone [start | finish | status]#108DylanDevelops merged 2 commits intomainfrom
--project flag to tmpo milestone [start | finish | status]#108DylanDevelops merged 2 commits intomainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a --project/-p override to milestone subcommands so users can operate on a specific global project from any directory (aligning milestone behavior with other commands that already support project overrides).
Changes:
- Added
--project/-pflags tomilestone start,milestone finish, andmilestone status. - Updated each command to resolve the project via
project.DetectConfiguredProjectWithOverride(...)instead of always using local detection.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| cmd/milestones/start.go | Adds --project/-p and uses override-aware project detection for starting milestones. |
| cmd/milestones/finish.go | Adds --project/-p and uses override-aware project detection for finishing milestones. |
| cmd/milestones/status.go | Adds --project/-p and uses override-aware project detection for milestone status. |
Comments suppressed due to low confidence (2)
cmd/milestones/finish.go:36
- With
DetectConfiguredProjectWithOverride, this command can operate on a project other than the locally configured one. However, the subsequent error text “No active milestone found” (and the help text) doesn’t indicate which project was checked, which can be confusing when--projectis used. Consider includingprojectNamein the no-active-milestone message (e.g., “No active milestone found for ”) and updating theLongdescription that currently says “for the current project”.
projectName, err := project.DetectConfiguredProjectWithOverride(finishMilestoneProjectFlag)
if err != nil {
ui.PrintError(ui.EmojiError, fmt.Sprintf("detecting project: %v", err))
os.Exit(1)
}
cmd/milestones/status.go:38
- Similar to
finish, this now supports--project, but the command help still claims it reports status “for the current project”, and the “No active milestone” warning doesn’t indicate which project was checked. Update the help text and consider includingprojectNamein the no-active warning/output to avoid confusion when users runtmpo milestone status --project <name>from another directory.
projectName, err := project.DetectConfiguredProjectWithOverride(statusMilestoneProjectFlag)
if err != nil {
ui.PrintError(ui.EmojiError, fmt.Sprintf("detecting project: %v", err))
os.Exit(1)
}
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
tmpo milestone [start] | [finish] | [status]
tmpo milestone [start] | [finish] | [status]tmpo milestone [start | finish | status]
tmpo milestone [start | finish | status]--project flag to tmpo milestone [start | finish | status]
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.
Pull Request Checklist
mainbranch of tmpo.Closes #106
Description
This pull request enhances the
milestonesCLI commands by adding a--project(or-p) flag to thestart,finish, andstatussubcommands. This allows users to specify a particular global project when managing milestones, increasing flexibility and control over milestone operations.New flag for project selection:
--project(-p) flag to themilestones start,milestones finish, andmilestones statuscommands, enabling users to target a specific global project when running these commands. [1] [2] [3]project.DetectConfiguredProjectWithOverridewith the provided project value, instead of always detecting the configured project automatically. [1] [2] [3]