We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a63c920 commit acc771aCopy full SHA for acc771a
packages/core/update/Update.ts
@@ -208,10 +208,12 @@ function updateWorkflows(
208
209
for (const fileName of workflowFiles) {
210
const workflowPath = `.github/workflows/${fileName}`;
211
- let workflow = fs.readFile(workflowPath);
212
- if (workflow) {
213
- workflow = workflow.replace(oldNpmInstall, newNpmInstall);
214
- fs.writeFile(workflowPath, workflow);
+ if (fs.fileExists(workflowPath)) {
+ let workflow = fs.readFile(workflowPath);
+ if (workflow) {
+ workflow = workflow.replace(oldNpmInstall, newNpmInstall);
215
+ fs.writeFile(workflowPath, workflow);
216
+ }
217
}
218
219
0 commit comments