Skip to content

Commit 243ac1a

Browse files
committed
Add license_template_path configuration snippet
1 parent 943407a commit 243ac1a

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

Configurations.md

+20
Original file line numberDiff line numberDiff line change
@@ -2115,3 +2115,23 @@ Enable unstable featuers on stable channel.
21152115
- **Default value**: `false`
21162116
- **Possible values**: `true`, `false`
21172117
- **Stable**: Yes
2118+
2119+
## `license_template_path`
2120+
2121+
Check whether beginnings of files match a license template.
2122+
2123+
- **Default value**: `""``
2124+
- **Possible values**: path to a license template file
2125+
- **Stable**: No
2126+
2127+
A license template is a plain text file which is matched literally against the
2128+
beginning of each source file, except for `{}`-delimited blocks, which are
2129+
matched as regular expressions. The following license template therefore
2130+
matches strings like `// Copyright 2017 The Rust Project Developers.`, `//
2131+
Copyright 2018 The Rust Project Developers.`, etc.:
2132+
2133+
```
2134+
// Copyright {\d+} The Rust Project Developers.
2135+
```
2136+
2137+
`\{`, `\}` and `\\` match literal braces / backslashes.

0 commit comments

Comments
 (0)