Skip to content

Instantly share code, notes, and snippets.

@briandominick
Created February 23, 2018 03:24
Show Gist options
  • Save briandominick/6be4f6f01997ea1763b4bcfdb0550310 to your computer and use it in GitHub Desktop.
Save briandominick/6be4f6f01997ea1763b4bcfdb0550310 to your computer and use it in GitHub Desktop.
A programmatically generated narrative of a preconfigured build operation in LiquiDoc.
  1. Copies content/ to _build/, without carrying the parent directory.

  2. Copies theme/ to _build/.

  3. Performs the first round of product-data parsing to build two structurally vital files, sourcing data in data/product.yml.

    1. Builds the page metadata (_build/includes/_built_page-meta.adoc) included in all HTML and PDF exposures of topics, but only relevant as Jekyll page metadata at this time.

    2. Builds the metadata file _build/includes/_built_page-meta.adoc based on the user stories in product.yml, looping over them as directed in _templates/liquid/page-meta.asciidoc. The topics metadata is drawn from this preprocessed file (_build_page-meta.adoc).

  4. Draws data from the `data/meta.yml`and parses it as follows:

    1. Builds _build/includes/_built_company-info.adoc pressed with the template _templates/liquid/company-info.asciidoc.

  5. Draws data from the `data/terms.yml`and parses it as follows:

    1. Builds _build/includes/_built_terms.adoc pressed with the template _templates/liquid/terms.asciidoc, to be included into the 'jargon guide'.

  6. Draws data from the `NOTICE`and parses it as follows:

    1. Builds _build/includes/_built_dependencies_table.adoc pressed with the template _templates/liquid/dependencies.asciidoc, using a regular expression pattern to extract data from the plaintext source file before passing the results to Liquid.

  7. Copies _build/theme to _build/site.

  8. Copies data to _build/.

  9. Draws data from the data/product.yml, to have user-stories content in convenient includes, and parses it as follows:

    1. Builds _build/includes/_built_user-stories-bulleted-by-role.adoc pressed with the template _templates/liquid/user-stories-bulleted-by-role.asciidoc.

    2. Builds _build/includes/_built_user-stories-full.adoc pressed with the template _templates/liquid/user-stories-full.asciidoc.

  10. Draws data from the data/product.yml, to build lists of files to exclude from a given guide’s Jekyll build (otherwise it would grab all our topics/ source files for every guide) , and parses it as follows:

    1. Builds _build/data/excludes-docpro.yml pressed with the template _templates/liquid/excludes-docpro.yaml.

    2. Builds _build/data/excludes-admin.yml pressed with the template _templates/liquid/excludes-admin.yaml.

    3. Builds _build/data/excludes-dev.yml pressed with the template _templates/liquid/excludes-dev.yaml.

  11. Draws data from the `data/meta.yml`and parses it as follows:

    1. Builds _build/data/topnav.yml pressed with the template _templates/liquid/topnav.yaml, the source file for the top navigation bar.

  12. Draws data from the data/product.yml, the source files for the guide-specific sidebars, and parses it as follows:

    1. Builds _build/data/sidebars/docpro.yml pressed with the template _templates/liquid/sidebar-docpro.yaml.

    2. Builds _build/data/sidebars/admin.yml pressed with the template _templates/liquid/sidebar-admin.yaml.

    3. Builds _build/data/sidebars/dev.yml pressed with the template _templates/liquid/sidebar-dev.yaml.

  13. Using the index file _build/portal-index.adoc as a map…​

    1. Calls on Asciidoctor/Prawn to generate a PDF file _build/docs/docpro-guide.pdf.

    2. Uses Jekyll config files:

      • _configs/jekyll-global.yml

      • _configs/jekyll-guides-common.yml

      • _configs/jekyll-guide-1.yml

      • _build/data/excludes-docpro.yml

      to generate a static site at _build/site, the static files for the 'docpro' web portal.

  14. Using the index file _build/portal-index.adoc as a map…​

    1. Calls on Asciidoctor/Prawn to generate a PDF file _build/docs/admin-guide.pdf.

    2. Uses Jekyll config files:

      • _configs/jekyll-global.yml

      • _configs/jekyll-guides-common.yml

      • _configs/jekyll-guide-2.yml

      • _build/data/excludes-admin.yml

      to generate a static site at _build/site.

  15. Using the index file _build/portal-index.adoc as a map…​

    1. Calls on Asciidoctor/Prawn to generate a PDF file _build/docs/dev-guide.pdf.

    2. Uses Jekyll config files:

      • _configs/jekyll-global.yml

      • _configs/jekyll-guides-common.yml

      • _configs/jekyll-guide-3.yml

      • _build/data/excludes-dev.yml

      to generate a static site at _build/site.

  16. Copies _build/theme to _build/site.

  17. Copies _build/assets to _build/site.

  18. Copies _build/docs to _build/site.

  19. Copies content/index.html to _build/site.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment