We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
There was an error while loading.Please reload this page.
1 parentae3d90b commit730b5ddCopy full SHA for 730b5dd
cli/root.go
@@ -72,7 +72,7 @@ const (
72
varDisableDirect="disable-direct-connections"
73
varDisableNetworkTelemetry="disable-network-telemetry"
74
75
-notLoggedInMessage="You are not logged in. Try logging in using 'coder login <url>'."
+notLoggedInMessage="You are not logged in. Try logging in using '%s login <url>'."
76
77
envNoVersionCheck="CODER_NO_VERSION_WARNING"
78
envNoFeatureWarning="CODER_NO_FEATURE_WARNING"
@@ -534,7 +534,11 @@ func (r *RootCmd) InitClient(client *codersdk.Client) serpent.MiddlewareFunc {
534
rawURL,err:=conf.URL().Read()
535
// If the configuration files are absent, the user is logged out
536
ifos.IsNotExist(err) {
537
-returnxerrors.New(notLoggedInMessage)
+binPath,err:=os.Executable()
538
+iferr!=nil {
539
+binPath="coder"
540
+}
541
+returnxerrors.Errorf(notLoggedInMessage,binPath)
542
}
543
iferr!=nil {
544
returnerr