SummerCart64/docker_build.sh
Polprzewodnikowy 3d1daf3fc6 some changes
2021-11-25 23:11:36 +01:00

19 lines
440 B
Bash
Executable File

#!/bin/bash
GIT_SHA=$(git rev-parse --short HEAD)
GIT_TAG=$(git describe --tags --exact-match 2> /dev/null)
if [ ! -z "$GIT_TAG" ]; then
__SC64_VERSION="git tag: $GIT_TAG"
else
__SC64_VERSION="git sha: $GIT_SHA"
fi
docker run \
--rm \
--user $(id -u):$(id -g) \
--mount type=bind,src="$(pwd)",target="/workdir" \
-e __SC64_VERSION="$__SC64_VERSION" \
ghcr.io/polprzewodnikowy/sc64env:v1.2 \
./build.sh $@