From 23f59f4153b4dd06fe601477c1d5445c700f3e92 Mon Sep 17 00:00:00 2001 From: Malathi Date: Tue, 8 Sep 2020 23:38:17 +0530 Subject: [PATCH] Docs: Use data file(s) to render table(s) at https://jekyllrb.com/docs/configuration/options/ (#8380) Merge pull request 8380 --- docs/_data/config_options.yml | 146 ++++++++++++ docs/_docs/configuration/options.md | 354 ++++------------------------ 2 files changed, 196 insertions(+), 304 deletions(-) diff --git a/docs/_data/config_options.yml b/docs/_data/config_options.yml index a2430caf..5bc8330d 100644 --- a/docs/_data/config_options.yml +++ b/docs/_data/config_options.yml @@ -35,3 +35,149 @@ global: - name: Encoding description: "Set the encoding of files by name (only available for Ruby 1.9 or later). The default value is utf-8 starting in 2.0.0, and nil before 2.0.0, which will yield the Ruby default of ASCII-8BIT. Available encodings can be shown by the command ruby -e 'puts Encoding::list.join(\"\\n\")'." option: "encoding: ENCODING" +build: +- name: Regeneration + description: Enable auto-regeneration of the site when files are modified. + flag: -w, --[no-]watch +- name: Configuration + description: >- + Specify config files instead of using _config.yml automatically. + Settings in later files override settings in earlier files. + flag: --config FILE1[,FILE2,...] +- name: Plugins + description: >- + Specify plugin directories instead of using _plugins/ automatically. + option: "plugins_dir: [ DIR1,... ]" + flag: -p, --plugins DIR1[,DIR2,...] +- name: Layouts + description: >- + Specify layout directory instead of using _layouts/ automatically. + option: "layout_dir: DIR" + flag: --layouts DIR +- name: Drafts + description: Process and render draft posts. + option: "show_drafts: BOOL" + flag: -D, --drafts +- name: Environment + description: Use a specific environment value in the build. + flag: JEKYLL_ENV=production +- name: Future + description: Publish posts or collection documents with a future date. + option: "future: BOOL" + flag: --future +- name: Unpublished + description: Render posts that were marked as unpublished. + option: "unpublished: BOOL" + flag: --unpublished +- name: LSI + description: >- + Produce an index for related posts. Requires the + classifier-reborn plugin. + option: "lsi: BOOL" + flag: --lsi +- name: Limit Posts + description: Limit the number of posts to parse and publish. + option: "limit_posts: NUM" + flag: --limit_posts NUM +- name: Force polling + description: Force watch to use polling. + option: "force_polling: BOOL" + flag: --force_polling +- name: Verbose output + description: Print verbose output. + flag: -V, --verbose +- name: Silence Output + description: Silence the normal output from Jekyll during a build. + flag: -q, --quiet +- name: Incremental build + description: >- + Enable the experimental incremental build feature. Incremental build only + re-builds posts and pages that have changed, resulting in significant performance + improvements for large sites, but may also break site generation in certain + cases. + option: "incremental: BOOL" + flag: -I, --incremental +- name: Liquid profiler + description: Generate a Liquid rendering profile to help you identify performance bottlenecks. + option: "profile: BOOL" + flag: --profile +- name: Strict Front Matter + description: Cause a build to fail if there is a YAML syntax error in a page's front matter. + option: "strict_front_matter: BOOL" + flag: --strict_front_matter +- name: Base URL + description: Serve the website from the given base URL. + option: "baseurl: URL" + flag: -b, --baseurl URL +- name: Trace + description: Show the full backtrace when an error occurs. + flag: -t, --trace +serve: +- name: Local Server Port + description: Listen on the given port. + option: + - "port: PORT" + flag: + - -P, --port PORT +- name: Local Server Hostname + description: Listen at the given hostname. + option: + - "host: HOSTNAME" + flag: + - -H, --host HOSTNAME +- name: Live Reload + description: Reload a page automatically on the browser when its content is edited. + option: + - "livereload: BOOL" + flag: + - -l, --livereload +- name: Live Reload Ignore + description: File glob patterns for LiveReload to ignore. + option: + - "livereload_ignore: [ GLOB1,... ]" + flag: + - --livereload-ignore GLOB1[,GLOB2,...] +- name: Live Reload Min/Max Delay + description: Minimum/Maximum delay before automatically reloading page. + option: + - "livereload_min_delay: SECONDS" + - "livereload_max_delay: SECONDS" + flag: + - --livereload-min-delay SECONDS + - --livereload-max-delay SECONDS +- name: Live Reload Port + description: Port for LiveReload to listen on. + flag: + - --livereload-port PORT +- name: Open URL + description: Open the site's URL in the browser. + option: + - "open_url: BOOL" + flag: + - -o, --open-url +- name: Detach + description: Detach the server from the terminal. + option: + - "detach: BOOL" + flag: + - -B, --detach +- name: Skips the initial site build + description: Skips the initial site build which occurs before the server is started. + option: + - "skip_initial_build: BOOL" + flag: + - --skip-initial-build +- name: Show Directory Listing + description: Show a directory listing instead of loading your index file. + option: + - "show_dir_listing: BOOL" + flag: + - --show-dir-listing +- name: X.509 (SSL) Private Key + description: SSL Private Key, stored or symlinked in the site source. + flag: + - --ssl-key +- name: X.509 (SSL) Certificate + description: SSL Public certificate, stored or symlinked in the site source. + flag: + - --ssl-cert diff --git a/docs/_docs/configuration/options.md b/docs/_docs/configuration/options.md index 42dfd4bc..4206c221 100644 --- a/docs/_docs/configuration/options.md +++ b/docs/_docs/configuration/options.md @@ -80,191 +80,27 @@ class="flag">flags (specified on the command-line) that control them. - - -

