Skip to content

Commit

Permalink
fixup quoting
Browse files Browse the repository at this point in the history
  • Loading branch information
seanbudd committed Sep 6, 2024
1 parent d9b5e43 commit 43eb1e1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/checkAddonUrlAndHash.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ module.exports = ({core}, globPattern) => {
const sha256 = addonMetadata.sha256;
const hash = crypto.createHash('sha256');
exec(
`curl --fail --silent --show-error --location --output ${addonId}.nvda-addon "${addonMetadata.URL}"`,
`curl --fail --silent --show-error --location --output "${addonId}.nvda-addon" "${addonMetadata.URL}"`,
// increase maxBuffer size to 10GB
{ maxBuffer: 1024 * 1024 * 1024 * 10 },
(err, stdout, stderr) => {
Expand All @@ -21,7 +21,7 @@ module.exports = ({core}, globPattern) => {
console.log(`stdout: ${stdout}`);
console.log(`stderr: ${stderr}`);
// delete file if download failed
exec(`rm ${file}`, (err, stdout, stderr) => {
exec(`rm "${file}"`, (err, stdout, stderr) => {
if (stderr !== '' || err !== null) {
console.log(`err: ${err}`);
console.log(`stdout: ${stdout}`);
Expand All @@ -41,7 +41,7 @@ module.exports = ({core}, globPattern) => {
fileStream.on('end', () => {
const fileHash = hash.digest('hex');
if (fileHash !== sha256) {
exec(`rm ${file}`, (err, stdout, stderr) => {
exec(`rm "${file}"`, (err, stdout, stderr) => {
if (stderr !== '' || err !== null) {
console.log(`err: ${err}`);
console.log(`stderr: ${stderr}`);
Expand Down

0 comments on commit 43eb1e1

Please sign in to comment.