-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
48 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
## Dev Setup instructions | ||
|
||
1. [Setup go](https://golang.org/doc/install) | ||
2. Clone this repo: `git clone [email protected]:auth0/auth0-cli` | ||
3. `make test` - ensure everything works correctly. Should see things pass. | ||
|
||
## Build and run on native platform | ||
|
||
From the top-level directory: | ||
``` | ||
$ make build | ||
$ ./auth0 --help | ||
``` | ||
|
||
## Adding a new command | ||
|
||
This part is not fully fleshed out yet, but here are the steps: | ||
|
||
1. Create a command (example: https://github.com/auth0/auth0-cli/blob/main/internal/cli/login.go) | ||
2. Add the command constructor to the root command: (e.g. somewhere here: https://github.com/auth0/auth0-cli/blob/main/internal/cli/root.go) | ||
|
||
Test it out by doing: | ||
|
||
``` | ||
go run ./cmd/auth0 <your command> | ||
``` | ||
|
||
## Adding a new go dependency | ||
|
||
If you have to add another go dependency, you can follow the steps: | ||
|
||
1. `go get -u github.com/some/path/to/lib` | ||
2. Import the library you need in the relevant file. (This step is necessary, so | ||
the next steps informs `go mod` that this dependency is actually used). | ||
3. go mod tidy | ||
4. go mod vendor | ||
|
||
We use vendoring, so the last step is required. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,14 @@ | ||
# auth0-cli | ||
# Auth0 CLI | ||
|
||
## What? | ||
`auth0` is the command line to supercharge your development workflow. | ||
|
||
The goal is to build a fully fleshed out product, similar to the Heroku CLI, | ||
Stripe CLI, etc. | ||
Build, test, and manage your integration with **[Auth0](http://auth0.com/)** directly from your **terminal**. | ||
|
||
## Why now? | ||
![demo](./demo.gif) | ||
|
||
- It would also allow MVP products to be shipped faster. | ||
- For actions, delivering a CLI experience would be far ideal than having | ||
developers write code in the browser. | ||
|
||
## Installation | ||
|
||
### macOS | ||
1. Download the binaries from: https://github.com/auth0/auth0-cli/releases/latest/ | ||
1. Extract | ||
|
@@ -23,45 +20,11 @@ Stripe CLI, etc. | |
|
||
> see more completion options: `auth0 completion -h` | ||
## Dev Setup instructions | ||
|
||
1. [Setup go](https://golang.org/doc/install) | ||
2. Clone this repo: `git clone [email protected]:auth0/auth0-cli` | ||
3. `make test` - ensure everything works correctly. Should see things pass. | ||
|
||
## Build and run on native platform | ||
|
||
From the top-level directory: | ||
``` | ||
$ make build | ||
$ ./auth0 --help | ||
``` | ||
|
||
## Adding a new command | ||
|
||
This part is not fully fleshed out yet, but here are the steps: | ||
|
||
1. Create a command (example: https://github.com/auth0/auth0-cli/blob/main/internal/cli/login.go) | ||
2. Add the command constructor to the root command: (e.g. somewhere here: https://github.com/auth0/auth0-cli/blob/main/internal/cli/root.go) | ||
|
||
Test it out by doing: | ||
|
||
``` | ||
go run ./cmd/auth0 <your command> | ||
``` | ||
|
||
## Adding a new go dependency | ||
|
||
If you have to add another go dependency, you can follow the steps: | ||
## Contributing | ||
|
||
1. `go get -u github.com/some/path/to/lib` | ||
2. Import the library you need in the relevant file. (This step is necessary, so | ||
the next steps informs `go mod` that this dependency is actually used). | ||
3. go mod tidy | ||
4. go mod vendor | ||
Please check the [contributing guidelines](CONTRIBUTING.md). | ||
|
||
We use vendoring, so the last step is required. | ||
|
||
## References | ||
## Author | ||
|
||
https://auth0team.atlassian.net/wiki/spaces/eco/pages/1050510482/actions%3A+CLI+sketch | ||
[Auth0](https://auth0.com) |