Skip to content

A way to replace/override files in the InputTreeBuilder? #253

Answered by jenshalm
armanbilge asked this question in Q&A
Discussion options

You must be logged in to vote

I'd recommend not to pre-populate laikaInputs in any way. The reason is that it is kind of reserved for "user land". Even if we'd find a way to make it work for the base case (one plugin overriding another), it would still break for users who browse the Laika docs and find out that they can put a default template into the root directory. They would still get a duplicate path error and this is intentional (to avoid silent errors or non-determinism when users define ambiguous inputs).

The more natural way to pre-populate something in a library or plugin would be to package it as a theme. This way anything added in user land automatically does obtain the override semantics. It's also less er…

Replies: 1 comment 7 replies

Comment options

You must be logged in to vote
7 replies
@jenshalm
Comment options

@armanbilge
Comment options

armanbilge Feb 6, 2022
Maintainer Author

@jenshalm
Comment options

@jenshalm
Comment options

@armanbilge
Comment options

armanbilge Feb 6, 2022
Maintainer Author

Answer selected by armanbilge
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants