Merge e9e7c7fe4a into c7d63beba2
				
					
				
			This commit is contained in:
		
						commit
						d3b4ecec38
					
				| 
						 | 
					@ -27,6 +27,7 @@ import (
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const (
 | 
					const (
 | 
				
			||||||
	loginQuietFlag     = "quiet"
 | 
						loginQuietFlag     = "quiet"
 | 
				
			||||||
 | 
						noPrettyFlag       = "no-pretty"
 | 
				
			||||||
	sshHostnameFlag    = "hostname"
 | 
						sshHostnameFlag    = "hostname"
 | 
				
			||||||
	sshDestinationFlag = "destination"
 | 
						sshDestinationFlag = "destination"
 | 
				
			||||||
	sshURLFlag         = "url"
 | 
						sshURLFlag         = "url"
 | 
				
			||||||
| 
						 | 
					@ -97,6 +98,10 @@ func Commands() []*cli.Command {
 | 
				
			||||||
							Aliases: []string{"q"},
 | 
												Aliases: []string{"q"},
 | 
				
			||||||
							Usage:   "do not print the jwt to the command line",
 | 
												Usage:   "do not print the jwt to the command line",
 | 
				
			||||||
						},
 | 
											},
 | 
				
			||||||
 | 
											&cli.BoolFlag{
 | 
				
			||||||
 | 
												Name:  noPrettyFlag,
 | 
				
			||||||
 | 
												Usage: "only print the jwt to the command line",
 | 
				
			||||||
 | 
											},
 | 
				
			||||||
					},
 | 
										},
 | 
				
			||||||
				},
 | 
									},
 | 
				
			||||||
				{
 | 
									{
 | 
				
			||||||
| 
						 | 
					@ -261,7 +266,12 @@ func login(c *cli.Context) error {
 | 
				
			||||||
	if c.Bool(loginQuietFlag) {
 | 
						if c.Bool(loginQuietFlag) {
 | 
				
			||||||
		return nil
 | 
							return nil
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						if c.Bool(noPrettyFlag) {
 | 
				
			||||||
 | 
							fmt.Fprintf(os.Stdout, cfdToken)
 | 
				
			||||||
 | 
						} else {
 | 
				
			||||||
		fmt.Fprintf(os.Stdout, "Successfully fetched your token:\n\n%s\n\n", cfdToken)
 | 
							fmt.Fprintf(os.Stdout, "Successfully fetched your token:\n\n%s\n\n", cfdToken)
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	return nil
 | 
						return nil
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue