mirror of
https://github.com/wesnoth/wesnoth
synced 2025-04-27 17:26:23 +00:00

@Pentarctagon noticed in commit 9a34cbb3291 that $UID isn't set when /bin/sh isn't GNU Bash. `id -u` is specified by POSIX: https://pubs.opengroup.org/onlinepubs/9699919799.2018edition/utilities/id.html Also move `-xe` to a `set` command (in case someone runs scripts with `sh path/to/script` instead of `path/to/script`) and add `set -u` to complain more loudly about such unset variables.
10 lines
217 B
Bash
Executable File
10 lines
217 B
Bash
Executable File
#!/bin/sh
|
|
|
|
set -xeu
|
|
|
|
cd mingw
|
|
docker build -t mingw-wesnoth .
|
|
rm -rf ../mingwbuild
|
|
mkdir ../mingwbuild
|
|
docker run -v "$PWD"/../../..:/wesnoth -v "$PWD"/../mingwbuild:/output --tmpfs /build -u "$(id -u)" mingw-wesnoth
|