Skip to content

Commit 6c5ae56

Browse files
ryaneitaysk
authored andcommitted
change bash shebangs to be more portable
When running kubectl-neat tests on a nixos system, I was getting test failures like the following: ``` --- FAIL: TestGetCmd (0.00s) cmd_test.go:186: error assertion: have: &errors.errorString{s:"Error invoking kubectl as [../test/kubectl-stub get -o json pods] fork/exec ../test/kubectl-stub: no such file or directory"} test case: {[pods] 0x1021740 apiVersion } ``` And running the script directly: ``` $ ./test/kubectl-stub zsh: ./test/kubectl-stub: bad interpreter: /bin/bash: no such file or directory ``` This PR changes the shebang to `#!/usr/bin/env bash` to make the tests more portable across systems. I changed the other bash shebangs for good measure.
1 parent 4c647f3 commit 6c5ae56

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

hack/update-kubernetes-deps.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/bin/bash
1+
#!/usr/bin/env bash
22

33
VERSION=${1#"v"}
44
if [ -z "$VERSION" ]; then

krew-package.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#! /bin/bash
1+
#!/usr/bin/env bash
22
# This script makes a platform specific krew package
33
# it assumes goreleaser had already run and created the archives and the checksums
44
# Arguments:

test/kubectl-stub

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/bin/bash
1+
#!/usr/bin/env bash
22
#
33
# based on Argbash: https://argbash.io
44

0 commit comments

Comments
 (0)