From dcda342eccd152fe69521d59de016ef09b70400c Mon Sep 17 00:00:00 2001 From: Marek Mahut Date: Thu, 22 Apr 2021 23:45:33 +0200 Subject: [PATCH] use /usr/bin/env to find bash in scripts (#314) --- src/Misc/externals.sh | 2 +- src/Misc/layoutbin/darwin.svc.sh.template | 2 +- src/Misc/layoutbin/installdependencies.sh | 2 +- src/Misc/layoutbin/runsvc.sh | 2 +- src/Misc/layoutbin/systemd.svc.sh.template | 2 +- src/Misc/layoutbin/update.sh.template | 2 +- src/Misc/layoutroot/config.sh | 2 +- src/Misc/layoutroot/env.sh | 2 +- src/Misc/layoutroot/run.sh | 2 +- src/dev.sh | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/Misc/externals.sh b/src/Misc/externals.sh index bc90fea1c..55e05f28a 100755 --- a/src/Misc/externals.sh +++ b/src/Misc/externals.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash PACKAGERUNTIME=$1 PRECACHE=$2 diff --git a/src/Misc/layoutbin/darwin.svc.sh.template b/src/Misc/layoutbin/darwin.svc.sh.template index 8d2f96512..4986b20ab 100644 --- a/src/Misc/layoutbin/darwin.svc.sh.template +++ b/src/Misc/layoutbin/darwin.svc.sh.template @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash SVC_NAME="{{SvcNameVar}}" SVC_NAME=${SVC_NAME// /_} diff --git a/src/Misc/layoutbin/installdependencies.sh b/src/Misc/layoutbin/installdependencies.sh index 786714925..e58f5004a 100755 --- a/src/Misc/layoutbin/installdependencies.sh +++ b/src/Misc/layoutbin/installdependencies.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash user_id=`id -u` diff --git a/src/Misc/layoutbin/runsvc.sh b/src/Misc/layoutbin/runsvc.sh index 1919b9c21..695968deb 100755 --- a/src/Misc/layoutbin/runsvc.sh +++ b/src/Misc/layoutbin/runsvc.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # convert SIGTERM signal to SIGINT # for more info on how to propagate SIGTERM to a child process see: http://veithen.github.io/2014/11/16/sigterm-propagation.html diff --git a/src/Misc/layoutbin/systemd.svc.sh.template b/src/Misc/layoutbin/systemd.svc.sh.template index bdbc998f7..df00e75e6 100644 --- a/src/Misc/layoutbin/systemd.svc.sh.template +++ b/src/Misc/layoutbin/systemd.svc.sh.template @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash SVC_NAME="{{SvcNameVar}}" SVC_NAME=${SVC_NAME// /_} diff --git a/src/Misc/layoutbin/update.sh.template b/src/Misc/layoutbin/update.sh.template index c09cc1d5b..d7eeacac6 100644 --- a/src/Misc/layoutbin/update.sh.template +++ b/src/Misc/layoutbin/update.sh.template @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # runner will replace key words in the template and generate a batch script to run. # Keywords: diff --git a/src/Misc/layoutroot/config.sh b/src/Misc/layoutroot/config.sh index 116024596..025f414f7 100755 --- a/src/Misc/layoutroot/config.sh +++ b/src/Misc/layoutroot/config.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash user_id=`id -u` diff --git a/src/Misc/layoutroot/env.sh b/src/Misc/layoutroot/env.sh index cfe1a2caf..51544f350 100755 --- a/src/Misc/layoutroot/env.sh +++ b/src/Misc/layoutroot/env.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash varCheckList=( 'LANG' diff --git a/src/Misc/layoutroot/run.sh b/src/Misc/layoutroot/run.sh index 827290ec4..f4c756ab6 100755 --- a/src/Misc/layoutroot/run.sh +++ b/src/Misc/layoutroot/run.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # Validate not sudo user_id=`id -u` diff --git a/src/dev.sh b/src/dev.sh index 43474c68c..66ee5616a 100755 --- a/src/dev.sh +++ b/src/dev.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash ############################################################################### #