Skip to content

Commit 54b4838

Browse files
authored
Merge pull request #10714 from peterbecich/fix-cabal-build-depends-formatting-inconsistency
make formatting of `build-depends` consistent
2 parents 3b12960 + add05c4 commit 54b4838

File tree

8 files changed

+175
-157
lines changed

8 files changed

+175
-157
lines changed

.git-blame-ignore-revs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# 2025
2+
########################################
3+
# make *.cabal build-depends consistently formatted
4+
7d791b9da10b5034e7a997a0044ded5575fe123f
5+
16
# 2023
27
########################################
38

Cabal-hooks/Cabal-hooks.cabal

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,11 @@ library
2727
hs-source-dirs: src
2828

2929
build-depends:
30-
Cabal-syntax >= 3.15 && < 3.17,
31-
Cabal >= 3.15 && < 3.17,
32-
base >= 4.13 && < 5,
33-
containers >= 0.5.0.0 && < 0.8,
34-
transformers >= 0.5.6.0 && < 0.7
30+
, Cabal-syntax >= 3.15 && < 3.17
31+
, Cabal >= 3.15 && < 3.17
32+
, base >= 4.13 && < 5
33+
, containers >= 0.5.0.0 && < 0.8
34+
, transformers >= 0.5.6.0 && < 0.7
3535

3636
ghc-options: -Wall -fno-ignore-asserts -fwarn-tabs -fwarn-incomplete-uni-patterns -fwarn-incomplete-record-updates
3737

Cabal-syntax/Cabal-syntax.cabal

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -28,22 +28,22 @@ library
2828
hs-source-dirs: src
2929

3030
build-depends:
31-
array >= 0.4.0.1 && < 0.6,
32-
base >= 4.13 && < 5,
33-
binary >= 0.7 && < 0.9,
34-
bytestring >= 0.10.0.0 && < 0.13,
35-
containers >= 0.5.0.0 && < 0.8,
36-
deepseq >= 1.3.0.1 && < 1.7,
37-
directory >= 1.2 && < 1.4,
38-
filepath >= 1.3.0.1 && < 1.6,
39-
mtl >= 2.1 && < 2.4,
40-
parsec >= 3.1.13.0 && < 3.2,
41-
pretty >= 1.1.1 && < 1.2,
42-
text (>= 1.2.3.0 && < 1.3) || (>= 2.0 && < 2.2),
43-
time >= 1.4.0.1 && < 1.15,
31+
, array >= 0.4.0.1 && < 0.6
32+
, base >= 4.13 && < 5
33+
, binary >= 0.7 && < 0.9
34+
, bytestring >= 0.10.0.0 && < 0.13
35+
, containers >= 0.5.0.0 && < 0.8
36+
, deepseq >= 1.3.0.1 && < 1.7
37+
, directory >= 1.2 && < 1.4
38+
, filepath >= 1.3.0.1 && < 1.6
39+
, mtl >= 2.1 && < 2.4
40+
, parsec >= 3.1.13.0 && < 3.2
41+
, pretty >= 1.1.1 && < 1.2
42+
, text (>= 1.2.3.0 && < 1.3) || (>= 2.0 && < 2.2)
43+
, time >= 1.4.0.1 && < 1.15
4444
-- transformers-0.4.0.0 doesn't have record syntax e.g. for Identity
4545
-- See also https://github.com/ekmett/transformers-compat/issues/35
46-
transformers (>= 0.3 && < 0.4) || (>=0.4.1.0 && <0.7)
46+
, transformers (>= 0.3 && < 0.4) || (>=0.4.1.0 && <0.7)
4747

4848
ghc-options:
4949
-Wall

Cabal-tests/Cabal-tests.cabal

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ test-suite unit-tests
5555

5656
main-is: UnitTests.hs
5757
build-depends:
58-
array
58+
, array
5959
, base >=4.13 && <5
6060
, bytestring
6161
, Cabal
@@ -82,7 +82,7 @@ test-suite parser-tests
8282
hs-source-dirs: tests
8383
main-is: ParserTests.hs
8484
build-depends:
85-
base
85+
, base
8686
, base-compat >=0.11.0 && <0.14
8787
, bytestring
8888
, Cabal-syntax
@@ -103,7 +103,7 @@ test-suite check-tests
103103
hs-source-dirs: tests
104104
main-is: CheckTests.hs
105105
build-depends:
106-
base
106+
, base
107107
, bytestring
108108
, Cabal
109109
, Cabal-syntax
@@ -125,7 +125,7 @@ test-suite custom-setup-tests
125125
IdrisSetup
126126

127127
build-depends:
128-
base
128+
, base
129129
, Cabal
130130
, Cabal-syntax
131131
, directory
@@ -141,7 +141,7 @@ test-suite hackage-tests
141141

