build: drop the agent-specific gradle wrapper from the devshell

The flock/nice/worker-cap wrapper serialised local builds to protect the
shared box. That is now handled at the machine level (a GRADLE_OPTS cap
in nix-home), so the devshell goes back to the plain nix Gradle.
This commit is contained in:
austinried
2026-10-09 09:11:54 +00:00
parent 779131c766
commit 15d77f998f
2 changed files with 1 additions and 24 deletions
+1 -23
View File
@@ -40,31 +40,9 @@
};
androidSdk = android.androidsdk;
gradle_wrapper = pkgs.writeShellScriptBin "gradle" ''
if [ -n "''${CI:-}" ]; then
exec ${pkgs.gradle_9}/bin/gradle "$@"
fi
for arg in "$@"; do
case "$arg" in
-v | --version | --status | --stop)
exec ${pkgs.gradle_9}/bin/gradle "$@"
;;
esac
done
runtime_dir="''${XDG_RUNTIME_DIR:-''${HOME:-/tmp}/.cache}"
mkdir -p "$runtime_dir"
lock="$runtime_dir/subtracks-gradle.lock"
if ! ${pkgs.util-linux}/bin/flock -n "$lock" ${pkgs.coreutils}/bin/true 2>/dev/null; then
echo "gradle: waiting for the build lock at $lock" >&2
fi
export GRADLE_OPTS="''${GRADLE_OPTS:-} -Dorg.gradle.workers.max=4"
exec ${pkgs.util-linux}/bin/flock "$lock" \
${pkgs.coreutils}/bin/nice -n 10 ${pkgs.gradle_9}/bin/gradle "$@"
'';
basePackages = [
pkgs.jdk21
gradle_wrapper
pkgs.gradle_9
pkgs.git
pkgs.curl
pkgs.unzip