spooder 4.3.1 → 4.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/package.json +1 -1
- package/src/cli.ts +6 -3
package/README.md
CHANGED
|
@@ -225,6 +225,10 @@ server.webhook(process.env.WEBHOOK_SECRET, '/webhook', payload => {
|
|
|
225
225
|
});
|
|
226
226
|
```
|
|
227
227
|
|
|
228
|
+
### Skip Updates
|
|
229
|
+
|
|
230
|
+
In addition to being skipped in [dev mode](#cli-dev-mode), updates can also be skipped in production mode by passing the `--no-update` flag.
|
|
231
|
+
|
|
228
232
|
<a id="cli-canary"></a>
|
|
229
233
|
## CLI > Canary
|
|
230
234
|
|
package/package.json
CHANGED
package/src/cli.ts
CHANGED
|
@@ -8,13 +8,18 @@ async function start_server() {
|
|
|
8
8
|
|
|
9
9
|
const argv = process.argv.slice(2);
|
|
10
10
|
const is_dev_mode = argv.includes('--dev');
|
|
11
|
+
const skip_updates = argv.includes('--no-update');
|
|
11
12
|
|
|
12
13
|
if (is_dev_mode)
|
|
13
14
|
log('[{dev}] spooder has been started in {dev mode}');
|
|
14
15
|
|
|
15
16
|
const config = await get_config();
|
|
16
17
|
|
|
17
|
-
if (
|
|
18
|
+
if (is_dev_mode) {
|
|
19
|
+
log('[{update}] skipping update commands in {dev mode}');
|
|
20
|
+
} else if (skip_updates) {
|
|
21
|
+
log('[{update}] skipping update commands due to {--no-update} flag');
|
|
22
|
+
} else {
|
|
18
23
|
const update_commands = config.update;
|
|
19
24
|
const n_update_commands = update_commands.length;
|
|
20
25
|
|
|
@@ -42,8 +47,6 @@ async function start_server() {
|
|
|
42
47
|
}
|
|
43
48
|
}
|
|
44
49
|
}
|
|
45
|
-
} else {
|
|
46
|
-
log('[{dev}] skipping update commands in {dev mode}');
|
|
47
50
|
}
|
|
48
51
|
|
|
49
52
|
const crash_console_history = config.canary.crash_console_history;
|