You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on May 1, 2020. It is now read-only.
Refer to the PureScript [compiler usage](https://github.com/purescript/purescript/wiki/Language-Guide:-Getting-Started#compiler-usage) section of the Github wiki for additional details on the behaviour of each option below.
34
34
35
-
### purescript.psc(options)
36
-
37
-
Invokes the `psc` command.
38
-
39
-
#### options
40
-
41
-
-**noPrelude**: Boolean value that toggles `--no-prelude`
42
-
- Do not include the Prelude in the generated Javascript.
43
-
-**noTco**: Boolean value that toggles `--no-tco`
44
-
- Turn off tail-call elimination.
45
-
-**noMagicDo**: Boolean value that toggles `--no-magic-do`
46
-
- Turn off optimizations which inline calls to >>= for the Eff monad.
47
-
-**main**: Boolean or string value that sets `--main` or `--main=<string>`
48
-
- Generate a call to main in the specified module after all other generated Javascript. Defaults to Main if the option is used but no value is provided.
49
-
-**noOpts**: Boolean value that toggles `--no-opts`
50
-
- Disable all optimizations.
51
-
-**verboseErrors**: Boolean value that toggles `--verbose-errors`
52
-
- Generate verbose error messages.
53
-
-**comments**: Boolean value that toggles `--comments`
54
-
- Include comments in generated code.
55
-
-**browserNamespace**: String value that sets `--browser-namespace=<string>`
56
-
- Specify the namespace that PureScript modules will be exported to when running in the browser.
57
-
-**externs**: String value that sets `--externs=<string>`
58
-
- Write a list of foreign imports declarations to the specified file in addition to generating Javascript output.
59
-
-**module**: Array of string values that sets one or more `--module=<string>`
60
-
- If specified, any code which is not referenced transitively from this module will be removed.
61
-
-**codegen**: Array of string values that sets one or more `--codegen=<string>`
62
-
- A array of modules for which JavaScript and externs should be generated.
63
-
-**output**: String value that specifies the output file. Note that this will not set `--output=<string>` because the resulting file is piped through the Gulp stream.
64
-
- Write the generated Javascript to the specified file.
65
-
-**noPrefix**: Boolean value that toggles `--no-prefix`
66
-
- Do not include the comment header.
67
-
68
-
### purescript.pscMake(options)
69
-
70
-
Invokes the `psc-make` command.
71
-
72
-
#### options
73
-
74
-
-**noPrelude**: Boolean value that toggles `--no-prelude`
75
-
- Do not include the Prelude in the generated Javascript.
76
-
-**noOpts**: Boolean value that toggles `--no-opts`
77
-
- Disable all optimizations.
78
-
-**noMagicDo**: Boolean value that toggles `--no-magic-do`
79
-
- Turn off optimizations which inline calls to >>= for the Eff monad.
80
-
-**noTco**: Boolean value that toggles `--no-tco`
81
-
- Turn off tail-call elimination.
82
-
-**verboseErrors**: Boolean value that toggles `--verbose-errors`
83
-
- Generate verbose error messages.
84
-
-**browserNamespace**: String value that sets `--browser-namespace=<string>`
85
-
- Specify the namespace that PureScript modules will be exported to when running in the browser.
86
-
-**output**: String value that sets `--output=<string>`
87
-
- Write the generated Javascript to the specified file.
88
-
89
-
### purescript.pscDocs(options)
90
-
91
-
Invokes the `pscDocs` command.
92
-
93
-
#### options
94
-
95
-
- hierarchy: Boolean value that toggles `--hierarchy-images`
96
-
97
-
### purescript.dotPsci()
98
-
99
-
Generates a `.psci` file in the current directory. Each source file is
100
-
added with the `:m` command.
35
+
### `purescript.psc(options)`
36
+
37
+
Invokes the `psc` command. The following options are supported.
38
+
39
+
###### `noPrelude` (Boolean)
40
+
41
+
Toggles `--no-prelude` that omits the Prelude.
42
+
43
+
###### `noTco` (Boolean)
44
+
45
+
Toggles `--no-tco` that disables tail-call optimizations.
46
+
47
+
###### `noMagicDo` (Boolean)
48
+
49
+
Toggles `--no-magic-do` that disables optimizations overloading the do keyword generating efficient code for the `Eff` monad.
50
+
51
+
###### `main` (Boolean or String)
52
+
53
+
Toggles `--main` or sets `--main=<string>` that generates code to run the `main` function in the specified module or the `Main` module by default.
54
+
55
+
###### `noOpts` (Boolean)
56
+
57
+
Toggles `--no-opts` that skips the optimization phase.
58
+
59
+
###### `verboseErrors` (Boolean)
60
+
61
+
Toggles `--verbose-errors` that displays verbose error messages.
62
+
63
+
###### `comments` (Boolean)
64
+
65
+
Toggles `--comments` that includes comments in generated code.
66
+
67
+
###### `browserNamespace` (String)
68
+
69
+
Sets `--browser-namespace=<string>` that specifies the namespace that PureScript modules will be exported to when running in the browser.
70
+
71
+
###### `externs` (String)
72
+
73
+
Sets `--externs=<string>` that specifies the externs file.
74
+
75
+
###### `module` (String Array)
76
+
77
+
Sets one or more `--module=<string>` that enables dead code elimination, removing all code without a transitive dependency of one of the specified modules.
78
+
79
+
###### `codegen` (String Array)
80
+
81
+
Sets one or more `--codegen=<string>` that generates code and extenrs for the specified modules.
82
+
83
+
###### `output` (String)
84
+
85
+
Sets the path value of the [File](https://github.com/wearefractal/vinyl) passed through the Gulp stream. Note that this will not set `--output=<string>`.
86
+
87
+
###### `noPrefix` (Boolean)
88
+
89
+
Toggles `--no-prefix` that does not include the comment header.
90
+
91
+
### `purescript.pscMake(options)`
92
+
93
+
Invokes the `psc-make` command. The following options are supported.
94
+
95
+
###### `noPrelude` (Boolean)
96
+
97
+
Toggles `--no-prelude` that omits the Prelude.
98
+
99
+
###### `noTco` (Boolean)
100
+
101
+
Toggles `--no-tco` that disables tail-call optimizations.
102
+
103
+
###### `noMagicDo` (Boolean)
104
+
105
+
Toggles `--no-magic-do` that disables optimizations overloading the do keyword generating efficient code for the `Eff` monad.
106
+
107
+
###### `noOpts` (Boolean)
108
+
109
+
Toggles `--no-opts` that skips the optimization phase.
110
+
111
+
###### `verboseErrors` (Boolean)
112
+
113
+
Toggles `--verbose-errors` that displays verbose error messages.
114
+
115
+
###### `comments` (Boolean)
116
+
117
+
Toggles `--comments` that includes comments in generated code.
118
+
119
+
###### `output` (String)
120
+
121
+
Sets `--output=<string>` the specifies the output directory, `output` by default.
122
+
123
+
###### `noPrefix` (Boolean)
124
+
125
+
Toggles `--no-prefix` that does not include the comment header.
126
+
127
+
### `purescript.pscDocs(options)`
128
+
129
+
Invokes the `pscDocs` command. The following options are supported.
130
+
131
+
###### `format` (markdown | etags | ctags)
132
+
133
+
Sets `--output=<markdown|etags|ctags>` that specifies the output format.
134
+
135
+
### `purescript.dotPsci()`
136
+
137
+
Generates a `.psci` file in the current directory. Each source file is added with the `:m` command.
101
138
102
139
## Command line arguments
103
140
104
-
The `--verbose` argument will display the output during the `psc-make`
105
-
command. For example `gulp --verbose`.
141
+
The `--verbose` argument will display the output during the `psc-make` command. For example `gulp --verbose`.
0 commit comments