Skip to content

Commit 6d48fb0

Browse files
committed
prettify warning
1 parent 280c603 commit 6d48fb0

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

cmd/bundle.go

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import (
88
"path/filepath"
99
"strings"
1010

11+
"github.com/massdriver-cloud/airlock/pkg/prettylogs"
1112
"github.com/massdriver-cloud/mass/docs/helpdocs"
1213
"github.com/massdriver-cloud/mass/pkg/api"
1314
"github.com/massdriver-cloud/mass/pkg/bundle"
@@ -92,7 +93,7 @@ func NewCmdBundle() *cobra.Command {
9293
RunE: runBundlePublish,
9394
}
9495
bundlePublishCmd.Flags().StringP("bundle-directory", "b", ".", "Path to a directory containing a massdriver.yaml file.")
95-
bundlePublishCmd.Flags().String("access", "private", "Override the access, useful in CI for deploying to sandboxes.")
96+
bundlePublishCmd.Flags().String("access", "", "Override the access, useful in CI for deploying to sandboxes.")
9697

9798
bundlePullCmd := &cobra.Command{
9899
Use: "pull <bundle-name>",
@@ -330,7 +331,8 @@ func runBundlePublish(cmd *cobra.Command, args []string) error {
330331

331332
access, _ := cmd.Flags().GetString("access")
332333
if access != "" {
333-
fmt.Println("Warning: The --access flag is deprecated and will be removed in a future release.")
334+
prettylogs.Orange("Warning: The --access flag is deprecated and will be removed in a future release.")
335+
fmt.Println(prettylogs.Orange("Warning: The --access flag is deprecated and will be removed in a future release."))
334336
}
335337

336338
bundleDirectory, err := cmd.Flags().GetString("bundle-directory")
@@ -371,7 +373,7 @@ func runBundlePull(cmd *cobra.Command, args []string) error {
371373
// Check if bundle exists in the specified directory and if so prompt the user
372374
mdYamlPath := filepath.Join(directory, "massdriver.yaml")
373375
if _, err := os.Stat(mdYamlPath); err == nil && !force {
374-
fmt.Printf("Warning: bundle already exists at %s. Continuing will overwrite its contents. Continue? (y/N): ", mdYamlPath)
376+
fmt.Printf("Bundle already exists at %s. Continuing will overwrite its contents. Continue? (y/N): ", mdYamlPath)
375377
reader := bufio.NewReader(os.Stdin)
376378
answer, _ := reader.ReadString('\n')
377379
answer = strings.TrimSpace(strings.ToLower(answer))

0 commit comments

Comments
 (0)