Commit 9ba00c2
Move to cobra part 3 (#250)
* Improve Some command descriptions
* Add alias and shorthands support
* Drop unused symbols
* Add shell completions for common flags
Implement dynamic shell completions for app, team, job, pool, plan,
platform, and router flags. This enables tab completion in shells for
these frequently used flags, improving CLI usability.
Also removes local platform struct in favor of appTypes.Platform.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Update license header
* Remove redundant MinArgs: 0 declarations
MinArgs defaults to 0, so explicitly setting it is unnecessary. This
cleanup removes the redundant declarations and fixes formatting.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Add shell completions for app/job commands and update shorthands
Implement Complete() method for app commands (AppCreate, AppInfo,
AppGrant, AppRevoke, AppStop, AppStart, AppRestart) and job commands
(JobInfo, JobDelete, JobTrigger, JobUpdate, JobLog) to provide
tab completion suggestions. Also fix ShorthandCommand to properly
delegate completion to wrapped commands.
Update shorthand registrations: add rollback, remove scale.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Add AutoCompleteCommand interface and gray color for env observations
- Add AutoCompleteCommand interface for commands with custom arg completion
- Implement ValidArgsFunction integration in ManagerV2 for auto-complete
- Add common aliases support for FQDN commands on root
- Add gray color support to Colorfy for subtle text styling
- Apply gray coloring to env variable observations (private, managed by)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Update tsuru/client/apps.go
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Rename autoscale commands and improve deprecated command UX
- Rename unit-autoscale-{set,unset,swap} to autoscale-{set,unset,swap}
- Register old names as deprecated aliases
- Improve DeprecatedCommand to show colored warnings with humanized
command names (e.g., "tsuru app info" instead of "app-info")
- Add DEPRECATED notice to help output for deprecated commands
- Standardize topic descriptions (capitalization and punctuation)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Add shell completions for service commands
Implement AutoCompleteCommand interface for service-related commands
to provide shell tab-completion for service names, instance names,
and team names. Adds ServiceInstanceCompletionMixIn for reusable
completion logic across multiple service instance commands.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Use ExtractProgramName
* Add generate-doc command for markdown documentation
Add a hidden generate-doc command that uses cobra/doc to generate
markdown documentation for all CLI commands.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* fix tests
* Attempt to fix CI test on windows
* Refactor Manager.Run to return error for proper exit handling
Update both V1 and V2 Manager.Run methods to return error instead of
calling os.Exit directly. This enables better error propagation and
allows main() to handle exit codes consistently. Also simplifies
root command configuration by removing redundant runRootCmd function.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Attempt to fix CI test on windows[2]
* Enable V2 by default and fix V1-specific tests
Change the version check to default to V2 (require explicit v1 to use V1).
Remove RemovedCommand which is no longer needed with V2.
Add V2() getter to Manager and disable V2 in V1-specific tests.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Fix grammar
* Fix ServiceTemplate
* Fix test
* Drop deprecated AppDeployRebuild
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>1 parent 422c2ba commit 9ba00c2
File tree
52 files changed
+2289
-392
lines changed- tsuru
- admin
- auth
- client
- cmd
- completions
- standards
- v2
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
52 files changed
+2289
-392
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| 43 | + | |
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| |||
76 | 77 | | |
77 | 78 | | |
78 | 79 | | |
| 80 | + | |
79 | 81 | | |
80 | 82 | | |
81 | 83 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
29 | 30 | | |
30 | 31 | | |
31 | 32 | | |
| |||
228 | 229 | | |
229 | 230 | | |
230 | 231 | | |
| 232 | + | |
231 | 233 | | |
232 | 234 | | |
233 | 235 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
24 | | - | |
25 | | - | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
35 | 34 | | |
36 | 35 | | |
37 | 36 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
| 27 | + | |
27 | 28 | | |
28 | 29 | | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | 30 | | |
35 | 31 | | |
36 | 32 | | |
| |||
46 | 42 | | |
47 | 43 | | |
48 | 44 | | |
49 | | - | |
| 45 | + | |
50 | 46 | | |
51 | 47 | | |
52 | 48 | | |
| |||
103 | 99 | | |
104 | 100 | | |
105 | 101 | | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
110 | 105 | | |
111 | 106 | | |
112 | 107 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
18 | 19 | | |
19 | 20 | | |
20 | 21 | | |
| |||
558 | 559 | | |
559 | 560 | | |
560 | 561 | | |
561 | | - | |
| 562 | + | |
562 | 563 | | |
563 | 564 | | |
564 | | - | |
| 565 | + | |
565 | 566 | | |
566 | 567 | | |
567 | 568 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
99 | 99 | | |
100 | 100 | | |
101 | 101 | | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
106 | 106 | | |
107 | 107 | | |
108 | 108 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
241 | 241 | | |
242 | 242 | | |
243 | 243 | | |
244 | | - | |
245 | | - | |
246 | 244 | | |
247 | 245 | | |
248 | | - | |
| 246 | + | |
249 | 247 | | |
250 | 248 | | |
251 | 249 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
237 | 237 | | |
238 | 238 | | |
239 | 239 | | |
240 | | - | |
241 | | - | |
242 | 240 | | |
243 | 241 | | |
244 | | - | |
| 242 | + | |
245 | 243 | | |
246 | 244 | | |
247 | 245 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
45 | | - | |
46 | 45 | | |
47 | 46 | | |
48 | 47 | | |
| |||
0 commit comments