Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit8165a6e

Browse files
authored
feat: Add spooky hidden flag (#1065)
1 parenta68b076 commit8165a6e

File tree

1 file changed

+22
-2
lines changed

1 file changed

+22
-2
lines changed

‎cli/start.go

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ func start() *cobra.Command {
6363
traceDatadogbool
6464
secureAuthCookiebool
6565
sshKeygenAlgorithmRawstring
66+
spookybool
6667
)
6768

6869
root:=&cobra.Command{
@@ -76,7 +77,7 @@ func start() *cobra.Command {
7677
defertracer.Stop()
7778
}
7879

79-
printLogo(cmd)
80+
printLogo(cmd,spooky)
8081
listener,err:=net.Listen("tcp",address)
8182
iferr!=nil {
8283
returnxerrors.Errorf("listen %q: %w",address,err)
@@ -394,6 +395,8 @@ func start() *cobra.Command {
394395
cliflag.BoolVarP(root.Flags(),&secureAuthCookie,"secure-auth-cookie","","CODER_SECURE_AUTH_COOKIE",false,"Specifies if the 'Secure' property is set on browser session cookies")
395396
cliflag.StringVarP(root.Flags(),&sshKeygenAlgorithmRaw,"ssh-keygen-algorithm","","CODER_SSH_KEYGEN_ALGORITHM","ed25519","Specifies the algorithm to use for generating ssh keys. "+
396397
`Accepted values are "ed25519", "ecdsa", or "rsa4096"`)
398+
cliflag.BoolVarP(root.Flags(),&spooky,"spooky","","",false,"Specifies spookiness level")
399+
_=root.Flags().MarkHidden("spooky")
397400

398401
returnroot
399402
}
@@ -464,7 +467,24 @@ func newProvisionerDaemon(ctx context.Context, client *codersdk.Client, logger s
464467
}),nil
465468
}
466469

467-
funcprintLogo(cmd*cobra.Command) {
470+
// nolint: revive
471+
funcprintLogo(cmd*cobra.Command,spookybool) {
472+
ifspooky {
473+
_,_=fmt.Fprintf(cmd.OutOrStdout(),`
474+
▄████▄ ▒█████ ▓█████▄ ▓█████ ██▀███
475+
▒██▀ ▀█ ▒██▒ ██▒▒██▀ ██▌▓█ ▀ ▓██ ▒ ██▒
476+
▒▓█ ▄ ▒██░ ██▒░██ █▌▒███ ▓██ ░▄█ ▒
477+
▒▓▓▄ ▄██▒▒██ ██░░▓█▄ ▌▒▓█ ▄ ▒██▀▀█▄
478+
▒ ▓███▀ ░░ ████▓▒░░▒████▓ ░▒████▒░██▓ ▒██▒
479+
░ ░▒ ▒ ░░ ▒░▒░▒░ ▒▒▓ ▒ ░░ ▒░ ░░ ▒▓ ░▒▓░
480+
░ ▒ ░ ▒ ▒░ ░ ▒ ▒ ░ ░ ░ ░▒ ░ ▒░
481+
░ ░ ░ ░ ▒ ░ ░ ░ ░ ░░ ░
482+
░ ░ ░ ░ ░ ░ ░ ░
483+
░ ░
484+
485+
`)
486+
return
487+
}
468488
_,_=fmt.Fprintf(cmd.OutOrStdout(),` ▄█▀ ▀█▄
469489
▄▄ ▀▀▀ █▌ ██▀▀█▄ ▐█
470490
▄▄██▀▀█▄▄▄ ██ ██ █▀▀█ ▐█▀▀██ ▄█▀▀█ █▀▀

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp