File tree 3 files changed +3
-14
lines changed
3 files changed +3
-14
lines changed Original file line number Diff line number Diff line change @@ -92,13 +92,7 @@ const install = async (
92
92
}
93
93
}
94
94
if ( getPackageManager ( ) === `yarn` && checkForYarn ( ) ) {
95
- if ( await fs . pathExists ( `package-lock.json` ) ) {
96
- if ( ! ( await fs . pathExists ( `yarn.lock` ) ) ) {
97
- await execa ( `yarnpkg` , [ `import` ] )
98
- }
99
- await fs . remove ( `package-lock.json` )
100
- }
101
-
95
+ await fs . remove ( `package-lock.json` )
102
96
const args = packages . length ? [ `add` , silent , ...packages ] : [ silent ]
103
97
await execa ( `yarnpkg` , args )
104
98
} else {
Original file line number Diff line number Diff line change @@ -111,12 +111,7 @@ const install = async (rootPath: string): Promise<void> => {
111
111
}
112
112
}
113
113
if ( getPackageManager ( ) === `yarn` && checkForYarn ( ) ) {
114
- if ( await fs . pathExists ( `package-lock.json` ) ) {
115
- if ( ! ( await fs . pathExists ( `yarn.lock` ) ) ) {
116
- await spawn ( `yarnpkg import` )
117
- }
118
- await fs . remove ( `package-lock.json` )
119
- }
114
+ await fs . remove ( `package-lock.json` )
120
115
await spawn ( `yarnpkg` )
121
116
} else {
122
117
await fs . remove ( `yarn.lock` )
Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ for folder in $GLOB; do
29
29
30
30
if [ " $IS_WORKSPACE " = null ]; then
31
31
rm -f yarn.lock
32
- if [" $MINIMAL_STARTER " != " $NAME " ]; then # ignore minimal starter because we don't want any lock files for create-gatsby
32
+ if [ " $MINIMAL_STARTER " != " $NAME " ]; then # ignore minimal starter because we don't want any lock files for create-gatsby
33
33
yarn import # generate a new yarn.lock file based on package-lock.json, gatsby new does this is new CLI versions but will ignore if file exists
34
34
fi
35
35
fi
You can’t perform that action at this time.
0 commit comments