@@ -57,6 +57,8 @@ resolver.
57
57
58
58
### resolver or snapshot
59
59
60
+ Command line equivalent (takes precedence): ` --resolver ` option
61
+
60
62
` resolver ` and ` snapshot ` are synonyms. Only one of these keys is permitted, not
61
63
both.
62
64
@@ -220,6 +222,8 @@ For further information on the format for specifying dependencies, see the
220
222
221
223
Default : ` {}`
222
224
225
+ Command line equivalent (takes precedence) : ` stack build --flag` option
226
+
223
227
Flags can be set for each package separately, e.g.
224
228
225
229
` ` ` yaml
@@ -281,6 +285,8 @@ user-message: ! 'Warning: Some packages were found to be incompatible with the r
281
285
282
286
Default : ` []`
283
287
288
+ Command line equivalent : ` --customer-preprocessor-extensions` option
289
+
284
290
In order for Stack to be aware of any custom preprocessors you are using, add
285
291
their extensions here
286
292
@@ -301,9 +307,11 @@ options below are listed in alphabetic order.
301
307
302
308
(Since 1.0.1)
303
309
310
+ Restrictions : POSIX systems only.
311
+
304
312
Default : ` false`
305
313
306
- Restrictions : POSIX systems only.
314
+ Command line equivalent (takes precedence) : ` --[no-]allow-different-user ` flag
307
315
308
316
Allow users other than the owner of the Stack root to use the Stack
309
317
installation.
@@ -352,12 +360,16 @@ about your snapshot database.
352
360
353
361
# ## arch
354
362
355
- Set the architecture for GHC, build directories, etc. Values are those
356
- recognized by Cabal, e.g. :
363
+ Default : The machine architecture on which Stack is running.
364
+
365
+ Command line equivalent (takes precedence) : ` --arch` option
357
366
358
- arch : i386, x86_64
367
+ Stack identifies different GHC executables by platform (operating system and
368
+ machine architecture), (optional) GHC variant and (optional) GHC build.
369
+ See [`setup-info`](#setup-info).
359
370
360
- This can also be set via the command line.
371
+ ` arch` sets the machine architecture. Values are those recognized by Cabal,
372
+ including `x86_64`, `i386` and `aarch64`.
361
373
362
374
# ## build
363
375
@@ -412,6 +424,8 @@ build:
412
424
ddump-dir: ""
413
425
` ` `
414
426
427
+ Command line equivalents (take precedence) : Yes, see below.
428
+
415
429
Allows setting build options which are usually specified on the command line.
416
430
417
431
The meanings of these settings correspond directly with the command line flags
@@ -421,22 +435,22 @@ of the same name. For further information, see the
421
435
422
436
# ## color
423
437
438
+ Command line equivalent (takes precedence) : ` --color` option
439
+
424
440
This option specifies when to use color in output. The option is used as
425
441
`color : <WHEN>`, where `<WHEN>` is 'always', 'never', or 'auto'. On Windows
426
442
versions before Windows 10, for terminals that do not support color codes, the
427
443
default is 'never'; color may work on terminals that support color codes.
428
444
429
- The color use can also be set at the command line using the equivalent
430
- ` --color=<WHEN>` global option. Color use set at the command line takes
431
- precedence over that set in a yaml configuration file.
432
-
433
445
(The British English spelling (colour) is also accepted. In yaml configuration
434
446
files, the American spelling is the alternative that has priority.)
435
447
436
448
# ## compiler
437
449
438
450
(Since 0.1.7)
439
451
452
+ Command line equivalent (takes precedence) : ` --compiler` option
453
+
440
454
Overrides the compiler version in the resolver. Note that the `compiler-check`
441
455
flag also applies to the version numbers. This uses the same syntax as compiler
442
456
resolvers like `ghc-9.2.4`. This can be used to override the
@@ -591,6 +605,9 @@ repository. See the output of `stack templates`.
591
605
592
606
# ## docker
593
607
608
+ Command line equivalents : ` --docker-*` flags and options (see
609
+ ` stack --docker-help` for details).
610
+
594
611
For further information, see the
595
612
[Docker integration](docker_integration.md#configuration) documentation.
596
613
@@ -600,6 +617,8 @@ For further information, see the
600
617
601
618
Default : ` warning`
602
619
620
+ Command line equivalent (takes precedence) : ` --[no-]dump-logs` flag
621
+
603
622
Control which log output from local non-dependency packages to print to the
604
623
console. By default, Stack will only do this when building a single target
605
624
package or if the log contains warnings, to avoid generating unnecessarily
@@ -615,6 +634,9 @@ dump-logs: all # dump all logs for local non-dependency packages
615
634
616
635
Default : ` []`
617
636
637
+ Command line equivalent : ` --extra-include-dirs` option (repeat for each
638
+ directory)
639
+
618
640
A list of extra paths to be searched for header files. Paths should be absolute
619
641
620
642
` ` ` yaml
@@ -631,6 +653,8 @@ may well make sense to include these there as well.
631
653
632
654
Default : ` []`
633
655
656
+ Command line equivalent : ` --extra-lib-dirs` option (repeat for each directory)
657
+
634
658
A list of extra paths to be searched for libraries. Paths should be absolute
635
659
636
660
` ` ` yaml
@@ -640,7 +664,7 @@ extra-lib-dirs:
640
664
641
665
Since these are system-dependent absolute paths, it is recommended that you
642
666
specify these in your `config.yaml` file. If you control the build environment
643
- in your project's ``stack.yaml``, perhaps through docker or other means, then it
667
+ in your project's ``stack.yaml``, perhaps through Docker or other means, then it
644
668
may well make sense to include these there as well.
645
669
646
670
# ## extra-path
@@ -666,10 +690,18 @@ compiler's binary directory - will take precedence over those specified here
666
690
667
691
(Since 1.3.0)
668
692
669
- Specify a specialized architecture bindist to use. Normally this is
670
- determined automatically, but you can override the autodetected value here.
671
- Possible arguments include `standard`, `gmp4`, `nopie`, `tinfo6`,
672
- ` tinfo6-nopie` , `ncurses6`, and `integersimple`.
693
+ Default : ` standard`
694
+
695
+ Command line equivalent (takes precedence) : ` --ghc-build` option
696
+
697
+ Stack identifies different GHC executables by platform (operating system and
698
+ machine architecture), (optional) GHC variant and (optional) GHC build.
699
+ See [`setup-info`](#setup-info).
700
+
701
+ ` ghc-build` specifies a specialized architecture for the GHC executable.
702
+ Normally this is determined automatically, but it can be overriden. Possible
703
+ arguments include `standard`, `gmp4`, `nopie`, `tinfo6`, `tinfo6-nopie`,
704
+ ` ncurses6` , and `integersimple`.
673
705
674
706
# ## ghc-options
675
707
@@ -710,7 +742,13 @@ expressive, keys.
710
742
711
743
Default : ` standard`
712
744
713
- Specify a variant binary distribution of GHC to use. Known values :
745
+ Command line equivalent (takes precedence) : ` --ghc-variant` option
746
+
747
+ Stack identifies different GHC executables by platform (operating system and
748
+ machine architecture), (optional) GHC variant and (optional) GHC build.
749
+ See [`setup-info`](#setup-info).
750
+
751
+ `ghc-variant` specifies a variant of the GHC executable. Known values are :
714
752
715
753
* `standard`: Use the standard GHC binary distribution
716
754
* `integersimple`: Use a GHC bindist that uses
@@ -779,15 +817,18 @@ will receive a warning if this configuration value is set.
779
817
780
818
Default : ` true` (since 1.5.0)
781
819
820
+ Command line equivalent (takes precedence) : ` --[no-]install-ghc` flag
821
+
782
822
Whether or not to automatically install GHC when necessary.
783
823
784
824
# ## jobs
785
825
786
826
Default : the number of processors reported by your CPU.
787
827
788
- Specifies how many build tasks should be run in parallel. This can be overloaded
789
- on the command line via `-jN`, for example `-j2`. One usage for this might be to
790
- avoid running out of memory by setting it to 1, like this :
828
+ Command line equivalent (takes precedence) : ` -j` , `--jobs` option
829
+
830
+ Specifies how many build tasks should be run in parallel. One usage for this
831
+ might be to avoid running out of memory by setting it to 1, like this :
791
832
792
833
` ` ` yaml
793
834
jobs: 1
@@ -799,6 +840,8 @@ Default (on Unix-like operating systems): `~/.local/bin`
799
840
800
841
Default (on Windows) : ` %APPDATA%\l ocal\b in`
801
842
843
+ Command line equivalent (takes precedence) : ` --local-bin-path` option
844
+
802
845
Target directory for `stack install` and `stack build --copy-bins`.
803
846
804
847
# ## local-programs-path
@@ -830,9 +873,13 @@ Hackage that make use of `configure` are `network` and `process`.
830
873
831
874
(Since 0.1.6)
832
875
876
+ Restrictions : Windows systems only.
877
+
833
878
Default : ` true`
834
879
835
- Whether to modify the code page for UTF-8 output when running on Windows.
880
+ Command line equivalent (takes precedence) : ` --[no-]modify-code-page` flag
881
+
882
+ Whether to modify the code page for UTF-8 output.
836
883
837
884
` ` ` yaml
838
885
modify-code-page: false
855
902
shell-file :
856
903
~~~
857
904
905
+ Command line equivalents : ` --nix-*` flags and options (see `stack --nix-help`
906
+ for details).
907
+
858
908
For further information, see the
859
909
[Nix integration](nix_integration.md#configuration) documentation.
860
910
@@ -1077,6 +1127,8 @@ setup-info-locations: []
1077
1127
1078
1128
(Since 2.3)
1079
1129
1130
+ Command line equivalent (takes precedence) : ` --setup-info-yaml` option
1131
+
1080
1132
By way of introduction, see the [`setup-info`](#setup-info) option. This option
1081
1133
specifies the location(s) of `setup-info` dictionaries.
1082
1134
@@ -1158,16 +1210,20 @@ ghc:
1158
1210
1159
1211
Default : ` false`
1160
1212
1213
+ Command line equivalent (takes precedence) : ` --[no-]skip-ghc-check` flag
1214
+
1161
1215
Should we skip the check to confirm that your system GHC version (on the PATH)
1162
1216
matches what your project expects?
1163
1217
1164
1218
# ## skip-msys
1165
1219
1166
1220
(Since 0.1.2.0)
1167
1221
1222
+ Restrictions : Windows systems only
1223
+
1168
1224
Default : ` false`
1169
1225
1170
- Restrictions : Windows systems only
1226
+ Command line equivalent (takes precedence) : ` --[no-]skip-msys ` flag
1171
1227
1172
1228
Skips checking for and installing MSYS2 when stack is Setting up the
1173
1229
environment. This usually doesn't make sense in project-level configurations,
@@ -1184,6 +1240,8 @@ skip-msys: true
1184
1240
Default : https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/
1185
1241
(as set in the `pantry` library)
1186
1242
1243
+ Command line equivalent (takes precedence) : ` --snapshot-location-base` option
1244
+
1187
1245
Sets the base location of the LTS Haskell or Stackage Nightly snapshots.
1188
1246
1189
1247
For example :
@@ -1206,6 +1264,8 @@ then use a custom `snapshot-location-base` in the closed environments only.
1206
1264
1207
1265
# ## stack-colors
1208
1266
1267
+ Command line equivalent (takes precedence) : ` --stack-colors` option
1268
+
1209
1269
Stack uses styles to format some of its output. The default styles do not work
1210
1270
well with every terminal theme. This option specifies Stack's output styles,
1211
1271
allowing new styles to replace the defaults. The option is used as
@@ -1232,11 +1292,8 @@ terminal theme might wish to set the styles as follows:
1232
1292
` ` ` yaml
1233
1293
stack-colors: error=31:good=32:shell=35:dir=34:recommendation=32:target=95:module=35:package-component=95:secondary=92:highlight=32
1234
1294
` ` `
1235
- The styles can also be set at the command line using the equivalent
1236
- ` --stack-colors=<STYLES>` global option. Styles set at the command line take
1237
- precedence over those set in a YAML configuration file. (In respect of styles
1238
- used in verbose output, some of that output occurs before the configuration file
1239
- is processed.)
1295
+ In respect of styles used in verbose output, some of that output occurs before
1296
+ the configuration file is processed.
1240
1297
1241
1298
(The British English spelling (colour) is also accepted. In YAML configuration
1242
1299
files, the American spelling is the alternative that has priority.)
@@ -1261,6 +1318,8 @@ stack-developer-mode: false
1261
1318
Default : ` false` , unless the [Docker](docker_integration.md) or
1262
1319
[Nix](nix_integration.md) integration is enabled.
1263
1320
1321
+ Command line equivalent (takes precedence) : ` --[no-]system-ghc` flag
1322
+
1264
1323
Enables or disables using the GHC available on the PATH. (Make sure PATH is
1265
1324
explicit, i.e., don't use ~.) Useful to enable if you want to save the time,
1266
1325
bandwidth or storage space needed to setup an isolated GHC.
@@ -1343,6 +1402,8 @@ Customize the URLs where Stack looks for snapshot build plans.
1343
1402
1344
1403
# ## with-gcc
1345
1404
1405
+ Command line equivalent (takes precedence) : ` --with-gcc` option
1406
+
1346
1407
Specify a path to GCC explicitly, rather than relying on the normal path
1347
1408
resolution.
1348
1409
@@ -1352,6 +1413,8 @@ with-gcc: /usr/local/bin/gcc-5
1352
1413
1353
1414
# ## with-hpack
1354
1415
1416
+ Command line equivalent (takes precedence) : ` --with-hpack` option
1417
+
1355
1418
Use an [Hpack](https://github.com/sol/hpack) executable, rather than Stack's
1356
1419
in-built version of the Hpack functionality.
1357
1420
@@ -1365,10 +1428,9 @@ with-hpack: /usr/local/bin/hpack
1365
1428
1366
1429
Default : ` .stack-work`
1367
1430
1368
- This key specifies the relative path of Stack's ' work' directory. This can also
1369
- be specified by an environment variable or on the command line. The earlier
1370
- items in the list below take precedence:
1431
+ Command line equivalent (takes precedence) : ` -- work-dir ` option
1432
+
1433
+ Environment variable alternative (lowest precedence) : ` STACK_WORK `
1371
1434
1372
- 1. `--work-dir DIR` passed on the command line
1373
- 2. `work-dir` in a YAML configuration file
1374
- 3. `STACK_WORK` environment variable
1435
+ ` work-dir` (or the contents of `STACK_WORK`) specifies the relative path of
1436
+ Stack's 'work' directory.
0 commit comments