-
Notifications
You must be signed in to change notification settings - Fork 3
calling from package.json #21
Copy link
Copy link
Open
Labels
questionFurther information is requestedFurther information is requested
Description
I am trying to get reenv to run my graphql introspection command.
I cant seem to call it from the package.json script and then pass the value to the command.
Some of the things I have tried.
This works but I can't seem to get past it:
❯ reenv -e .env printenv REACT_APP_SERVER_URL
http://localhost:4000/graphqlThese doesn't work:
> reenv -e .env get-graphql-schema $REACT_APP_SERVER_URL -j > graphql_schema.json
reenv: unknown option `-j'.❯ reenv -e .env npx get-graphql-schema $REACT_APP_SERVER_URL -j
reenv: unknown option `-j'.
Usage: reenv [OPTION]... COMMAND [ARGS]...
Try `reenv --help' for more information.The examples not using reenv work.
{
"get-schema-url": "reenv -e .env printenv REACT_APP_SERVER_URL",
"get-schema-url-flag": "reenv -e .env -- ls printenv REACT_APP_SERVER_URL",
"get-schema": "ENDPOINT_URL=$(npm run get-schema-url) get-graphql-schema ENDPOINT_URL -j > graphql_schema.json",
"introspection-reenv": "get-graphql-schema $(npm run get-schema-url) -j > graphql_schema.json",
"introspection": "get-graphql-schema http://localhost:4000/graphql -j > graphql_schema.json",
"introspection:gql": "get-graphql-schema http://localhost:4000/graphql > schema.graphql"
},Thank you, sir.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
questionFurther information is requestedFurther information is requested