diff options
-rw-r--r-- | scripts/add_github.js | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/add_github.js b/scripts/add_github.js index add3575..543e347 100644 --- a/scripts/add_github.js +++ b/scripts/add_github.js | |||
@@ -57,6 +57,8 @@ const compressed = path.join(__dirname, 'tmp.tar.gz'); | |||
57 | console.log("Creating temporary directory"); | 57 | console.log("Creating temporary directory"); |
58 | 58 | ||
59 | await fs.ensureDir(tempDir); | 59 | await fs.ensureDir(tempDir); |
60 | await fs.ensureDir(recipeSrc); | ||
61 | await fs.ensureDir(recipeSrcTmp); | ||
60 | 62 | ||
61 | console.log("Downloading " + repo); | 63 | console.log("Downloading " + repo); |
62 | 64 | ||
@@ -71,10 +73,11 @@ const compressed = path.join(__dirname, 'tmp.tar.gz'); | |||
71 | 73 | ||
72 | console.log("Moving directories"); | 74 | console.log("Moving directories"); |
73 | 75 | ||
74 | await fs.move(recipeSrc, recipeSrcTmp); | 76 | await fs.move(recipeSrc, recipeSrcTmp, {overwrite: true}); |
75 | await fs.move( | 77 | await fs.move( |
76 | path.join(tempDir, `${repoInfo.name}-master`), | 78 | path.join(tempDir, `${repoInfo.name}-master`), |
77 | recipeSrc | 79 | recipeSrc, |
80 | {overwrite: true} | ||
78 | ); | 81 | ); |
79 | 82 | ||
80 | console.log("Adding to repository"); | 83 | console.log("Adding to repository"); |