docs: updated workflows examples and options descriptions (#772) [skip ci]

This commit is contained in:
Simon Lecoq
2022-01-14 04:49:14 +01:00
committed by GitHub
parent 44e3992ca9
commit 4d06539136
80 changed files with 2292 additions and 450 deletions

View File

@@ -2,7 +2,58 @@
Metrics also have general options that impact global metrics rendering.
[➡️ Available options](metadata.yml)
#### ➡️ Available options
<!--options-->
| Option | Type *(format)* **[default]** *{allowed values}* | Description |
| ------ | -------------------------------- | ----------- |
| `token` 🔐 | `token` | GitHub Personal Token |
| `user` | `string` **[]** | GitHub username |
| `repo` | `string` **[]** | GitHub repository |
| `committer_token` 🔐 | `token` **[${{ github.token }}]** | GitHub Token used to commit metrics |
| `committer_branch` | `string` **[]** | Branch used to commit rendered metrics |
| `committer_message` | `string` **[Update ${filename} - [Skip GitHub Action]]** | Commit message |
| `committer_gist` | `string` **[]** | Gist used to store metrics |
| `filename` | `string` **[github-metrics.*]** | Rendered metrics output path |
| `markdown` | `string` **[TEMPLATE.md]** | Rendered markdown output path |
| `markdown_cache` | `string` **[.cache]** | Rendered markdown file cache |
| `output_action` | `string` **[commit]** *{"none", "commit", "pull-request", "pull-request-merge", "pull-request-squash", "pull-request-rebase", "gist"}* | Output action |
| `output_condition` | `string` **[always]** *{"always", "data-changed"}* | Output condition |
| `optimize` | `array` *(comma-separated)* **[css, xml]** *{"css", "xml", "svg"}* | SVG optimization |
| `setup_community_templates` | `array` *(comma-separated,/(?<user>[-a-z0-9]+)[/](?<repo>[-a-z0-9]+)@(?<branch>[-a-z0-9]+):(?<template>[-a-z0-9]+)/)* **[]** | Additional community templates to setup |
| `template` | `string` **[classic]** | Template to use |
| `query` | `json` **[{}]** | Additional query parameters |
| `extras_css` | `string` **[]** | Extra CSS |
| `config_timezone` | `string` **[]** | Timezone used |
| `config_order` | `array` *(comma-separated)* **[]** | Configure content order |
| `config_twemoji` | `boolean` **[no]** | Use twemojis instead of emojis |
| `config_gemoji` | `boolean` **[yes]** | Use GitHub custom emojis |
| `config_display` | `string` **[regular]** *{"regular", "large", "columns"}* | Render display width |
| `config_animations` | `boolean` **[yes]** | SVG CSS animations |
| `config_base64` | `boolean` **[yes]** | Encode images links into base64 data |
| `config_padding` | `string` **[0, 8 + 11%]** | Image padding |
| `config_output` | `string` **[auto]** *{"auto", "svg", "png", "jpeg", "json", "markdown", "markdown-pdf", "insights"}* | Output image format |
| `retries` | `number` **[3]** *{1 ≤ 𝑥 ≤ 10}* | Number of retries |
| `retries_delay` | `number` **[300]** *{0 ≤ 𝑥 ≤ 3600}* | Time to wait (in seconds) before each retry |
| `retries_output_action` | `number` **[5]** *{1 ≤ 𝑥 ≤ 10}* | Number of retries (output action) |
| `retries_delay_output_action` | `number` **[120]** *{0 ≤ 𝑥 ≤ 3600}* | Time to wait (in seconds) before each retry (output action) |
| `plugins_errors_fatal` | `boolean` **[no]** | Die on plugins errors |
| `debug` | `boolean` **[no]** | Debug logs |
| `verify` | `boolean` **[no]** | Verify SVG |
| `debug_flags` | `array` *(space-separated)* **[]** *{"--cakeday", "--hireable", "--halloween", "--error"}* | Debug flags |
| `dryrun` | `boolean` **[no]** | Enable dry-run |
| `experimental_features` | `array` *(space-separated)* **[]** *{"--optimize-svg"}* | Experimental features |
| `use_mocked_data` | `boolean` **[no]** | Use mocked data instead of live APIs |
| `use_prebuilt_image` | `boolean` **[yes]** | Use pre-built image from GitHub registry |
| `delay` | `number` **[0]** *{0 ≤ 𝑥 ≤ 3600}* | Use this to avoid triggering abuse mechanics on large workflows |
Legend for option icons:
* 🔐 Value should be stored in repository secrets
* ✨ New feature currently in testing on `master`/`main`
<!--/options-->
*[→ Full specification](metadata.yml)*
### 🛠️ General configuration