Skip to content

Commit

Permalink
Updates
Browse files Browse the repository at this point in the history
  • Loading branch information
hardillb committed Sep 22, 2023
1 parent 0f30748 commit 103d88a
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
node_modules/
temp/
7 changes: 5 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,11 @@ function update() {
let latest = details.body['dist-tags'].latest
let version = details.body.versions[latest]
let tar = version.dist.tarball
fs.mkdirSync(path.dirname(path.join("temp", nodeNames[node])),{recursive: true})
let tarPath = path.join('temp', nodeNames[node] + ".tgz")
let tarDir = path.join("temp", nodeNames[node])
console.log(tarDir)
fs.mkdirSync(tarDir,{recursive: true})
let tarPath = path.join(tarDir, nodeNames[node].split('/').slice(-1) + ".tgz")
console.log(tarPath)
let tarRes = await superagent.get(tar).responseType('blob')
fs.writeFileSync(tarPath, tarRes.body)
let moduleDetails = nodeRedModule.examinTar(tarPath, "temp")
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 103d88a

Please sign in to comment.