Fix shellcheck warnings

This commit is contained in:
jo 2021-08-16 23:00:01 +02:00
parent dc999f9006
commit 9881eebf55
17 changed files with 90 additions and 75 deletions

View file

@ -5,8 +5,8 @@ set -e
apt-get install -y --force-yes lsb-release sudo
dist=$(lsb_release -is)
code=$(lsb_release -cs)
cpu=$(getconf LONG_BIT)
cpuvalue=
# cpu=$(getconf LONG_BIT)
# cpuvalue=
#enable apt.sourcefabric.org source
set +e
@ -32,7 +32,7 @@ if [ "$dist" = "Ubuntu" ]; then
fi
#enable squeeze backports to get lame packages
if [ "$dist" = "Debian" -a "$code" = "squeeze" ]; then
if [[ "$dist" == "Debian" && "$code" == "squeeze" ]]; then
set +e
grep -E "deb http://backports.debian.org/debian-backports squeeze-backports main" /etc/apt/sources.list
returncode=$?
@ -42,12 +42,12 @@ if [ "$dist" = "Debian" -a "$code" = "squeeze" ]; then
fi
fi
echo "System is $cpu bit..."
if [ "$cpu" = "64" ]; then
cpuvalue="amd64"
else
cpuvalue="i386"
fi
# echo "System is $cpu bit..."
# if [ "$cpu" = "64" ]; then
# cpuvalue="amd64"
# else
# cpuvalue="i386"
# fi
apt-get update
apt-get -o Dpkg::Options::="--force-confold" upgrade

View file

@ -3,12 +3,12 @@
set -e
# Absolute path to this script
SCRIPT=$(readlink -f $0)
SCRIPT=$(readlink -f "$0")
# Absolute directory this script is in
SCRIPTPATH=$(dirname $SCRIPT)
SCRIPTPATH=$(dirname "$SCRIPT")
cd $SCRIPTPATH/../airtime_mvc/
cd "$SCRIPTPATH/../airtime_mvc/" || (echo "could not cd in $SCRIPTPATH/../airtime_mvc/" && exit 1)
path=$(pwd)
cd build
sed -i s:"project\.home =.*$":"project.home = $path":g build.properties
sed -i "s|\"project\.home =.*$\"|\"project.home = $path\"|g" build.properties
../../vendor/propel/propel1/generator/bin/propel-gen

View file

@ -19,13 +19,13 @@ if [ $# == 0 ]; then
exit
elif [ $# == 1 ]; then
suffix=$1
version=$1
# version=$1
else
suffix=$1-$2
version=$1
# version=$1
fi
dir=$(dirname $(readlink -f $0))
# dir=$(dirname "$(readlink -f "$0")")
gitrepo=$(readlink -f ./../../)
echo "Creating tarball for LibreTime ${suffix}."

View file

@ -22,7 +22,8 @@
#
# - When merging branches, conflicts in PO files will be marked with "#-#-#-#"
#
O=$1
# O=$1
A=$2
B=$3

View file

@ -4,8 +4,8 @@ cd ..
#generate a new .po file
#this will generate a file called messages.po
find airtime_mvc -iname "*.phtml" -o -name "*.php" | xargs xgettext -L php --from-code=UTF-8
find airtime_mvc -iname "*.phtml" -o -name "*.php" | xargs xgettext -L php --from-code=UTF-8 -k --keyword=_pro:1 -d pro --force-po
find airtime_mvc -print0 -iname "*.phtml" -o -name "*.php" | xargs xgettext -L php --from-code=UTF-8
find airtime_mvc -print0 -iname "*.phtml" -o -name "*.php" | xargs xgettext -L php --from-code=UTF-8 -k --keyword=_pro:1 -d pro --force-po
#merge the new messages from messages.po into each existing .po file
#this will generate new .po files