Skip to content

Commit

Permalink
save
Browse files Browse the repository at this point in the history
  • Loading branch information
jcbhmr committed Apr 11, 2024
1 parent 111104e commit 411a4aa
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/npm-generate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,4 @@ jobs:
- run: npm run build
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
9 changes: 7 additions & 2 deletions run.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,18 @@ async function generate() {
const url = `https://github.com/git-for-windows/git/releases/download/v${gfwVersion}/${filename}`;
console.debug("url %o", url);
const response = await fetch(url);
await response.body.pipeTo(Writable.toWeb(createWriteStream("PortableGit-64-bit.7z.exe")));
await response.body.pipeTo(
Writable.toWeb(createWriteStream("PortableGit-64-bit.7z.exe")),
);
console.log("downloaded %o to %o", url, "PortableGit-64-bit.7z.exe");
}

async function build() {
await mkdir("out", { recursive: true });
await $({ stdio: "inherit", cwd: "out" })`7z x -aos ../PortableGit-64-bit.7z.exe`;
await $({
stdio: "inherit",
cwd: "out",
})`7z x -aos ../PortableGit-64-bit.7z.exe`;
console.log("extracted to %o", "out");
}

Expand Down

0 comments on commit 411a4aa

Please sign in to comment.