tests: Use env in bash scripts shebang

Bash can be in both /usr/bin/bash or /bin/bash (or elsewhere!) depending on
the distro, so let's be generic using env to figure it out.

This comes from a packaging lintian error we get:

 E: mutter-16-tests: wrong-path-for-interpreter /usr/bin/bash != /bin/bash
    [usr/share/mutter-16/tests/socket-launch.sh]

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/4288>
This commit is contained in:
Marco Trevisan (Treviño) 2025-02-18 16:30:39 +01:00 committed by Marge Bot
parent fac0854a4f
commit 169ea4cf81
5 changed files with 5 additions and 5 deletions

View File

@ -1,4 +1,4 @@
#!/bin/sh
#!/usr/bin/env sh
outputfile=$1
shift

View File

@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
set -e

View File

@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
set -e

View File

@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
export LISTEN_PID=$$
exec "$@"

View File

@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
set -ex