33 lines
747 B
Nix
33 lines
747 B
Nix
{ pkgs }:
|
|
|
|
with pkgs;
|
|
|
|
# Configure your development environment.
|
|
#
|
|
# Documentation: https://github.com/numtide/devshell
|
|
devshell.mkShell {
|
|
name = "android-project";
|
|
motd = ''
|
|
Entered the Android app development environment.
|
|
'';
|
|
env = [
|
|
{
|
|
name = "ANDROID_HOME";
|
|
value = "${android-sdk}/share/android-sdk";
|
|
}
|
|
{
|
|
name = "ANDROID_SDK_ROOT";
|
|
value = "${android-sdk}/share/android-sdk";
|
|
}
|
|
{
|
|
name = "JAVA_HOME";
|
|
value = jdk11.home;
|
|
}
|
|
];
|
|
packages = [
|
|
android-sdk
|
|
( pkgs.writeShellScriptBin "gradle" ''
|
|
exec env "ORG_GRADLE_PROJECT_android.aapt2FromMavenOverride"="${android-sdk}/share/android-sdk/build-tools/32.0.0/aapt2" '${gradle}/bin/gradle' $@
|
|
'')
|
|
];
|
|
}
|