aws-amplify / amplify-cli

The AWS Amplify CLI is a toolchain for simplifying serverless web and mobile development.
Apache License 2.0
2.82k stars 820 forks source link

Unnecessary Amplify init on Codegen #2383

Closed borisdering closed 5 years ago

borisdering commented 5 years ago

Which Category is your question related to? Why do I need to init a project when I just want to use the codegen subtooling?

What AWS Services are you utilizing?

Provide additional details e.g. code snippets amplify codegen types --nodownload

nikhname commented 5 years ago

Hi @borisdering, you can use codegen without init by including your schema (named schema.graphl) or instrospection schema (named schema.json) in the root directory of your project and running amplify add codegen. Then, if you want to update your types, save your changes to the schema/introspection schema and run amplify codegen types. The --no-download flag is not needed outside of an amplify project.

For more about this flow, take a look at flow 5 in the docs for this workflow: https://aws-amplify.github.io/docs/cli-toolchain/graphql#workflows

github-actions[bot] commented 3 years ago

This issue has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs.

Looking for a help forum? We recommend joining the Amplify Community Discord server *-help channels for those types of questions.