blob: 50dc74f773d5c35ee8db9afb756cd41256e77203 [file] [log] [blame]
Robert Szewczyk38cf7312020-06-29 09:07:49 -07001#
2# Copyright (c) 2020 Project CHIP Authors
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15#
16
Justin Wood0c46b2e2020-04-17 14:20:48 -070017# Do anything at all
18enabled: true
19
20# Push the style fixes directly to the original PR
21auto: false
22
23# Open Restyle PRs?
24pull_requests: true
25
26# Add labels to any created Restyle PRs
27labels:
28 - restyled
29
30# Labels to ignore
31ignore_labels:
32 - restyled-ignore
33
34# Leave comments on the original PR linking to the Restyle PR?
35comments: false
36
37# Request review on the Restyle PR
38request_review: none
39
40# Patterns to exclude from all Restylers
41exclude:
42 - ".github/workflows/**/*" # https://github.com/restyled-io/restyler/issues/73
Vivien Nicolasdd625452020-07-09 04:56:45 +020043 - ".github/workflows/*" # https://github.com/restyled-io/restyler/issues/73
44 - ".github/**/*" # https://github.com/restyled-io/restyler/issues/73
45 - ".github/*" # https://github.com/restyled-io/restyler/issues/73
Rob Walker085b3d02020-09-08 14:11:59 -070046 - "third_party/android/**/*"
47 - "third_party/inipp/repo/**/*"
48 - "third_party/jlink/**/*"
49 - "third_party/lwip/repo/**/*"
50 - "third_party/nlbuild-autotools/repo/**/*"
51 - "third_party/nlbuild-autotools/repo/.**/*" # "**/*" doesn't include directories that start with "."
52 - "third_party/nlassert/repo/**/*" # from here down built with $ awk '/path =/ {print $3 "/**/*"}' .gitmodules
53 - "third_party/nlfaultinjection/repo/**/*"
54 - "third_party/nlio/repo/**/*"
55 - "third_party/nlunit-test/repo/**/*"
56 - "third_party/mbedtls/repo/**/*"
57 - "examples/common/QRCode/repo/**/*"
58 - "examples/common/m5stack-tft/repo/**/*"
59 - "third_party/pigweed/repo/**/*"
60 - "third_party/openthread/repo/**/*"
61 - "third_party/ot-br-posix/repo/**/*"
62 - "third_party/bluez/repo/**/*"
63 - "third_party/ot-commissioner/repo/**/*"
64 - "third_party/cirque/repo/**/*"
65
66
67changed_paths:
68 maximum: 100000
69 outcome: error
Justin Wood0c46b2e2020-04-17 14:20:48 -070070
71# Restylers to run, and how
72restylers:
Rob Walker5a9f46d2020-05-26 14:32:28 -070073 - name: whitespace
74 enabled: true
Rob Walker085b3d02020-09-08 14:11:59 -070075 image: restyled/restyler-whitespace:v0.1.0.1
Rob Walker5a9f46d2020-05-26 14:32:28 -070076 command:
77 - whitespace
78 arguments: []
79 include:
Rob Walker84781242020-06-03 18:15:33 -070080 - "**/Dockerfile"
Rob Walker085b3d02020-09-08 14:11:59 -070081 - ".**/Dockerfile"
Rob Walkerafdc90d2020-06-03 20:07:26 -070082 - "**/*.yml"
83 - "**/*.yaml"
Rob Walker085b3d02020-09-08 14:11:59 -070084 - ".**/*.yml"
85 - ".**/*.yaml"
Rob Walker84781242020-06-03 18:15:33 -070086 - "**/*.sh"
Rob Walker5a9f46d2020-05-26 14:32:28 -070087 - "**/*.c"
88 - "**/*.cc"
89 - "**/*.cpp"
90 - "**/*.cxx"
91 - "**/*.c++"
92 - "**/*.C"
93 - "**/*.cs"
94 - "**/*.h"
95 - "**/*.hh"
96 - "**/*.hpp"
97 - "**/*.hxx"
98 - "**/*.h++"
99 - "**/*.H"
100 - "**/*.java"
101 - "**/*.js"
Rob Walkerafdc90d2020-06-03 20:07:26 -0700102 - "**/*.json"
Rob Walker085b3d02020-09-08 14:11:59 -0700103 - ".**/*.js"
104 - ".**/*.json"
Rob Walker5a9f46d2020-05-26 14:32:28 -0700105 - "**/*.m"
106 - "**/*.mm"
randyrossic4964e32020-06-23 19:14:03 -0400107 - name: google-java-format
108 enabled: true
109 image: restyled/restyler-google-java-format:v1.6
110 command:
111 - google-java-format
112 - "--replace"
113 arguments: []
114 include:
115 - "**/*.java"
116 interpreters: []
Justin Wood0c46b2e2020-04-17 14:20:48 -0700117 - name: clang-format
118 enabled: true
119 image: restyled/restyler-clang-format:v9.0.0
120 command:
121 - clang-format
122 - "-i"
123 arguments: []
124 include:
125 - "**/*.c"
126 - "**/*.cc"
127 - "**/*.cpp"
128 - "**/*.cxx"
129 - "**/*.c++"
130 - "**/*.C"
131 - "**/*.cs"
132 - "**/*.h"
133 - "**/*.hh"
134 - "**/*.hpp"
135 - "**/*.hxx"
136 - "**/*.h++"
137 - "**/*.H"
Justin Wood0c46b2e2020-04-17 14:20:48 -0700138 - "**/*.js"
139 - "**/*.m"
Rob Walker5a9f46d2020-05-26 14:32:28 -0700140 - "**/*.mm"
Justin Wood0c46b2e2020-04-17 14:20:48 -0700141 interpreters: []
Michael Spang65dd6512020-08-18 12:07:01 -0400142 - name: gn
143 image: restyled/restyler-gn:v1
144 enabled: true
145 include:
146 - "**/*.gn"
147 - "**/*.gni"
Justin Wood0a9545e2020-04-20 18:15:21 -0700148 - name: prettier-json
149 image: restyled/restyler-prettier:v1.19.1-2
Justin Wood0c46b2e2020-04-17 14:20:48 -0700150 enabled: true
Justin Wood0a9545e2020-04-20 18:15:21 -0700151 command:
152 - prettier
153 - "--write"
154 arguments: []
Justin Wood0c46b2e2020-04-17 14:20:48 -0700155 include:
156 - "**/*.json"
Rob Walker085b3d02020-09-08 14:11:59 -0700157 - ".**/*.json"
Justin Wood0a9545e2020-04-20 18:15:21 -0700158 interpreters: []
Justin Wood0c46b2e2020-04-17 14:20:48 -0700159 - name: prettier-markdown
Justin Wood0a9545e2020-04-20 18:15:21 -0700160 image: restyled/restyler-prettier:v1.19.1-2
161 command:
162 - prettier
163 - "--write"
164 arguments: []
Justin Wood0c46b2e2020-04-17 14:20:48 -0700165 enabled: true
166 include:
167 - "**/*.md"
168 - "**/*.markdown"
169 - name: prettier-yaml
Justin Wood0a9545e2020-04-20 18:15:21 -0700170 image: restyled/restyler-prettier:v1.19.1-2
Justin Wood0c46b2e2020-04-17 14:20:48 -0700171 enabled: true
172 include:
173 - "**/*.yml"
174 - "**/*.yaml"
175 - name: shellharden
Justin Wood0a9545e2020-04-20 18:15:21 -0700176 image: restyled/restyler-shellharden:v4.1.1-2
Justin Wood0c46b2e2020-04-17 14:20:48 -0700177 enabled: true
178 include:
179 - "**/*.sh"
180 - "**/*.bash"
181 - name: shfmt
Justin Wood0a9545e2020-04-20 18:15:21 -0700182 image: restyled/restyler-shfmt:v3.0.1
Justin Wood0c46b2e2020-04-17 14:20:48 -0700183 enabled: true
Justin Wooda923ce72020-05-13 18:59:48 -0700184 command:
185 - shfmt
186 - "-w"
187 arguments:
188 - "-i"
189 - "4"
190 - "-ci"
191 interpreters:
192 - sh
193 - bash
Justin Wood0c46b2e2020-04-17 14:20:48 -0700194 include:
195 - "**/*.sh"
196 - "**/*.bash"