Regeneration

-

Enable auto-regeneration of the site when files are modified.

- - -

-w, --[no-]watch

- - - - -

Configuration

-

Specify config files instead of using _config.yml automatically. Settings in later files override settings in earlier files.

- - -

--config FILE1[,FILE2,...]

- - - - -

Plugins

-

Specify plugin directories instead of using _plugins/ automatically.

- - -

plugins_dir: [ DIR1,... ]

-

-p, --plugins DIR1[,DIR2,...]

- - - - -

Layouts

-

Specify layout directory instead of using _layouts/ automatically.

- - -

layout_dir: DIR

-

--layouts DIR

- - - - -

Drafts

-

Process and render draft posts.

- - -

show_drafts: BOOL

-

-D, --drafts

- - - - -

Environment

-

Use a specific environment value in the build.

- - -

JEKYLL_ENV=production

- - - - -

Future

-

Publish posts or collection documents with a future date.

- - -

future: BOOL

-

--future

- - - - -

Unpublished

-

Render posts that were marked as unpublished.

- - -

unpublished: BOOL

-

--unpublished

- - - - -

LSI

-

Produce an index for related posts. Requires the - classifier-reborn plugin.

- - -

lsi: BOOL

-

--lsi

- - - - -

Limit Posts

-

Limit the number of posts to parse and publish.

- - -

limit_posts: NUM

-

--limit_posts NUM

- - - - -

Force polling

-

Force watch to use polling.

- - -

force_polling: BOOL

-

--force_polling

- - - - -

Verbose output

-

Print verbose output.

- - -

-V, --verbose

- - - - -

Silence Output

-

Silence the normal output from Jekyll - during a build

- - -

-q, --quiet

- - - - -

Incremental build

-

- Enable the experimental incremental build feature. Incremental build only - re-builds posts and pages that have changed, resulting in significant performance - improvements for large sites, but may also break site generation in certain - cases. -

- - -

incremental: BOOL

-

-I, --incremental

- - - - -

Liquid profiler

-

- Generate a Liquid rendering profile to help you identify performance bottlenecks. -

- - -

profile: BOOL

-

--profile

- - - - -

Strict Front Matter

-

- Cause a build to fail if there is a YAML syntax error in a page's front matter. -

- - -

strict_front_matter: BOOL

-

--strict_front_matter

- - - - -

Base URL

-

Serve the website from the given base URL.

- - -

baseurl: URL

-

-b, --baseurl URL

- - - - -

Trace

-

Show the full backtrace when an error occurs.

- - -

-t, --trace

- - + {% for setting in site.data.config_options.build %} + + +

+ {{ setting.name }} + {% if setting.version-badge %} + {{ setting.version-badge }} + {% endif %} +

+

{{ setting.description }}

+ + + {% if setting.option %} +

{{ setting.option }}

+ {% endif %} + {% if setting.flag %} +

{{ setting.flag }}

+ {% endif %} + + + {% endfor %} @@ -284,125 +120,35 @@ before your site is served. - - -

Local Server Port

-

Listen on the given port.

- - -

port: PORT

-

-P, --port PORT

- - - - -

Local Server Hostname

-

Listen at the given hostname.

- - -

host: HOSTNAME

-

-H, --host HOSTNAME

- - - - -

Live Reload

-

Reload a page automatically on the browser when its content is edited.

- - -

livereload: BOOL

-

-l, --livereload

- - - - -

Live Reload Ignore

-

File glob patterns for LiveReload to ignore.

- - -

livereload_ignore: [ GLOB1,... ]

-

--livereload-ignore GLOB1[,GLOB2,...]

- - - - -

Live Reload Min/Max Delay

-

Minimum/Maximum delay before automatically reloading page.

- - -

livereload_min_delay: SECONDS
- livereload_max_delay: SECONDS

-

--livereload-min-delay SECONDS
- --livereload-max-delay SECONDS

- - - - -

Live Reload Port

-

Port for LiveReload to listen on.

- - -

--livereload-port PORT

- - - - -

Open URL

-

Open the site's URL in the browser.

- - -

open_url: BOOL

-

-o, --open-url

- - - - -

Detach

-

Detach the server from the terminal.

- - -

detach: BOOL

-

-B, --detach

- - - - -

Skips the initial site build

-

Skips the initial site build which occurs before the server is started.

- - -

skip_initial_build: BOOL

-

--skip-initial-build

- - - - -

Show Directory Listing

-

Show a directory listing instead of loading your index file.

- - -

show_dir_listing: BOOL

-

--show-dir-listing

- - - - -

X.509 (SSL) Private Key

-

SSL Private Key, stored or symlinked in the site source.

- - -

--ssl-key

- - - - -

X.509 (SSL) Certificate

-

SSL Public certificate, stored or symlinked in the site source.

- - -

--ssl-cert

- - + {% for setting in site.data.config_options.serve %} + + +

+ {{ setting.name }} + {% if setting.version-badge %} + {{ setting.version-badge }} + {% endif %} +

+

{{ setting.description }}

+ + + {% if setting.option %} +

+ {% for option in setting.option %} + {{ option }}
+ {% endfor %} +

+ {% endif %} + {% if setting.flag %} +

+ {% for flag in setting.flag %} + {{ flag }}
+ {% endfor %} +

+ {% endif %} + + + {% endfor %}