Skip to content

Commit

Permalink
docs: Tidy up tables
Browse files Browse the repository at this point in the history
  • Loading branch information
twpayne committed Feb 21, 2023
1 parent b9fae1f commit 461b175
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,23 +22,23 @@ Entries may have the following fields:
| Variable | Type | Default value | Description |
| ----------------- | -------- | ------------- | ------------------------------------------------------------- |
| `type` | string | *none* | External type (`file`, `archive`, or `git-repo`) |
| `clone.args` | []string | *none* | Extra args to `git clone` |
| `encrypted` | bool | `false` | Whether the external is encrypted |
| `exact` | bool | `false` | Add `exact_` attribute to directories in archive |
| `exclude` | []string | *none* | Patterns to exclude from archive |
| `executable` | bool | `false` | Add `executable_` attribute to file |
| `filter.command` | string | *none* | Command to filter contents |
| `filter.args` | []string | *none* | Extra args to command to filter contents |
| `format` | string | *autodetect* | Format of archive |
| `include` | []string | *none* | Patterns to include from archive |
| `pull.args` | []string | *none* | Extra args to `git pull` |
| `refreshPeriod` | duration | `0` | Refresh period |
| `stripComponents` | int | `0` | Number of leading directory components to strip from archives |
| `url` | string | *none* | URL |
| `checksum.sha256` | string | *none* | Expected SHA256 checksum of data |
| `checksum.sha384` | string | *none* | Expected SHA384 checksum of data |
| `checksum.sha512` | string | *none* | Expected SHA512 checksum of data |
| `checksum.size` | int | *none* | Expected size of data |
| `clone.args` | []string | *none* | Extra args to `git clone` |
| `filter.command` | string | *none* | Command to filter contents |
| `filter.args` | []string | *none* | Extra args to command to filter contents |
| `pull.args` | []string | *none* | Extra args to `git pull` |

If any of the optional `checksum.sha256`, `checksum.sha384`, or
`checksum.sha512` fields are set, chezmoi will verify that the downloaded data
Expand Down
20 changes: 10 additions & 10 deletions assets/chezmoi.io/docs/reference/templates/directives.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ with a template directive:

`$VALUE` can be an arbitrary string or one of:

| Value | Effect |
| -------- | --------------------------------------------------------------------- |
| `crlf` | Use Windows line endings (`\r\n`). |
| `lf` | Use UNIX-style line endings (`\n`). |
| `native` | Use platform-native line endings (`crlf` on Windows, `lf` elsewhere). |
| Value | Effect |
| -------- | -------------------------------------------------------------------- |
| `crlf` | Use Windows line endings (`\r\n`) |
| `lf` | Use UNIX-style line endings (`\n`) |
| `native` | Use platform-native line endings (`crlf` on Windows, `lf` elsewhere) |

## Missing keys

Expand All @@ -64,8 +64,8 @@ that is not present in the map. This behavior can be changed globally with the

`$VALUE` can be one of:

| Value | Effect |
| --------- | ---------------------------------------------------------------------------------------------- |
| `error` | Return an error on any missing key (default). |
| `invalid` | Ignore missing keys. If printed, the result of the index operation is the string `<no value>`. |
| `zero` | Ignore missing keys. If printed, the result of the index operation is the zero value. |
| Value | Effect |
| --------- | --------------------------------------------------------------------------------------------- |
| `error` | Return an error on any missing key (default) |
| `invalid` | Ignore missing keys. If printed, the result of the index operation is the string `<no value>` |
| `zero` | Ignore missing keys. If printed, the result of the index operation is the zero value |

0 comments on commit 461b175

Please sign in to comment.