Skip to content

Commit

Permalink
Update CLI docs (#402)
Browse files Browse the repository at this point in the history
  • Loading branch information
vazexqi committed Jul 17, 2024
1 parent 1eacabc commit de03ee2
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 15 deletions.
8 changes: 5 additions & 3 deletions docs/cli/authentication.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,12 @@ The Zuplo CLI, `zup`, uses API Keys to authenticate. You can find your API Key
by following these steps:

1. Navigate to [portal.zuplo.com](https://portal.zuplo.com) and log in.
2. Select the project that you want to work on.
3. Click on the "Settings" tab and navigate to the "Zuplo API Keys" section.
2. Select the account that you want to work on.
3. Click on the "Settings" tab and navigate to the "API Keys" section. Select an
existing API Key or create a new one to use with the CLI.

All commands take an `--api-key` argument. For example, to list your zups, run:
Most commands take an `--api-key` argument. For example, to list your available
Zuplo API Gateways, run:

```bash
zup list --api-key zpka_d67b7e241bb948758f415b79aa8exxxx_2efbxxxx
Expand Down
8 changes: 4 additions & 4 deletions docs/cli/convert.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ zup convert
Converts routes.json to routes.oas.json
```

Use this command to convert your old routes.json to the new routes.oas.json,
which is based on OpenAPI 3.x.x. Run this command from the root of your Zuplo
project. It will search for a config/routes.json and generate a
config/routes.oas.json from it.
If you have an older Zuplo project, use this command to convert your old
routes.json to the new routes.oas.json, which is based on OpenAPI 3.x.x. Run
this command from the root of your Zuplo project. It will search for a
config/routes.json and generate a config/routes.oas.json from it.
6 changes: 4 additions & 2 deletions docs/cli/deployments.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,20 +29,22 @@ an argument or through the `ZUPLO_API_KEY` environment variable.

```bash
# The following will use the current Git branch as the name of the environment

git checkout -b my-new-branch
zup deploy
```

```bash
# If you do not wish to use the current Git branch as the name of the
# environment, you can specify one using --environment

zup deploy --environment my-env-name
```

```bash
# If you have configured your remote origin differently from portal.zuplo.com,
# you can still force it to deploy. Be aware that this could make merging changes impossible if the remote do not share a common ancestor.
git remote -v
# you can still force it to deploy. Be aware that this could make merging
# changes impossible if the remote do not share a common ancestor.

zup deploy --no-verify-remote
```
5 changes: 4 additions & 1 deletion docs/cli/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,11 @@ Node.js 18.0.0.

1. Install Node.js 18.0.0 or later. You can download it from
[nodejs.org](https://nodejs.org/en/download/).
1. Install the Zuplo CLI by running the following command:
1. Install the Zuplo CLI globally by running the following command:

```bash
npm install -g @zuplo/cli
```

1. After installing the CLI, you can use the `zup` command to interact with
Zuplo.
3 changes: 1 addition & 2 deletions docs/cli/project.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ zup project
Project commands

Commands:
zup project update Updates your project structure to the latest
conventions
zup project update Updates your project structure to the latest conventions
zup project import-openapi Imports an OpenAPI file into your Zuplo Project

```
Expand Down
5 changes: 2 additions & 3 deletions docs/cli/test.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ You can find more sample tests
Once you have written your tests, you can run them using the `test` command.

```bash
zup test --endpoint https:/your-zup.example.com
zup test --endpoint https://your-zup.example.com
```

## Environment Variables
Expand Down Expand Up @@ -108,5 +108,4 @@ time you run the tests.

## Tips for writing tests

Look for more testing tips
[here](../articles/testing.md#tips-for-writing-tests).
Look for more testing tips [here](../articles/testing#tips-for-writing-tests).

0 comments on commit de03ee2

Please sign in to comment.