diff --git a/pkgs/applications/editors/android-studio/common.nix b/pkgs/applications/editors/android-studio/common.nix index 698602085fe..cd031ce5ac8 100644 --- a/pkgs/applications/editors/android-studio/common.nix +++ b/pkgs/applications/editors/android-studio/common.nix @@ -37,8 +37,9 @@ }: let + drvName = "android-studio-${channel}-${version}"; androidStudio = stdenv.mkDerivation { - name = "${pname}-${version}"; + name = drvName; src = fetchurl { url = "https://dl.google.com/dl/android/studio/ide-zips/${version}/android-studio-ide-${build}-linux.zip"; @@ -116,18 +117,19 @@ let # (e.g. `mksdcard`) have `/lib/ld-linux.so.2` set as the interpreter. An FHS # environment is used as a work around for that. fhsEnv = buildFHSUserEnv { - name = "${pname}-fhs-env"; + name = "${drvName}-fhs-env"; multiPkgs = pkgs: [ pkgs.ncurses5 ]; }; in writeTextFile { - name = "${pname}-${version}"; + name = "${drvName}-wrapper"; + # TODO: Rename preview -> beta (and add -stable suffix?): destination = "/bin/${pname}"; executable = true; text = '' #!${bash}/bin/bash - ${fhsEnv}/bin/${pname}-fhs-env ${androidStudio}/bin/studio.sh + ${fhsEnv}/bin/${drvName}-fhs-env ${androidStudio}/bin/studio.sh ''; } // { meta = with stdenv.lib; { diff --git a/pkgs/applications/editors/android-studio/default.nix b/pkgs/applications/editors/android-studio/default.nix index 73f2724f0e1..b60687c50ba 100644 --- a/pkgs/applications/editors/android-studio/default.nix +++ b/pkgs/applications/editors/android-studio/default.nix @@ -26,18 +26,16 @@ in rec { # Old alias preview = beta; - # Attributes are named by the corresponding release channels + # Attributes are named by their corresponding release channels stable = mkStudio (stableVersion // { channel = "stable"; pname = "android-studio"; - #pname = "android-studio-stable"; # TODO: Rename and provide symlink }); beta = mkStudio (betaVersion // { channel = "beta"; pname = "android-studio-preview"; - #pname = "android-studio-beta"; # TODO: Rename and provide symlink }); dev = mkStudio (latestVersion // {