ZORALab / Hestia

One Peaceful Frontend+Backend Software Library Suite.
https://hestia.zoralab.com
Other
19 stars 1 forks source link

Revisit HestiaHUGO User Guide and Experience for Hugo Server Watch List Customization #25

Closed hollowaykeanho closed 1 year ago

hollowaykeanho commented 1 year ago

Description

Please provide a short description of what feature you're looking forward to
enhance below. Please include the story behind your idea as well to give a
better visualization of your idea.

Dated to this issue creation, there is no way to implement a hugo server's watch list customization. Feature request was raised in https://github.com/gohugoio/hugo/issues/10518

Should they have any updates, we will have to revisit this matter and roll updates to hestiaHUGO.

Expected Behavior

Please specify the expected behavior of your requested enhancement. Some great
and helpful pointers are your expected interface (e.g. command patterns,
simple sketches of the user interface, etc).

Hugo developers can either implement or reject such feature. If they reject, we will find our own way.

Current Behavior

Please specify the current behavior (e.g. workaround, blockage, etc).

Guiding user to nudge _index.html or any Hugo server tracking files manually.

Attachment

Please drag and drop the necessary data files (e.g. screenshot, logs, etc)
below.
hollowaykeanho commented 1 year ago

Hugo team leader bep replied on using cascade settings. Testing it now...

hollowaykeanho commented 1 year ago

Solution found:

  1. You need (_default and production) configurations directories.
  2. Name your custom content with watchable and traceable naming prefix but not conflicting with the main bundle file (e.g. _index.html). My recommendation is using double underscore (e.g. __name.extension ).
  3. Define your usual site-level configs in _default/config.toml
  4. Inside your production/config.toml, only add the ignoreFiles field to extend the _default configuration settings during build. If we follow the double underscore naming prefix, the regex value should be:
    ignoreFiles = [
       '(__.*)',
    ]

    This will let Hugo track all the underlying data files during development while not building it into output files in compilation.

hollowaykeanho commented 1 year ago

Tested working for .content.html. Now it is called __content.html data file instead. Committed in: 2fe004e746a8335a93022c2cb96008a7272049ef

hollowaykeanho commented 1 year ago

ported .components.toml in b8a7799521c9b7c8cc83ce8df632d2d63fa037db

hollowaykeanho commented 1 year ago

ported .creators.toml in f7e523c4f75372ca0f112178db90ce1557283409

hollowaykeanho commented 1 year ago

ported .page.toml in 443a124007d441091b00140937512b82de089a4d.

hollowaykeanho commented 1 year ago

ported .js.toml in 8f4b4c2d56fb6f277881aa096b7a722ec7deecc4.

hollowaykeanho commented 1 year ago

ported .languages.toml in 223eda454de6dd6f47d6e9b295098c8da94b7e73.

hollowaykeanho commented 1 year ago

ported .page+ld.json in 7621cd26a4229269524f7f8c56c9c7135ca0edb4

hollowaykeanho commented 1 year ago

ported .caches.toml in d9743f97c866f4d02986d6a7f9b8a0538060d6cf.

hollowaykeanho commented 1 year ago

ported .robots.toml in 8715a101eaa346595e64e015e185adfc8edfca5d.

hollowaykeanho commented 1 year ago

ported .thumbnails.toml in 6c2c2a5d9251690b96eb9fe978f50190b97c5805.

hollowaykeanho commented 1 year ago

ported .twitter.toml in cebd7e0d708b8b808725ca4d4316e566ff659691.

hollowaykeanho commented 1 year ago

ported .wasm.toml in fd9cf4f6446944cd71b990b0c2540a2c9414aad1.

hollowaykeanho commented 1 year ago

ported .data.toml in a132505b8526cb1b7c7ccc12030274584d2b4916.

hollowaykeanho commented 1 year ago

Completed and site is working properly.

hollowaykeanho commented 1 year ago

Released in https://github.com/ZORALab/Hestia/releases/tag/v1.0.0