-
Notifications
You must be signed in to change notification settings - Fork 5
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
Update init command format and add a helpful link #387
Conversation
e0f92fc
to
220c6d3
Compare
} | ||
|
||
return os.Chdir(pwd) | ||
} | ||
|
||
func modulesInit(l log.Logger, appPath string, skipInit, vendor bool) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lint complained... made me do it
8d59572
to
3552f0c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This reads great, thank you for the swift iteration on this! ✨
case "js", JavaScript, NodeJs: | ||
err = turbinejs.Init(ctx, i.logger, name, i.path) | ||
case "py", Python3, Python: | ||
err = turbinepy.Init(ctx, i.logger, name, i.path) | ||
default: | ||
i.logger.StopSpinnerWithStatus("\t", log.Failed) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice addition!
cmd/meroxa/turbine_cli/utils.go
Outdated
func GoInit(ctx context.Context, l log.Logger, appPath string, skipInit, vendor bool) error { | ||
func GoInit(l log.Logger, appPath string, skipInit, vendor bool) error { | ||
l.StartSpinner("\t", "Running golang module initializing...") | ||
skipLog := "skipping go module initialization\n\tFor guidance, visit https://docs.meroxa.com/beta-overview#go-mod-init-for-a-new-golang-turbine-data-application" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This reads neat!
@@ -62,3 +65,7 @@ func (l *spinnerLogger) SuccessfulCheck() string { | |||
func (l *spinnerLogger) FailedMark() string { | |||
return color.New(color.FgRed).Sprintf("x") | |||
} | |||
|
|||
func (l *spinnerLogger) WarningMark() string { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Description of change
Make init command conform to the standards of the other app commands.
Provide a helpful link when go mod init must be aborted.
Fixes https://github.com/meroxa/turbine-project/issues/202
Fixes https://github.com/meroxa/turbine-project/issues/212
Type of change
How was this tested?
Demo
BEFORE
AFTER
Additional references
Documentation updated