graphql-engine/cli
Kali Vara Purushotham Santhati 489835eb36 cli: metadata apply,export enhancements
- modified the `dry-run` flag of metadata apply command.
- added new flag `o` which takes "json" or "yaml" as parameters for metadata apply command.
- added new flag `o` which takes "json" or "yaml" as parameters for metadata export command. It outputs the metadata from server to stdout in form of  json or yaml and won't change the project's metadata.
- added deprecation warnings for `--from-file` flag
- added info message for describing change of behavior of `--dry-run` flag
- v3 metadata objects like `rest_endpoints` was also added to list of metadata objects in config v2 (fix)
- the order in which metadata objects are appended to metadata objects list matter when using `--dry-run` flag, refactored this order to match server metadata.
- `metadata apply` command can now accept json/yaml metadata from io pipe
- config v3 `metadata apply` didn't show any information to user when applied metadata is inconsistent, this is addressed.
- removed `github.com/ghodss/yaml` dependency from repo
- version metadata object was added twice during intialization (fix)

Co-authored-by: Aravind K P <8335904+scriptonist@users.noreply.github.com>
GitOrigin-RevId: 2316f519eb40645efd86ffee2a85d3c90543ec17
2021-05-14 19:09:59 +00:00
..
build ci: add tests for cli-migrations image (#4396) 2020-04-15 07:26:00 +05:30
cmd/hasura fix typos is multiple files (#728) 2018-10-15 12:29:51 +05:30
commands cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
integration_test cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
internal cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
migrate cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
pkg/console cli: update console assets buckets selection 2021-05-04 12:00:12 +00:00
plugins cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
seed cli: add support for bigquery 2021-04-19 07:06:18 +00:00
telemetry cli: add directory name as an argument to init cmd (#3590) 2019-12-25 14:01:29 +05:30
update cli: update promptui dependency (#51) 2020-11-18 13:36:24 +00:00
util cli: add e2e tests for metadata and migrate commands 2021-04-05 14:01:35 +00:00
version cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
.gitignore cli: merges cli-ext with cli 2021-03-17 15:10:03 +00:00
.realize.yaml cli: update go-binddata, fix realize (close #3588) (#3687) 2020-01-13 15:24:41 +05:30
cli.go cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
CONTRIBUTING.md cli: merges cli-ext with cli 2021-03-17 15:10:03 +00:00
directory.go validate pwd is neither filesystem root nor an existing hasura project 2020-04-27 09:04:32 +05:30
get.sh cli: on m1 macs use darwin/amd64 builds in installation script 2021-05-03 08:00:44 +00:00
global_config.go Fix typo in debug logs 2021-05-11 06:49:28 +00:00
go.mod cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
go.sum cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
logger_hook.go cli: metadata apply,export enhancements 2021-05-14 19:09:59 +00:00
Makefile cli: update console assets buckets selection 2021-05-04 12:00:12 +00:00
README.md cli: misc fixes 2020-11-24 06:12:24 +00:00

Hasura GraphQL Engine CLI

GoDoc

Installation

Download GraphQL Engine CLI bundled with Hasura CLI

  • Linux/macOS
curl -L https://github.com/hasura/graphql-engine/raw/stable/cli/get.sh | bash
  • Windows

Download the binary cli-hasura-windows-amd64.exe available under Assets of the latest release from the GitHub release page: https://github.com/hasura/graphql-engine/releases

Download using go get

go get github.com/hasura/graphql-engine/cli/cmd/hasura

Build from source

git clone https://github.com/hasura/graphql-engine
cd graphql-engine/cli
make deps
make build
# binaries will be in _output directory

Usage

hasura init --directory <my-project> --endpoint <graphql-endpoint> --admin-secret <admin-secret>
cd <my-project>
hasura console

Contributing

Checkout the contributing guide.