Skip to content
This repository was archived by the owner on Sep 12, 2019. It is now read-only.

Commit d5b6b9e

Browse files
author
sw-yx
committed
deprecate ts, go, and --dir command, clean up code
1 parent 53bbfe5 commit d5b6b9e

File tree

13 files changed

+136
-113
lines changed

13 files changed

+136
-113
lines changed

README.md

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ USAGE
3838
OPTIONS
3939
-c, --cmd=cmd command to run
4040
-d, --devport=devport port of the dev server started by command
41-
-d, --dir=dir dir with static files
4241
-f, --functions=functions Specify a functions folder to serve
4342
-o, --offline disables any features that require network access
4443
-p, --port=port port of netlify dev
@@ -69,14 +68,13 @@ The order of precedence for applying redirect rules is:
6968

7069
See the [Redirects Documentation](https://www.netlify.com/docs/redirects/) for more information on Netlify's redirect and proxying capabilities.
7170
72-
7371
#### Running the project and accessing redirects
72+
7473
```bash
7574
# Build, serve and hot-reload changes
7675
$ netlify dev
7776
```
7877
79-
8078
### Project detection
8179
8280
Netlify Dev will attempt to detect the SSG or build command that you are using, and run these on your behalf, while adding other development utilities.
@@ -91,14 +89,13 @@ The number of project types which Netlify Dev can detect is growing, but if your
9189
9290
```
9391
94-
9592
### Netlify Functions
9693
9794
Netlify can also create serverless functions for you locally as part of Netlify Functions. The serverless functions can then be run by Netlify Dev in the same way that wold be when deployed to the cloud.
9895
9996
A number of function templates are available to get you started, and you can add your own utility functions to suit your own project development needs.
10097
101-
Create a new function
98+
Create a new function
10299
103100
```bash
104101
$ netlify functions:create
@@ -113,13 +110,9 @@ $ netlify functions:create
113110
114111
# Create a new function with a given name
115112
$ netlify functions:create hello-world
116-
# or
113+
# or
117114
$ netlify functions:create --name hello-world
118115
119-
# Create a new function in a subdirectory
120-
# rather than as a single file
121-
$ netlify functions:create hello-world --dir
122-
123116
# Create a new function by cloning a template from a remote url
124117
# organised with dependencies installed into a subdirectory
125118
$ netlify functions:create hello-world --url https://github.com/netlify-labs/all-the-functions/tree/master/functions/9-using-middleware
@@ -136,7 +129,6 @@ $ netlify dev
136129
137130
Each serverless function will be exposed on a URL corresponding to its path and file name.
138131
139-
140132
`./functions/hello-world.js` -> `http://localhost:{PORT}/.netlify/functions/hello-world`
141133
142134
`./functions/my-api/hello-world.js` -> `http://localhost:{PORT}/.netlify/functions/my-api/hello-world`

package-lock.json

Lines changed: 31 additions & 39 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,11 @@
1212
"ascii-table": "0.0.9",
1313
"copy-template-dir": "^1.4.0",
1414
"fs-extra": "^7.0.1",
15+
"fuzzy": "^0.1.3",
1516
"get-port": "^4.1.0",
1617
"http-proxy": "^1.17.0",
1718
"inquirer": "^6.2.2",
19+
"inquirer-autocomplete-prompt": "^1.0.1",
1820
"netlify": "ssh+git://[email protected]:netlify/js-client-private",
1921
"netlify-rules-proxy": "git+ssh://[email protected]/netlify/netlify-rules-proxy.git",
2022
"node-fetch": "^2.3.0",

0 commit comments

Comments
 (0)