@@ -12,6 +12,70 @@ The `stack build` command is introduced in the first part of
12
12
[ Stack's user guide] ( GUIDE.md#the-stack-build-command ) . For further information
13
13
about the command, see the [ build command] ( build_command.md ) documentation.
14
14
15
+ ## The ` stack config ` commands
16
+
17
+ The ` stack config ` commands provide assistence with accessing or modifying
18
+ Stack's configuration. See ` stack config ` for the available commands.
19
+
20
+ ## The ` stack config env ` command
21
+
22
+ ` stack config env ` outputs a script that sets or unsets environment variables
23
+ for a Stack environment. Flags modify the script that is output:
24
+
25
+ * ` --[no-]locals ` (enabled by default) include/exclude local package information
26
+ * ` --[no-]ghc-package-path ` (enabled by default) set ` GHC_PACKAGE_PATH `
27
+ environment variable or not
28
+ * ` --[no-]stack-exe ` (enabled by default) set ` STACK_EXE ` environment variable
29
+ or not
30
+ * ` --[no-]locale-utf8 ` (disabled by default) set the ` GHC_CHARENC `
31
+ environment variable to ` UTF-8 ` or not
32
+ * ` --[no-]keep-ghc-rts ` (disabled by default) keep/discard any ` GHCRTS `
33
+ environment variable
34
+
35
+ ## The ` stack config set ` commands
36
+
37
+ The ` stack config set ` commands allow the values of keys in YAML configuration
38
+ files to be set. See ` stack config set ` for the available keys.
39
+
40
+ ## The ` stack config set install-ghc ` command
41
+
42
+ ` stack config set install-ghc true ` or ` false ` sets the ` install-ghc ` key in a
43
+ YAML configuration file, accordingly. By default, the project-level
44
+ configuration file (` stack.yaml ` ) is altered. The ` --global ` flag specifies the
45
+ user-specific global configuration file (` config.yaml ` ).
46
+
47
+ Known bug:
48
+
49
+ * The command does not respect the order of the existing YAML configuration
50
+ file.
51
+
52
+ ## The ` stack config set resolver ` command
53
+
54
+ ` stack config set resolver <snapshot> ` sets the ` resolver ` key in the
55
+ project-level configuration file (` stack.yaml ` ).
56
+
57
+ A snapshot of ` lts ` or ` nightly ` will be translated into the most recent
58
+ available. A snapshot of ` lts-19 ` will be translated into the most recent
59
+ available in the ` lts-19 ` sequence.
60
+
61
+ Known bugs:
62
+
63
+ * The command does not respect the presence of a ` snapshot ` key.
64
+ * The command does not respect the order of the existing YAML configuration
65
+ file.
66
+
67
+ ## The ` stack config set system-ghc ` command
68
+
69
+ ` stack config set system-ghc true ` or ` false ` sets the ` system-ghc ` key in a
70
+ YAML configuration file, accordingly. By default, the project-level
71
+ configuration file (` stack.yaml ` ) is altered. The ` --global ` flag specifies the
72
+ user-specific global configuration file (` config.yaml ` ).
73
+
74
+ Known bug:
75
+
76
+ * The command does not respect the order of the existing YAML configuration
77
+ file.
78
+
15
79
## The ` stack dot ` command
16
80
17
81
If you'd like to get some insight into the dependency tree of your packages, you
0 commit comments