X Tutup
Skip to content

Commit ff12a79

Browse files
Mic92keszybz
authored andcommitted
treewide: more portable bash shebangs
As in 2a5fcfa and in 3e67e5c using /usr/bin/env allows bash to be looked up in PATH rather than being hard-coded. As with the previous changes the same arguments apply - distributions have scripts to rewrite shebangs on installation and they know what locations to rely on. - For tests/compilation we should rather rely on the user to have setup there PATH correctly. In particular this makes testing from git easier on NixOS where do not provide /bin/bash to improve compose-ability.
1 parent eda0cbf commit ff12a79

File tree

94 files changed

+114
-109
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

94 files changed

+114
-109
lines changed

configure

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
#!/bin/bash -e
1+
#!/usr/bin/env bash
2+
set -e
23

34
cflags=CFLAGS="$CFLAGS"
45
cxxflags=CXXFLAGS="$CXXFLAGS"

src/basic/linux/update.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
set -eu
44

src/kernel-install/00-entry-directory.install

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
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*-
33
# ex: ts=8 sw=4 sts=4 et filetype=sh
44

src/kernel-install/50-depmod.install

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
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*-
33
# ex: ts=8 sw=4 sts=4 et filetype=sh
44

src/kernel-install/90-loaderentry.install

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
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*-
33
# ex: ts=8 sw=4 sts=4 et filetype=sh
44

src/kernel-install/kernel-install

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
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*-
33
# ex: ts=8 sw=4 sts=4 et filetype=sh
44
# SPDX-License-Identifier: LGPL-2.1+

test/TEST-01-BASIC/test.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
set -e
33
TEST_DESCRIPTION="Basic systemd setup"
44
RUN_IN_UNPRIVILEGED_CONTAINER=${RUN_IN_UNPRIVILEGED_CONTAINER:-yes}

test/TEST-02-CRYPTSETUP/test.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
set -e
33
TEST_DESCRIPTION="cryptsetup systemd setup"
44
TEST_NO_NSPAWN=1

test/TEST-03-JOBS/test-jobs.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
#!/bin/bash -ex
1+
#!/usr/bin/env bash
2+
set -ex
23

34
# Test merging of a --job-mode=ignore-dependencies job into a previously
45
# installed job.

test/TEST-03-JOBS/test.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
set -e
33
TEST_DESCRIPTION="Job-related tests"
44
TEST_NO_QEMU=1

0 commit comments

Comments
 (0)
X Tutup