graphql-platform icon indicating copy to clipboard operation
graphql-platform copied to clipboard

StrawBerry Shake Templates

Open PascalSenn opened this issue 3 years ago • 1 comments

Is your feature request related to a problem?

Currently we do not have a template for StrawBerry Shake.

I would be nice to just create a folder in a existing solution, navigate into it and run dotnet new graphql-client --endpoint https://thegraphqlserver.com/graphql.

Executing the initial fetch can be difficult, there are post actions to run a script, but this script would have to run on Windwos and Unix.

This could solve the issue: https://github.com/dotnet/templating/issues/2942

The solution you'd like

  1. Add a template graphql-client
  2. When dotnet new graphql-client --endpoint https://thegraphqlserver.com/graphql is executed it installs the tooling and creates a new classlib.
  3. The schema is fetched from the endpoint
  4. A query file is added to the project
query Example {
    example: __typename
}

Note to potential contributors

If someone wants to pick this up, we could already have a strawberry shake template, and generate a init.sh and init.cmd file that does the initialization.

It is also possible to print "manual instructions" on the screen. So if we cannot execute the script, we could just show the user how to execute it.

Product

Strawberry Shake

PascalSenn avatar Apr 24 '22 22:04 PascalSenn

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jun 24 '22 15:06 stale[bot]