Skip to content
This repository has been archived by the owner on May 16, 2021. It is now read-only.

Commit

Permalink
Add Examples to Commands Usage
Browse files Browse the repository at this point in the history
  • Loading branch information
mainawycliffe committed Apr 17, 2020
1 parent 55c3c0a commit be46077
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 5 deletions.
5 changes: 3 additions & 2 deletions cmd/login:ci.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@ import (

// loginCICmd represents the login:ci command
var loginCICmd = &cobra.Command{
Use: "login:ci",
Short: "generate an access token for use in non-interactive environments",
Use: "login:ci",
Short: "generate an access token for use in non-interactive environments",
Example: "kamanda login:ci",
Run: func(cmd *cobra.Command, args []string) {
noLocalhostFlag, _ := cmd.Flags().GetBool("no-localhost")
if !noLocalhostFlag {
Expand Down
5 changes: 3 additions & 2 deletions cmd/logout.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ import (

// logoutCmd represents the logout command
var logoutCmd = &cobra.Command{
Use: "logout",
Short: "Logout kamanda from Firebase",
Use: "logout",
Short: "Logout kamanda from Firebase",
Example: "kamanda logout",
Run: func(cmd *cobra.Command, args []string) {
email := viper.GetString(configs.FirebaseLoggedInUserEmailViperConfigKey)
if !viper.IsSet(configs.FirebaseRefreshTokenViperConfigKey) {
Expand Down
1 change: 1 addition & 0 deletions cmd/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ var versionCmd = &cobra.Command{
Use: "version",
Aliases: []string{"v"},
Short: "Version will output the current build information",
Example: "kamanda version or kamanda version -o json",
Run: func(cmd *cobra.Command, args []string) {
output, err := cmd.Flags().GetString("output")
if err != nil {
Expand Down
9 changes: 8 additions & 1 deletion docs/kamanda_login.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,19 @@ Log kamanda into firebase

### Synopsis

Log kamanda into firebase
This allows Kamanda to administer your Firebase Project.
You can use --no-localhost flag if you are on environment without a browser.

```
kamanda login [flags]
```

### Examples

```
kamanda login
```

### Options

```
Expand Down
6 changes: 6 additions & 0 deletions docs/kamanda_login:ci.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ generate an access token for use in non-interactive environments
kamanda login:ci [flags]
```

### Examples

```
kamanda login:ci
```

### Options

```
Expand Down
6 changes: 6 additions & 0 deletions docs/kamanda_logout.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ Logout kamanda from Firebase
kamanda logout [flags]
```

### Examples

```
kamanda logout
```

### Options

```
Expand Down
6 changes: 6 additions & 0 deletions docs/kamanda_version.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ Version will output the current build information
kamanda version [flags]
```

### Examples

```
kamanda version or kamanda version -o json
```

### Options

```
Expand Down

0 comments on commit be46077

Please sign in to comment.