Skip to content

Commit cedaa52

Browse files
committed
Update format and lint:format to not touch generated files (workaround for dart-lang/dart_style#864)
1 parent 89bfa58 commit cedaa52

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

melos.yaml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,12 @@ scripts:
126126

127127
format:
128128
description: Format code.
129-
run: dart format --fix --line-length 160 .
129+
# while we wait for https://github.com/dart-lang/dart_style/issues/864
130+
run: >-
131+
find lib test integration_test -name '*.dart' -not -name '*.g.dart' -not -name '*.realm.dart' -not -name 'realm_bindings.dart'
132+
| xargs dart format --fix --line-length 160
133+
exec:
134+
concurrency: 1 # only one project at a time to keep output sane
130135

131136
upgrade:
132137
description: Upgrade all dependencies.
@@ -140,8 +145,11 @@ scripts:
140145
melos publish --dry-run
141146
142147
lint:format:
143-
run: dart format --fix --line-length 160 --output none --set-exit-if-changed .
144-
exec:
148+
# while we wait for https://github.com/dart-lang/dart_style/issues/864
149+
run: >-
150+
find lib test integration_test -name '*.dart' -not -name '*.g.dart' -not -name '*.realm.dart' -not -name 'realm_bindings.dart'
151+
| xargs dart format --fix --line-length 160 --output none --set-exit-if-changed
152+
exec:
145153
concurrency: 1 # only one project at a time to keep output sane
146154

147155
lint:pana:

0 commit comments

Comments
 (0)