Skip to content

Commit

Permalink
Use bash in post-build hook
Browse files Browse the repository at this point in the history
  • Loading branch information
sandydoo committed Apr 25, 2024
1 parent ad440c0 commit 7431d10
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions dist/main/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -7957,14 +7957,14 @@ async function execToVariable(command, args, options) {
async function registerPostBuildHook(cachixBin, daemonDir) {
const postBuildHookScriptPath = `${daemonDir}/post-build-hook.sh`;
await fs.writeFile(postBuildHookScriptPath, `
#!/bin/sh
#!/usr/bin/env bash
set -eu
set -f # disable globbing
PUSH_FILTER="${pushFilter}"
function filterPaths {
filterPaths() {
local regex=$1
local paths=$2
Expand Down
4 changes: 2 additions & 2 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -276,14 +276,14 @@ async function execToVariable(command: string, args?: string[], options?: exec.E
async function registerPostBuildHook(cachixBin: string, daemonDir: string) {
const postBuildHookScriptPath = `${daemonDir}/post-build-hook.sh`;
await fs.writeFile(postBuildHookScriptPath, `
#!/bin/sh
#!/usr/bin/env bash
set -eu
set -f # disable globbing
PUSH_FILTER="${pushFilter}"
function filterPaths {
filterPaths() {
local regex=$1
local paths=$2
Expand Down

0 comments on commit 7431d10

Please sign in to comment.