142142
hs-source-dirs: tests
143143
build-depends:
144-
base
144+
, base
145145
, bytestring
146146
, Cabal
147147
, Cabal-syntax
@@ -152,7 +152,7 @@ test-suite hackage-tests
152152
, time
153153

154154
build-depends:
155-
base-compat >=0.11.0 && <0.14
155+
, base-compat >=0.11.0 && <0.14
156156
, base-orphans >=0.6 && <0.10
157157
, clock >=0.8 && <0.9
158158
, optparse-applicative >=0.13.2.0 && <0.19
@@ -168,12 +168,12 @@ test-suite rpmvercmp
168168
main-is: RPMVerCmp.hs
169169
hs-source-dirs: tests
170170
build-depends:
171-
base
171+
, base
172172
, bytestring
173173
, Cabal-syntax
174174

175175
build-depends:
176-
QuickCheck
176+
, QuickCheck
177177
, tasty >=1.2.3 && <1.6
178178
, tasty-hunit
179179
, tasty-quickcheck <0.12
@@ -190,7 +190,7 @@ test-suite no-thunks-test
190190
main-is: NoThunks.hs
191191
hs-source-dirs: tests
192192
build-depends:
193-
base
193+
, base
194194
, bytestring
195195
, Cabal-syntax
196196
, tasty >=1.2.3 && <1.6
@@ -199,4 +199,5 @@ test-suite no-thunks-test
199199
-- this is test is buildable on old GHCs
200200
-- but it doesn't do anything.
201201
if impl(ghc >=8.6)
202-
build-depends: nothunks >=0.1.1.0 && <0.3
202+
build-depends:
203+
, nothunks >=0.1.1.0 && <0.3

Cabal/Cabal.cabal

Lines changed: 20 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -39,25 +39,28 @@ library
3939
hs-source-dirs: src
4040

4141
build-depends:
42-
Cabal-syntax ^>= 3.15,
43-
array >= 0.4.0.1 && < 0.6,
44-
base >= 4.13 && < 5,
45-
bytestring >= 0.10.0.0 && < 0.13,
46-
containers >= 0.5.0.0 && < 0.8,
47-
deepseq >= 1.3.0.1 && < 1.7,
48-
directory >= 1.2 && < 1.4,
49-
filepath >= 1.3.0.1 && < 1.6,
50-
pretty >= 1.1.1 && < 1.2,
51-
process >= 1.2.1.0 && < 1.7,
52-
time >= 1.4.0.1 && < 1.15
42+
, Cabal-syntax ^>= 3.15
43+
, array >= 0.4.0.1 && < 0.6
44+
, base >= 4.13 && < 5
45+
, bytestring >= 0.10.0.0 && < 0.13
46+
, containers >= 0.5.0.0 && < 0.8
47+
, deepseq >= 1.3.0.1 && < 1.7
48+
, directory >= 1.2 && < 1.4
49+
, filepath >= 1.3.0.1 && < 1.6
50+
, pretty >= 1.1.1 && < 1.2
51+
, process >= 1.2.1.0 && < 1.7
52+
, time >= 1.4.0.1 && < 1.15
5353

5454
if os(windows)
55-
build-depends: Win32 >= 2.3.0.0 && < 2.15
55+
build-depends:
56+
, Win32 >= 2.3.0.0 && < 2.15
5657
else
57-
build-depends: unix >= 2.8.6.0 && < 2.9
58+
build-depends:
59+
, unix >= 2.8.6.0 && < 2.9
5860

5961
if flag(git-rev)
60-
build-depends: githash ^>= 0.1.7.0
62+
build-depends:
63+
, githash ^>= 0.1.7.0
6164
cpp-options: -DGIT_REV
6265

6366
ghc-options:
@@ -328,9 +331,9 @@ library
328331
build-depends:
329332
-- transformers-0.4.0.0 doesn't have record syntax e.g. for Identity
330333
-- See also https://github.com/ekmett/transformers-compat/issues/35
331-
transformers (>= 0.3 && < 0.4) || (>=0.4.1.0 && <0.7),
332-
mtl >= 2.1 && < 2.4,
333-
parsec >= 3.1.13.0 && < 3.2
334+
, transformers (>= 0.3 && < 0.4) || (>=0.4.1.0 && <0.7)
335+
, mtl >= 2.1 && < 2.4
336+
, parsec >= 3.1.13.0 && < 3.2
334337

335338
other-modules:
336339
Distribution.Backpack.PreExistingComponent

cabal-install-solver/cabal-install-solver.cabal

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,8 @@ library
118118

119119
if flag(debug-tracetree)
120120
cpp-options: -DDEBUG_TRACETREE
121-
build-depends: tracetree ^>=0.1
121+
build-depends:
122+
, tracetree ^>=0.1
122123

123124
Test-Suite unit-tests
124125
default-language: Haskell2010

0 commit comments

Comments
 (0)