mirror of
https://github.com/sourcegit-scm/sourcegit.git
synced 2024-12-25 21:07:20 -08:00
build: minor tweaks
* call bash through env progrem * add more strict defaults * [ -> [[ Signed-off-by: Maciej Barć <xgqt@gentoo.org>
This commit is contained in:
parent
67b3952080
commit
6461765cf7
3 changed files with 19 additions and 10 deletions
|
@ -1,13 +1,16 @@
|
||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
set -o
|
||||||
|
set -u
|
||||||
|
set pipefail
|
||||||
|
|
||||||
if [ -z "$VERSION" ]; then
|
if [[ -z "$VERSION" ]]; then
|
||||||
echo "Provide the version as environment variable VERSION"
|
echo "Provide the version as environment variable VERSION"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$RUNTIME" ]; then
|
if [[ -z "$RUNTIME" ]]; then
|
||||||
echo "Provide the runtime as environment variable RUNTIME"
|
echo "Provide the runtime as environment variable RUNTIME"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
@ -33,7 +36,7 @@ APPIMAGETOOL_URL=https://github.com/AppImage/appimagetool/releases/download/cont
|
||||||
|
|
||||||
cd build
|
cd build
|
||||||
|
|
||||||
if [ ! -f "appimagetool" ]; then
|
if [[ ! -f "appimagetool" ]]; then
|
||||||
curl -o appimagetool -L "$APPIMAGETOOL_URL"
|
curl -o appimagetool -L "$APPIMAGETOOL_URL"
|
||||||
chmod +x appimagetool
|
chmod +x appimagetool
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -1,13 +1,16 @@
|
||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
set -o
|
||||||
|
set -u
|
||||||
|
set pipefail
|
||||||
|
|
||||||
if [ -z "$VERSION" ]; then
|
if [[ -z "$VERSION" ]]; then
|
||||||
echo "Provide the version as environment variable VERSION"
|
echo "Provide the version as environment variable VERSION"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$RUNTIME" ]; then
|
if [[ -z "$RUNTIME" ]]; then
|
||||||
echo "Provide the runtime as environment variable RUNTIME"
|
echo "Provide the runtime as environment variable RUNTIME"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -1,13 +1,16 @@
|
||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
set -o
|
||||||
|
set -u
|
||||||
|
set pipefail
|
||||||
|
|
||||||
if [ -z "$VERSION" ]; then
|
if [[ -z "$VERSION" ]]; then
|
||||||
echo "Provide the version as environment variable VERSION"
|
echo "Provide the version as environment variable VERSION"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$RUNTIME" ]; then
|
if [[ -z "$RUNTIME" ]]; then
|
||||||
echo "Provide the runtime as environment variable RUNTIME"
|
echo "Provide the runtime as environment variable RUNTIME"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue