Skip to content

Commit

Permalink
chore: update copy when printing auth key
Browse files Browse the repository at this point in the history
  • Loading branch information
coadler committed Dec 13, 2024
1 parent 085989b commit 1ff2c90
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions cmd/wush/serve.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,10 @@ func serveCmd() *serpent.Command {
// Ensure we always print the auth key on stdout
if isatty.IsTerminal(os.Stdout.Fd()) {
hlog("Your auth key is:")
fmt.Println("\t>", cliui.Code(r.ClientAuth().AuthKey()))
fmt.Println(" >", cliui.Code(r.ClientAuth().AuthKey()))
hlog("Use this key to authenticate other " + cliui.Code("wush") + " commands to this instance.")
hlog("Visit the following link to connect via the browser:")
fmt.Println("\t>", cliui.Code("https://wush.dev#"+r.ClientAuth().AuthKey()))
fmt.Println(" >", cliui.Code("https://wush.dev#"+r.ClientAuth().AuthKey()))
} else {
fmt.Println(cliui.Code(r.ClientAuth().AuthKey()))
hlog("The auth key has been printed to stdout")
Expand All @@ -105,7 +105,10 @@ func serveCmd() *serpent.Command {
return err
}

ts.Up(ctx)
_, err = ts.Up(ctx)
if err != nil {
return fmt.Errorf("bring wireguard up: %w", err)
}
fs := afero.NewOsFs()

// hlog("WireGuard is ready")
Expand Down

0 comments on commit 1ff2c90

Please sign in to comment.