Closed mackoj closed 7 years ago
Hey @mackoj All the templates shipped with Sourcery are currently listed in the docs in Example section.
@ilyapuchka let's maybe update the title for the section from Example
to Bundled Templates
? I could submit a PR for it, if makes sense.
I mean from other source like this one for example https://github.com/AliSoftware/SourceryTemplates .
@mackoj I think we can add this in a similar way like here https://github.com/SwiftGen/SwiftGen#attributions
As @AliSoftware mentions here we need to develop contribution guidelines for contributing templates. It may contain requirements for templates description and documentation, tests and so on. Then we can accept new templates as PRs. I also think there is no need for all of them being listed in the Sourcery docs, because there they serve more as a reference. I think it will make sense to separate templates to a dedicated repo and setup some simple github.io page for it.
I think having contributions guidelines for contributions templates is clearly the good way to go. It's more important to have quality templates than having a lot of them. But I think they should be in Sourcery repo for discovery purpose.
@mackoj I don't think that idea to keep them separated - bad idea. I see the only drawback, that currently templates are developed with the Sourcery version from master
branch, not from Releases
. So for example when I added the tests for templates they were updated with new Stencil features, which were not available in the 0.6.0
release. And so the developer can download the template and it won't compile unless developer also uses Sourcery complied from master
.
There should be a reference to particular minimum version of Sourcery that is supported. We might do something like what fastlane does whit putting minimum version in fastfile, using special annotation for that in templates, but that might be an over-complication.
It's would be great to have a list/directory/repo of all available Sourcery Template available ?