-
Notifications
You must be signed in to change notification settings - Fork 65
chore (cli): clarify command and flag help texts #1646
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
dbee9c9
c949c85
6445acf
72d337d
d1c747a
4932770
34573f3
c5287f5
cfd57d7
104373f
0a16ddd
57558bc
a6cc781
0f5e833
8e8ce8a
3ae4fe7
7dbf3e6
0821160
24c5e2c
149357e
f60fa0d
65e53bc
39f7f3e
33b9f63
3c988cc
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -27,6 +27,7 @@ var ( | |
| var extensionPackageCmd = &cobra.Command{ | ||
| Use: "package path [branch]", | ||
| Short: "Build a distributable extension ZIP", | ||
| Long: "Build a ZIP of an extension. By default, files come from a clean Git checkout of the current tag or branch, so uncommitted changes are not included; use --disable-git to package the working copy. The build runs in a temporary folder and leaves the extension folder unchanged. The ZIP is named <name>-<tag-or-branch>.zip when a tag or branch is available, or <name>.zip otherwise, unless --filename is set.", | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win Avoid guaranteeing that the extension folder stays unchanged. Configured shell hooks receive 🤖 Prompt for AI Agents |
||
| Aliases: []string{"zip"}, | ||
| Args: cobra.RangeArgs(1, 2), | ||
| RunE: func(cmd *cobra.Command, args []string) error { | ||
|
|
@@ -228,17 +229,17 @@ var extensionPackageCmd = &cobra.Command{ | |
|
|
||
| func init() { | ||
| extensionRootCmd.AddCommand(extensionPackageCmd) | ||
| extensionPackageCmd.Flags().BoolVar(&disableGit, "disable-git", false, "Package the working copy instead of a clean git checkout (symlinks are skipped)") | ||
| extensionPackageCmd.Flags().BoolVar(&extensionReleaseMode, "release", false, "Prepare a release build (generate the changelog, remove app secrets)") | ||
| extensionPackageCmd.Flags().String("overwrite-app-backend-url", "", "Change all URLs in manifest.xml to this URL") | ||
| extensionPackageCmd.Flags().String("overwrite-app-backend-secret", "", "Change the secret to this value") | ||
| extensionPackageCmd.Flags().String("overwrite-version", "", "Change the extension version to this value") | ||
| extensionPackageCmd.Flags().Bool("use-git-tag-as-version", false, "Use the detected git tag as the extension version") | ||
| extensionPackageCmd.Flags().BoolVar(&disableGit, "disable-git", false, "Package the working copy instead of a clean Git checkout (symlinks are skipped)") | ||
|
Ant1gua marked this conversation as resolved.
|
||
| extensionPackageCmd.Flags().BoolVar(&extensionReleaseMode, "release", false, "Prepare a release build: generate the changelog if enabled and, for apps, remove the secret from manifest.xml") | ||
| extensionPackageCmd.Flags().String("overwrite-app-backend-url", "", "Replace the scheme and host of the app backend URLs in manifest.xml (apps only)") | ||
| extensionPackageCmd.Flags().String("overwrite-app-backend-secret", "", "Set the app secret in manifest.xml (apps only)") | ||
| extensionPackageCmd.Flags().String("overwrite-version", "", "Set the extension version in the package") | ||
| extensionPackageCmd.Flags().Bool("use-git-tag-as-version", false, "Use the Git tag (without a leading v) as the extension version") | ||
| extensionPackageCmd.MarkFlagsMutuallyExclusive("use-git-tag-as-version", "disable-git") | ||
| extensionPackageCmd.MarkFlagsMutuallyExclusive("use-git-tag-as-version", "overwrite-version") | ||
| extensionPackageCmd.Flags().String("output-directory", "", "Output directory for the zip file") | ||
| extensionPackageCmd.Flags().String("git-commit", "", "Commit hash or tag to package (defaults to the current tag or branch)") | ||
| extensionPackageCmd.Flags().String("filename", "", "Name of the zip file, generated from the extension name and tag when not set") | ||
| extensionPackageCmd.Flags().String("output-directory", "", "Directory for the ZIP file (created if missing)") | ||
| extensionPackageCmd.Flags().String("git-commit", "", "Git commit hash, tag, or branch to package (default: the current tag or branch)") | ||
| extensionPackageCmd.Flags().String("filename", "", "Name of the ZIP file (default: <name>-<tag>.zip when tagged, otherwise <name>.zip)") | ||
| } | ||
|
|
||
| func getStringOnStringError(val string, _ error) string { | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.