File tree Expand file tree Collapse file tree 3 files changed +16
-19
lines changed Expand file tree Collapse file tree 3 files changed +16
-19
lines changed Original file line number Diff line number Diff line change 17
17
"dateformat" : " 3.x" ,
18
18
"dot-prop" : " 5.x" ,
19
19
"glob" : " 7.x" ,
20
+ "js-yaml" : " 3.x" ,
20
21
"pretty-hrtime" : " 1.x" ,
21
22
"shelljs" : " 0.x" ,
22
23
"winston" : " 3.x" ,
23
- "yaml" : " 1.X" ,
24
24
"yargs" : " 15.x"
25
25
},
26
26
"pkg" : {
31
31
"author" : " Mads Jon Nielsen <madsjon@gmail.com>" ,
32
32
"license" : " ISC" ,
33
33
"devDependencies" : {
34
+ "@types/js-yaml" : " ^3.12.1" ,
34
35
"@types/pretty-hrtime" : " 1.x" ,
35
36
"@types/shelljs" : " 0.x" ,
36
37
"@types/yaml" : " 1.x" ,
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ import c = require("ansi-colors");
2
2
import * as dotProp from "dot-prop" ;
3
3
import fs = require( "fs" ) ;
4
4
import * as winston from "winston" ;
5
- import yaml = require( "yaml" ) ;
5
+ import yaml = require( "js- yaml" ) ;
6
6
import yargs = require( "yargs" ) ;
7
7
import { Job } from "./job" ;
8
8
@@ -30,7 +30,7 @@ if (!fs.existsSync(gitlabCiYmlPath)) {
30
30
process . exit ( 1 ) ;
31
31
}
32
32
const gitlabCiContent = fs . readFileSync ( gitlabCiYmlPath , "utf8" ) ;
33
- const gitlabCiData = yaml . parse ( gitlabCiContent ) ;
33
+ const gitlabCiData = yaml . safeLoad ( gitlabCiContent ) ;
34
34
35
35
// Parse .gitlab-local.yml
36
36
const gitlabCiLocalYmlPath = `${ cwd } /.gitlab-ci.local.yml` ;
@@ -39,7 +39,7 @@ if (!fs.existsSync(gitlabCiLocalYmlPath)) {
39
39
process . exit ( 1 ) ;
40
40
}
41
41
const gitlabCiLocalContent = fs . readFileSync ( gitlabCiLocalYmlPath , "utf8" ) ;
42
- const gitlabLocalData = yaml . parse ( gitlabCiLocalContent ) ;
42
+ const gitlabLocalData = yaml . safeLoad ( gitlabCiLocalContent ) ;
43
43
44
44
const jobs = new Map < string , Job > ( ) ;
45
45
const stages = new Map < string , Job [ ] > ( ) ;
You can’t perform that action at this time.
0 commit comments