This repository was archived by the owner on Dec 8, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +10
-7
lines changed Expand file tree Collapse file tree 2 files changed +10
-7
lines changed Original file line number Diff line number Diff line change 1313 "gg" : " dist/index.js"
1414 },
1515 "scripts" : {
16- "clean" : " rm -rf ./src/tests/**/tmp && rm -rf ./src/tests/**/generated" ,
17- "prepublishOnly" : " rm -rf example/node_modules && yarn test && yarn build" ,
16+ "clean" : " rm -rf ./src/tests/**/tmp && rm -rf ./src/tests/**/generated && rm -rf ./dist" ,
17+ "prepublishOnly" : " rm -rf example/node_modules && yarn checks && yarn test && yarn build" ,
18+ "postpublish" : " yarn clean" ,
1819 "benchmarks" : " ts-node benchmarks" ,
19- "build" : " yarn clean && yarn lint && tsc --declaration" ,
20+ "build" : " yarn clean && tsc --declaration" ,
2021 "watch" : " tsc --watch" ,
21- "lint" : " tslint --project tsconfig.json {src,test}/**/*.ts" ,
22- "test" : " jest" ,
2322 "check:types" : " yarn tsc --noEmit" ,
23+ "check:lint" : " tslint --project tsconfig.json {src,test}/**/*.ts" ,
24+ "checks" : " yarn check:types && yarn check:lint" ,
25+ "test" : " jest" ,
2426 "test:watch" : " jest --watch" ,
25- "test:ci" : " yarn lint && jest --maxWorkers 4" ,
27+ "test:ci" : " yarn check: lint && jest --maxWorkers 4" ,
2628 "gen" : " ts-node --files src/index.ts"
2729 },
2830 "repository" : {
Original file line number Diff line number Diff line change @@ -90,7 +90,8 @@ export function parseSchema(schemaPath: string): GraphQLTypes {
9090 // We can assume absolute path is cwd prefixed because
9191 // gg currently only works when run in a directory with the
9292 // graphqlgen manifest.
93- const absoluteFilePath = Path . join ( process . cwd ( ) , filePath )
93+ const absoluteFilePath =
94+ filePath [ 0 ] == '/' ? filePath : Path . join ( process . cwd ( ) , filePath )
9495
9596 if ( ! fs . existsSync ( absoluteFilePath ) ) {
9697 console . error (
You can’t perform that action at this time.
0 commit comments