installation - 如何解决此错误 \%RESOURCE_DIR%\?
问题描述
package.json Angular6:
{
"name": "adnanrealestate",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@agm/core": "^1.0.0-beta.3",
"@angular-mdc/web": "^0.36.3",
"@angular/animation": "^4.0.0-beta.8",
"@angular/animations": "^6.0.7",
"@angular/cdk": "github:angular/cdk-builds",
"@angular/common": "^6.0.7",
"@angular/compiler": "^6.0.7",
"@angular/core": "^6.0.7",
"@angular/forms": "^6.0.7",
"@angular/http": "^6.0.7",
"@angular/material": "github:angular/material2-builds",
"@angular/platform-browser": "^6.0.7",
"@angular/platform-browser-dynamic": "^6.0.7",
"@angular/platform-server": "^6.1.7",
"@angular/router": "^6.0.7",
"@google-cloud/firestore": "^0.16.1",
"@ng-bootstrap/ng-bootstrap": "^2.1.2",
"@ng-bootstrap/schematics": "^2.0.0-alpha.1",
"@ngrx/store": "^2.2.3",
"@ngui/map": "^0.30.3",
"@ngx-translate/core": "^10.0.2",
"@ngx-translate/http-loader": "^3.0.1",
"@types/googlemaps": "^3.30.10",
"angular-captcha": "^3.4.0",
"angular-file-upload": "^2.5.0",
"angular-file-uploader": "^4.1.1",
"angular-font-awesome": "^3.1.2",
"angularfire2": "^5.0.0-rc.12-next",
"bootstrap": "^4.1.1",
"core-js": "^2.5.4",
"file-saver": "^1.3.8",
"filepond": "^1.8.6",
"firebase": "^5.2.0",
"firebase-admin": "^5.12.1",
"firebase-functions": "^1.1.0",
"firestore": "^1.1.6",
"font-awesome": "^4.7.0",
"fs": "0.0.1-security",
"hammerjs": "^2.0.8",
"json2typescript": "^1.0.6",
"linq2fire": "^1.0.18",
"ng-bootstrap-form-validation": "^3.0.3",
"ng-recaptcha": "^4.0.0",
"ng-slideshow": "^0.8.2",
"ngx-bootstrap": "^3.0.1",
"ngx-gallery": "^5.6.2",
"ngx-international-phone-number": "^0.1.3",
"ngx-intl-tel-input": "^1.0.6",
"ngx-order-pipe": "^2.0.1",
"ngx-pagination": "^3.2.0",
"ngx-popover": "0.0.16",
"rxjs": "^6.0.0",
"rxjs-compat": "^6.2.1",
"time-ago-pipe": "^1.3.2",
"uikit": "^3.0.0-rc.6",
"zone.js": "^0.8.26"
},
"devDependencies": {
"@angular-devkit/build-angular": "~0.6.8",
"@angular/cli": "^6.2.1",
"@angular/compiler-cli": "^6.0.7",
"@angular/language-service": "^6.0.7",
"@types/hammerjs": "^2.0.35",
"@types/jasmine": "~2.8.6",
"@types/jasminewd2": "~2.0.3",
"@types/node": "~8.9.4",
"codelyzer": "~4.2.1",
"jasmine-core": "~2.99.1",
"jasmine-spec-reporter": "~4.2.1",
"karma": "~1.7.1",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage-istanbul-reporter": "~2.0.0",
"karma-jasmine": "~1.1.1",
"karma-jasmine-html-reporter": "^0.2.2",
"protractor": "~5.3.0",
"ts-node": "^5.0.1",
"tslint": "~5.9.1",
"typescript": "~2.7.2"
}
package.json 火力基地功能
{
"name": "functions",
"scripts": {
"lint": "tslint --project tsconfig.json",
"build": "tsc",
"serve": "npm run build && firebase serve --only functions",
"shell": "npm run build && firebase functions:shell",
"start": "npm run shell",
"deploy": "firebase deploy --only functions",
"logs": "firebase functions:log"
},
"main": "lib/index.js",
"dependencies": {
"firebase-admin": "^6.0.0",
"firebase-functions": "^2.0.5"
},
"devDependencies": {
"tslint": "~5.8.0",
"typescript": "~2.8.3"
},
"private": true
}
我该如何解决这个错误?在更改为 $ 相同的错误后,我将 npm install 用于 angular 6 和 firebase 功能,我没有看到任何区别。请帮助这是一个严重的错误,我不知道具体的版本或其他错误在哪里。
解决方案
https://github.com/firebase/firebase-tools/issues/610
我解决了这个问题,这很容易。您无需卸载。
Step1 : 打开 firebase.json 你会显示这个 JSON 文件
"functions": {
"predeploy": [
"npm --prefix \"$RESOURCE_DIR\" run lint",
"npm --prefix \"$RESOURCE_DIR\" run build"
]
}
Step2 : 删除"npm --prefix \"$RESOURCE_DIR\" run lint"
, 和"npm --prefix \"$RESOURCE_DIR\" run build"
"functions": {
"predeploy": [
]
}
第三步:firebase deploy --only functions.
Step4 : Like 并分享我的解决方案。
推荐阅读
- shortcut - mobaxterm 键盘快捷键
- nestjs - 将@ApiQuery 与nestJS 和swagger 一起使用时,有没有办法声明默认值?
- c# - 在实体框架中更新数据库
- javascript - 你能检查用户是否正在使用 Electron 查看网页吗?
- sql - “ORA-04098:触发器无效并且重新验证失败 ORA-06512:在行
- reactjs - 在 netlify 上找不到页面
- batch-file - 我想停止一个 .bat 文件,然后重新启动它
- apache-flink - 本地 Flink 作业因 OOM 失败
- regex - 正则表达式提取带有可选前缀或行首的“数字”
- swiftui - SwiftUI 中的自定义 propertyWrapper 和 @Published