如何为无服务器项目设置版本?
我已通过1.38.0
命令将无服务器降级为npm install -g [email protected]
版本。使用以下npm install
package.json
{
"name": "serverless-defaults",
"version": "1.6.0",
"description": "description",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "git+/???"
},
"bugs": {
"url": "/???"
},
"homepage": "/???#readme",
"license": "MIT",
"private": true,
"devDependencies": {
"serverless-cf-vars": "^0.3.2",
"serverless-domain-manager": "3.2.7",
"serverless-pseudo-parameters": "^2.4.0",
"serverless-step-functions": "^2.6.0"
}
}
并得到:
cmd.exe /c "npm install"
npm WARN deprecated [email protected]: Please note that v5.0.1+ of superagent removes User-Agent header by default, therefore you may need to add it yourself (e.g. GitHub blocks requests without a User-Agent header). This notice will go away with v5.0.2+ once it is released.
> [email protected] postinstall C:\pah\node_modules\spawn-sync
> node postinstall
> [email protected] postinstall C:\pah\node_modules\jsonpath
> node lib/aesprim.js > generated/aesprim-browser.js
> [email protected] postinstall C:\pah\node_modules\serverless
> node ./scripts/postinstall.js
+--------------------------------------------------+
| |
| Serverless Framework successfully installed! |
| To start your first project, run “serverless”. |
| |
+--------------------------------------------------+
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
added 592 packages from 368 contributors and audited 1848 packages in 32.798s
found 0 vulnerabilities
Process finished with exit code 0
为什么[email protected]
为什么出现在日志中??? npm
的最新无服务器版本在哪里???在哪里指定我需要的无服务器版本?
如何为无服务器项目设置版本?
我已通过1.38.0
命令将无服务器降级为npm install -g [email protected]
版本。使用以下npm install
package.json
{
"name": "serverless-defaults",
"version": "1.6.0",
"description": "description",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "git+/???"
},
"bugs": {
"url": "/???"
},
"homepage": "/???#readme",
"license": "MIT",
"private": true,
"devDependencies": {
"serverless-cf-vars": "^0.3.2",
"serverless-domain-manager": "3.2.7",
"serverless-pseudo-parameters": "^2.4.0",
"serverless-step-functions": "^2.6.0"
}
}
并得到:
cmd.exe /c "npm install"
npm WARN deprecated [email protected]: Please note that v5.0.1+ of superagent removes User-Agent header by default, therefore you may need to add it yourself (e.g. GitHub blocks requests without a User-Agent header). This notice will go away with v5.0.2+ once it is released.
> [email protected] postinstall C:\pah\node_modules\spawn-sync
> node postinstall
> [email protected] postinstall C:\pah\node_modules\jsonpath
> node lib/aesprim.js > generated/aesprim-browser.js
> [email protected] postinstall C:\pah\node_modules\serverless
> node ./scripts/postinstall.js
+--------------------------------------------------+
| |
| Serverless Framework successfully installed! |
| To start your first project, run “serverless”. |
| |
+--------------------------------------------------+
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
added 592 packages from 368 contributors and audited 1848 packages in 32.798s
found 0 vulnerabilities
Process finished with exit code 0
为什么[email protected]
为什么出现在日志中??? npm
的最新无服务器版本在哪里???在哪里指定我需要的无服务器版本?