Currently, the tailcall init command is not optimized for reinitializing a Tailcall project after updating the Tailcall version. This process can be made more seamless with the following enhancements:
Auto-detection of Configuration Format:
When reinitializing a project, the command should automatically detect the configuration format (GraphQL/YAML) based on existing files in the folder (e.g., .tailcallrc.graphql or .tailcallrc.yaml).
Only prompt the user to choose a format if no configuration file is detected.
Example Improvement:
Instead of showing:
Automatically infer the format from the existing file.
Skip Confirmation for Overwriting .tailcallrc:
Overwriting the .tailcallrc file should not require user confirmation, as it is mandatory for IDEs to understand the Tailcall configuration.
Current Behavior: Proposed Change: Automatically overwrite the file without prompting.
Skip Overwriting main.graphql:
Reinitializing should not overwrite main.graphql
Current Behavior:
main.graphql already exists. Overwrite? (y/n)
Proposed Change: don't overwrite main.graphql.
These changes will improve the developer experience by reducing unnecessary steps and making the tailcall init command more intuitive during reinitialization.
Steps to Reproduce Current Behavior:
Run tailcall init in an existing Tailcall project directory.
Observe the prompts for configuration format and confirmation to overwrite files.
Description:
Currently, the
tailcall init
command is not optimized for reinitializing a Tailcall project after updating the Tailcall version. This process can be made more seamless with the following enhancements:Auto-detection of Configuration Format:
.tailcallrc.graphql
or.tailcallrc.yaml
).Example Improvement:
Instead of showing:
Automatically infer the format from the existing file.
Skip Confirmation for Overwriting
.tailcallrc
:.tailcallrc
file should not require user confirmation, as it is mandatory for IDEs to understand the Tailcall configuration.Current Behavior:
Proposed Change: Automatically overwrite the file without prompting.
Skip Overwriting
main.graphql
:main.graphql
Current Behavior:
Proposed Change: don't overwrite main.graphql.
These changes will improve the developer experience by reducing unnecessary steps and making the
tailcall init
command more intuitive during reinitialization.Steps to Reproduce Current Behavior:
tailcall init
in an existing Tailcall project directory.