Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document how to do self-templating #286

Closed
yajo opened this issue Oct 6, 2020 · 2 comments
Closed

Document how to do self-templating #286

yajo opened this issue Oct 6, 2020 · 2 comments
Assignees
Labels
documentation Issue that requires updating docs
Milestone

Comments

@yajo
Copy link
Member

yajo commented Oct 6, 2020

Self-templating templates suffer from a 🐔 and 🥚 problem that disallows them to use a valid copier-answers file. A workaround is documented in copier-org/autopretty#2, but it would be better to improve this.

There seems to be some bug regarding how files/dirs ended with .tmpl override the ones without that extension.

Examples:

  • If my answers file is in .copier-answers.autopretty.upstream.yml and *.upstream.* is in _exclude, then it shouldn't be copied. But since it's my answers file, I need it updated. What to do?
@yajo yajo self-assigned this Oct 6, 2020
@yajo yajo added the bug label Oct 6, 2020
@yajo yajo added this to the v6.0.0 milestone Oct 6, 2020
@yajo yajo added documentation Issue that requires updating docs and removed bug labels Jan 15, 2021
@yajo yajo changed the title Enable easier self-templating Document how to do self-templating Jan 15, 2021
@yajo
Copy link
Member Author

yajo commented Jan 15, 2021

Finally managed to do it. It was as simple as using _subdirectory 🤷🏼‍♂️

See https://github.com/copier-org/autopretty/tree/65aeb34041cbe2281c57be0c04635ed2c61c4c80#notes-for-template-maintainers

Gotta document this.

@yajo
Copy link
Member Author

yajo commented Jul 17, 2021

Fixed in df2a301.

@yajo yajo closed this as completed Jul 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Issue that requires updating docs
Projects
None yet
Development

No branches or pull requests

1 participant