Skip to content

Commit 50ed912

Browse files
committed
cmd/cue: un-hide login command and update docs
We will soon publish the first tutorials using the central registry, so they will ask users to run `cue login`. Un-hide the command so it can be found with its documentation. Tweak the documentation after the $CUE_CONFIG_DIR change as well. Signed-off-by: Daniel Martí <[email protected]> Change-Id: I5dcd754e89dacf815d4460725c9aa72793b76765 Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1185185 TryBot-Result: CUEcueckoo <[email protected]> Reviewed-by: Paul Jolly <[email protected]> Unity-Result: CUE porcuepine <[email protected]>
1 parent 4aaa2db commit 50ed912

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

cmd/cue/cmd/login.go

+2-6
Original file line numberDiff line numberDiff line change
@@ -46,19 +46,15 @@ import (
4646

4747
func newLoginCmd(c *Command) *cobra.Command {
4848
cmd := &cobra.Command{
49-
// TODO: this command is still experimental, don't show it in
50-
// the documentation just yet.
51-
Hidden: true,
52-
5349
Use: "login [registry]",
5450
Short: "log into a CUE registry",
5551
Long: `WARNING: THIS COMMAND IS EXPERIMENTAL.
5652
5753
Log into a CUE registry via the OAuth 2.0 Device Authorization Grant.
5854
Without an argument, CUE_REGISTRY is used if it points to a single registry.
5955
60-
Once the authorization is successful, a token is stored in a cue/logins.json file
61-
inside your user's config directory, such as $XDG_CONFIG_HOME or %AppData%.
56+
Once the authorization is successful, a token is stored in a logins.json file
57+
inside $CUE_CONFIG_DIR; see 'cue help environment'.
6258
`,
6359
Args: cobra.MaximumNArgs(1),
6460
RunE: mkRunE(c, func(cmd *Command, args []string) error {

cmd/cue/cmd/testdata/script/help.txtar

+1
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ Available Commands:
4444
get add dependencies to the current module
4545
help Help about any command
4646
import convert other formats to CUE files
47+
login log into a CUE registry
4748
mod module maintenance
4849
trim remove superfluous fields
4950
version print CUE version

0 commit comments

Comments
 (0)