Skip to content

Commit

Permalink
updated docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Mrinal Wahal committed Oct 21, 2021
1 parent 7ae5ce2 commit c5a38ee
Show file tree
Hide file tree
Showing 28 changed files with 239 additions and 380 deletions.
2 changes: 1 addition & 1 deletion cmd/dev.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ var (
// devCmd represents the dev command
var devCmd = &cobra.Command{
Use: "dev [-p port]",
Aliases: []string{"d", "start", "up"},
Aliases: []string{"start", "up"},
Short: "Start local development environment",
Long: `Initialize a local Nhost environment for development and testing.`,
Run: func(cmd *cobra.Command, args []string) {
Expand Down
7 changes: 4 additions & 3 deletions cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ func Execute() {
}

// un-comment the following to auto-generate documentation
// generateDocumentation()
// generateDocumentation()

}

Expand All @@ -135,21 +135,22 @@ func generateDocumentation() {
}

func init() {

cobra.OnInitialize(initConfig)

// Here you will define your flags and configuration settings.
// Cobra supports persistent flags, which, if defined here,
// will be global for your application.

rootCmd.PersistentFlags().StringVar(&cfgFile, "config", "", "config file (default is $HOME/.nhost.yaml)")
// rootCmd.PersistentFlags().StringVar(&cfgFile, "config", "", "config file (default is $HOME/.nhost.yaml)")

rootCmd.PersistentFlags().BoolVarP(&logger.JSON, "json", "j", false, "Print JSON formatted logs")
rootCmd.PersistentFlags().StringVar(&nhost.API, "endpoint", "https://nuno.nhost.dev/v1/functions", "Auth endpoint - for internal testing")
//rootCmd.PersistentFlags().StringVarP(&userLicense, "license", "l", "", "name of license for the project")
//rootCmd.PersistentFlags().Bool("viper", true, "use Viper for configuration")
//viper.BindPFlag("author", rootCmd.PersistentFlags().Lookup("author"))
//viper.BindPFlag("useViper", rootCmd.PersistentFlags().Lookup("viper"))
viper.SetDefault("author", "Mrinal Wahal mrinalwahal@gmail.com")
viper.SetDefault("author", "Mrinal Wahal wahal@nhost.io")
viper.SetDefault("license", "MIT")

//rootCmd.AddCommand(versionCmd)
Expand Down
52 changes: 52 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
## nhost

Open Source Firebase Alternative with GraphQL

### Synopsis


_ ____ __
/ | / / /_ ____ _____/ /_
/ |/ / __ \/ __ \/ ___/ __/
/ /| / / / / /_/ (__ ) /_
/_/ |_/_/ /_/\____/____/\__/
Nhost.io is a full-fledged serverless backend for Jamstack and client-serverless applications.
Version -
Documentation - https://docs.nhost.io


```
nhost [flags]
```

### Options

```
--config string config file (default is $HOME/.nhost.yaml)
-d, --debug Show debugging level logs
--endpoint string Auth endpoint - for internal testing (default "https://nuno.nhost.dev/v1/functions")
-h, --help help for nhost
-j, --json Print JSON formatted logs
-f, --log-file string Write logs to given file
```

### SEE ALSO

* [nhost dev](nhost_dev.md) - Start local development environment
* [nhost env](nhost_env.md) - Manage your Nhost env vars
* [nhost execute](nhost_execute.md) - Execute commands inside your Nhost containers
* [nhost init](nhost_init.md) - Initialize current directory as Nhost app
* [nhost link](nhost_link.md) - Link local app to a remote one
* [nhost list](nhost_list.md) - List remote apps
* [nhost login](nhost_login.md) - Log in to your Nhost account
* [nhost logout](nhost_logout.md) - Log out from your Nhost account
* [nhost logs](nhost_logs.md) - Read container logs of any service
* [nhost purge](nhost_purge.md) - Delete all containers created by `nhost dev`
* [nhost support](nhost_support.md) - Reach out to us
* [nhost uninstall](nhost_uninstall.md) - Remove the installed CLI from system permanently
* [nhost upgrade](nhost_upgrade.md) - Upgrade this version of Nhost CLI to latest version
* [nhost version](nhost_version.md) - Show the current version of Nhost CLI you have installed

###### Auto generated by spf13/cobra on 22-Oct-2021
59 changes: 0 additions & 59 deletions docs/nhost.md

This file was deleted.

10 changes: 6 additions & 4 deletions docs/nhost_dev.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,28 @@ Start local development environment
Initialize a local Nhost environment for development and testing.

```
nhost dev [flags]
nhost dev [-p port] [flags]
```

### Options

```
-h, --help help for dev
-h, --help help for dev
-p, --port string Port for dev proxy (default "1337")
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.nhost.yaml)
-d, --debug Show debugging level logs
--endpoint string Auth endpoint - for internal testing (default "https://nuno.nhost.dev/v1/functions")
-j, --json Print JSON formatted logs
-l, --log-file string Write logs to given file
-f, --log-file string Write logs to given file
```

### SEE ALSO

* [nhost](nhost.md) - Open Source Firebase Alternative with GraphQL

###### Auto generated by spf13/cobra on 19-Jun-2021
###### Auto generated by spf13/cobra on 22-Oct-2021
32 changes: 0 additions & 32 deletions docs/nhost_down.md

This file was deleted.

18 changes: 5 additions & 13 deletions docs/nhost_env.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,6 @@
## nhost env

Handle your Nhost env vars

### Synopsis

A longer description that spans multiple lines and likely contains examples
and usage of using your command. For example:

Cobra is a CLI library for Go that empowers applications.
This application is a tool to generate the needed files
to quickly create a Cobra application.
Manage your Nhost env vars

### Options

Expand All @@ -22,14 +13,15 @@ to quickly create a Cobra application.
```
--config string config file (default is $HOME/.nhost.yaml)
-d, --debug Show debugging level logs
--endpoint string Auth endpoint - for internal testing (default "https://nuno.nhost.dev/v1/functions")
-j, --json Print JSON formatted logs
-l, --log-file string Write logs to given file
-f, --log-file string Write logs to given file
```

### SEE ALSO

* [nhost](nhost.md) - Open Source Firebase Alternative with GraphQL
* [nhost env ls](nhost_env_ls.md) - Fetch env vars from remote
* [nhost env list](nhost_env_list.md) - Fetch env vars from remote
* [nhost env pull](nhost_env_pull.md) - Sync env vars from remote with local env

###### Auto generated by spf13/cobra on 19-Jun-2021
###### Auto generated by spf13/cobra on 22-Oct-2021
13 changes: 7 additions & 6 deletions docs/nhost_env_ls.md → docs/nhost_env_list.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## nhost env ls
## nhost env list

Fetch env vars from remote

Expand All @@ -7,26 +7,27 @@ Fetch env vars from remote
List your environment variables stored on remote.

```
nhost env ls [flags]
nhost env list [flags]
```

### Options

```
-h, --help help for ls
-h, --help help for list
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.nhost.yaml)
-d, --debug Show debugging level logs
--endpoint string Auth endpoint - for internal testing (default "https://nuno.nhost.dev/v1/functions")
-j, --json Print JSON formatted logs
-l, --log-file string Write logs to given file
-f, --log-file string Write logs to given file
```

### SEE ALSO

* [nhost env](nhost_env.md) - Handle your Nhost env vars
* [nhost env](nhost_env.md) - Manage your Nhost env vars

###### Auto generated by spf13/cobra on 19-Jun-2021
###### Auto generated by spf13/cobra on 22-Oct-2021
7 changes: 4 additions & 3 deletions docs/nhost_env_pull.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,13 @@ nhost env pull [flags]
```
--config string config file (default is $HOME/.nhost.yaml)
-d, --debug Show debugging level logs
--endpoint string Auth endpoint - for internal testing (default "https://nuno.nhost.dev/v1/functions")
-j, --json Print JSON formatted logs
-l, --log-file string Write logs to given file
-f, --log-file string Write logs to given file
```

### SEE ALSO

* [nhost env](nhost_env.md) - Handle your Nhost env vars
* [nhost env](nhost_env.md) - Manage your Nhost env vars

###### Auto generated by spf13/cobra on 19-Jun-2021
###### Auto generated by spf13/cobra on 22-Oct-2021
36 changes: 36 additions & 0 deletions docs/nhost_execute.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
## nhost execute

Execute commands inside your Nhost containers

### Synopsis

Run shell commands directly inside your
already running Nhost service containers.

```
nhost execute [flags]
```

### Options

```
-c, --command string Command to run inside service
-h, --help help for execute
-s, --service string Service to run the command inside
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.nhost.yaml)
-d, --debug Show debugging level logs
--endpoint string Auth endpoint - for internal testing (default "https://nuno.nhost.dev/v1/functions")
-j, --json Print JSON formatted logs
-f, --log-file string Write logs to given file
```

### SEE ALSO

* [nhost](nhost.md) - Open Source Firebase Alternative with GraphQL

###### Auto generated by spf13/cobra on 22-Oct-2021
33 changes: 0 additions & 33 deletions docs/nhost_health.md

This file was deleted.

Loading

0 comments on commit c5a38ee

Please sign in to comment.