Skip to content

Commit

Permalink
nix: android builds to access network for debug
Browse files Browse the repository at this point in the history
  • Loading branch information
siddarthkay committed Aug 30, 2024
1 parent 1ffbabb commit 5715872
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion nix/mobile/android/build.nix
Original file line number Diff line number Diff line change
Expand Up @@ -149,10 +149,12 @@ in stdenv.mkDerivation rec {
buildPhase = let
adhocEnvVars = optionalString stdenv.isLinux
"LD_LIBRARY_PATH=$LD_LIBRARY_PATH:${makeLibraryPath [ pkgs.zlib ]}";
# For debug builds devs should have a chance of getting dependencies from network
offlineFlag = if (buildType != "debug") then "--offline " else "" ;
gradleCommand = ''
${pkgs.gradle}/bin/gradle \
--console=plain \
--offline \
${offlineFlag} \
--no-daemon \
--no-scan \
--no-watch-fs \
Expand Down

0 comments on commit 5715872

Please sign in to comment.