-
Notifications
You must be signed in to change notification settings - Fork 18
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
How to build an output directory structure different from the source directory structure? #63
Comments
I am almost there with the following hook:
However, if a page is in form of a leaf dir, i.e., Is there a way to also copy the assets to the modified target path? |
Hi Jayesh, It looks like I didn't really consider how the target dir override would compose with assets in leaf directories... Right now, assets are processed very early, before any pages. Which means hooks would have no chance to influence that process in any way. My original reasoning was that when I get to parallelizing the build process, that part could be delegated to a separate worker thread. But it clearly doesn't compose with the fact that the target path can be modified by a hook. I'll look how I could make it work correctly. One idea is to move asset processing after pages, store asset file paths in a hash instead of a list and insert target paths generated by hooks in the entries. I hope I'll experiment with that over the weekend. |
Another thing to keep in mind is to fix the reference to a modified target_file if it is crosslinked in some other page. |
The soupault manual says in overview:
Is it possible to define an arbitrary structure different from the source structure?
I wish to map as follows:
site/yyyy-mm-dd-on-reading-book.md
->build/on-reading-book/index.html
site/yyyy-mm-dd-on-guix/{.leaf,index.md,asset.png}
->build/on-guix/{.leaf,index.html,asset.png}
Is anything like this possible?
The text was updated successfully, but these errors were encountered: