File tree Expand file tree Collapse file tree 2 files changed +6
-7
lines changed Expand file tree Collapse file tree 2 files changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -51,14 +51,13 @@ function findProjectDir(pkgdir) {
51
51
}
52
52
53
53
function _isNativeScriptAppRoot ( dir ) {
54
- var isNativeScriptAppRoot = false ;
55
- var packageJsonFile = path . join ( dir , 'package.json' ) ;
56
- if ( fs . existsSync ( packageJsonFile ) ) {
57
- var packageJsonContent = require ( packageJsonFile ) ;
58
- isNativeScriptAppRoot = ! ! packageJsonContent . nativescript && ! ! packageJsonContent . nativescript . id ;
54
+ var tsConfig = path . join ( dir , 'nativescript.config.ts' ) ;
55
+ var jsConfig = path . join ( dir , 'nativescript.config.js' ) ;
56
+ if ( fs . existsSync ( tsConfig ) || fs . existsSync ( jsConfig ) ) {
57
+ return true ;
59
58
}
60
59
61
- return isNativeScriptAppRoot ;
60
+ return false ;
62
61
}
63
62
64
63
function forEachHook ( pkgdir , callback ) {
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @nativescript/hook" ,
3
- "version" : " 1 .0.0" ,
3
+ "version" : " 2 .0.0" ,
4
4
"description" : " Helper module for installing hooks into NativeScript projects" ,
5
5
"main" : " index.js" ,
6
6
"scripts" : {
You can’t perform that action at this time.
0 commit comments