Skip to content

Commit

Permalink
Stop GitHub from trolling
Browse files Browse the repository at this point in the history
  • Loading branch information
I-Al-Istannen committed Jan 7, 2025
1 parent b750eb2 commit fddec64
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,22 @@
};
in
pkgs.mkShell rec {
shellHook = ''
if [ "$LANG" = "C.UTF-8" ]; then
echo "You are using the C locale. Tests will fail. Changing it to en_US if possible"
if locale -a | grep -iP "en_us.utf(-?)8"; then
echo "Changing your locale to en_US.UTF-8"
export LANG=en_US.UTF-8
else
echo "You do not have en_US.UTF-8 installed ('localectl list-locales'/'locale -a')"
echo "Please change it something else yourself"
fi
fi
'';
test = pkgs.writeScriptBin "test" ''
set -eu
env
# Use silent log config
cp chore/logback.xml src/test/resources/
mvn -f spoon-pom -B test-compile
Expand Down

0 comments on commit fddec64

Please sign in to comment.