You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: wpiformat/README.md
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -20,13 +20,13 @@ pip install wpiformat
20
20
21
21
## Project Setup
22
22
23
-
To use these tools with a new project, copy `.styleguide`, and `.styleguide-license` from the examples folder into the project and create a new `.clang-format` file based on the desired C/C++ style.
23
+
To use these tools with a new project, copy `.wpiformat`, and `.wpiformat-license` from the examples folder into the project and create a new `.clang-format` file based on the desired C/C++ style.
24
24
25
25
Note: Since wpiformat already handles include ordering, it is recommended to use `SortIncludes: false` in `.clang-format`.
26
26
27
-
## .styleguide
27
+
## .wpiformat
28
28
29
-
wpiformat checks the current directory for the `.styleguide` file. If one doesn't exist, all parent directories are tried as well. This file contains groups of filename regular expressions.
29
+
wpiformat checks the current directory for the `.wpiformat` file. If one doesn't exist, all parent directories are tried as well. This file contains groups of filename regular expressions.
30
30
```
31
31
groupName {
32
32
regex_here
@@ -36,7 +36,7 @@ The regexes are matched using [re.search()](https://docs.python.org/3/library/re
36
36
37
37
Empty config groups can be omitted. Directory separators must be "/", not "\\". During processing, they will be replaced internally with an os.sep that is automatically escaped for regexes.
38
38
39
-
See the `.styleguide` file in the docs/examples directory for all possible groups.
39
+
See the `.wpiformat` file in the docs/examples directory for all possible groups.
40
40
41
41
### Specifying C/C++ files to format
42
42
@@ -87,17 +87,17 @@ The following groups correspond to the header groups in the style guide. If a he
87
87
88
88
Appending a `// NOLINT` comment to a header include to prevent wpiformat's header include sorter from modifying it and to maintain its relative ordering with other header includes. This will, in effect, treat it as a barrier across which no header includes will be moved. Header includes on each side of the barrier will still be sorted as normal.
89
89
90
-
## .styleguide-license
90
+
## .wpiformat-license
91
91
92
-
This file contains the license header template. It should contain `Copyright (c)` followed by the company name and the string `{year}`. See the `.styleguide-license` file in the docs/examples directory.
92
+
This file contains the license header template. It should contain `Copyright (c)` followed by the company name and the string `{year}`. See the `.wpiformat-license` file in the docs/examples directory.
93
93
94
-
wpiformat checks the currently processed file's directory for a `.styleguide` file first and traverses up the directory tree if one isn't found. This allows templates which are closer to the processed file to override a project's main template.
94
+
wpiformat checks the currently processed file's directory for a `.wpiformat` file first and traverses up the directory tree if one isn't found. This allows templates which are closer to the processed file to override a project's main template.
95
95
96
96
### License header semantics
97
97
98
98
The license header is always at the beginning of the file and ends after two newlines. If there isn't one, or it doesn't contain the required copyright contents, wpiformat inserts a new one containing the current year.
99
99
100
-
### `.styleguide-license` special variables
100
+
### `.wpiformat-license` special variables
101
101
102
102
`{year}` is replaced with a year range from the earliest copyright year in the file to the current year. If the earliest year is the current year, only that year will be written.
0 commit comments