Skip to content

Commit 750fbb7

Browse files
authored
[core] Add help text for sanity start command (#183)
1 parent 95d3c91 commit 750fbb7

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,22 @@
11
import lazyRequire from '@sanity/util/lib/lazyRequire'
22

3+
const helpText = `
4+
Notes
5+
Changing the hostname or port number might require a new CORS-entry to be added.
6+
7+
Options
8+
--port <port> TCP port to start server on. [default: 3333]
9+
--host <host> The local network interface at which to listen. [default: "127.0.0.1"]
10+
11+
Examples
12+
sanity start --host=0.0.0.0
13+
sanity start --port=1942
14+
`
15+
316
export default {
417
name: 'start',
5-
signature: '',
18+
signature: '[--port <port>] [--host <host>]',
619
description: 'Starts a webserver that serves Sanity',
7-
action: lazyRequire(require.resolve('../../actions/start/startAction'))
20+
action: lazyRequire(require.resolve('../../actions/start/startAction')),
21+
helpText
822
}

0 commit comments

Comments
 (0)