From df895cb2a733c7e7f64ff65075ee64398b95f5d1 Mon Sep 17 00:00:00 2001 From: Chocobo1 Date: Mon, 24 Apr 2023 13:22:53 +0800 Subject: [PATCH] Improve script compatibility Now the script is conforms to POSIX shell script which is universal on all linux. Also make it executable. --- .github/workflows/helper/appimage/export_vars.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) mode change 100644 => 100755 .github/workflows/helper/appimage/export_vars.sh diff --git a/.github/workflows/helper/appimage/export_vars.sh b/.github/workflows/helper/appimage/export_vars.sh old mode 100644 new mode 100755 index cbedc852e..d23b2166c --- a/.github/workflows/helper/appimage/export_vars.sh +++ b/.github/workflows/helper/appimage/export_vars.sh @@ -1,10 +1,12 @@ +#!/bin/sh + # this file is called from AppRun so 'root_dir' will point to where AppRun is root_dir="$(readlink -f "$(dirname "$0")")" # Insert the default values because after the test we prepend our path # and it will create problems with DEs (eg KDE) that don't set the variable # and rely on the default paths -if [[ -z ${XDG_DATA_DIRS} ]]; then +if [ -z "${XDG_DATA_DIRS}" ]; then XDG_DATA_DIRS="/usr/local/share/:/usr/share/" fi