-
-
Notifications
You must be signed in to change notification settings - Fork 153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use existing bash instance when running destroyScript #593
Use existing bash instance when running destroyScript #593
Conversation
hmm, not sure how portable that is. but it works in the tests, so let's hope it doesn't break anyones usecase |
@mergify queue |
🛑 The pull request has been removed from the queue
|
@@ -449,7 +449,7 @@ let | |||
|
|||
# shellcheck disable=SC2043 | |||
for dev in ${toString (lib.catAttrs "device" (lib.attrValues devices.disk))}; do | |||
${../disk-deactivate}/disk-deactivate "$dev" | |||
$BASH ${../disk-deactivate}/disk-deactivate "$dev" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need this?
$BASH ${../disk-deactivate}/disk-deactivate "$dev" | |
${BASH:-} ${../disk-deactivate}/disk-deactivate "$dev" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Applied this change
69821f5
to
e3448ff
Compare
@mergify rebase |
The destroy script already has a bash interpreter in use, but when the `disk-deactivate` script is ran, it calls out to /usr/bin/env to query for a bash interpreter. When running the destroyScript in unique places (such as the stage-1 initrd), /usr/bin/env might not exist, so we can make destroyScript more self-contained by reusing the same bash.
✅ Branch has been successfully rebased |
e3448ff
to
82783db
Compare
@mergify queue |
✅ The pull request has been merged automaticallyThe pull request has been merged automatically at 8d4ae69 |
The destroy script already has a bash interpreter in use, but when the
disk-deactivate
script is ran, it calls out to /usr/bin/env to query for a bash interpreter. When running the destroyScript in unique places (such as the stage-1 initrd), /usr/bin/env might not exist, so we can make destroyScript more self-contained by reusing the same bash.