diff options
Diffstat (limited to 'pkgs/development/mobile/xcodeenv/build-app.nix')
-rw-r--r-- | pkgs/development/mobile/xcodeenv/build-app.nix | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/pkgs/development/mobile/xcodeenv/build-app.nix b/pkgs/development/mobile/xcodeenv/build-app.nix index ade629759f0..1b4940b0c3d 100644 --- a/pkgs/development/mobile/xcodeenv/build-app.nix +++ b/pkgs/development/mobile/xcodeenv/build-app.nix @@ -15,9 +15,15 @@ , provisioningProfile ? null , generateIPA ? false , generateXCArchive ? false +, enableWirelessDistribution ? false +, installURL ? null +, bundleId ? null +, version ? null +, title ? null }: assert release -> codeSignIdentity != null && certificateFile != null && certificatePassword != null && provisioningProfile != null; +assert enableWirelessDistribution -> installURL != null && bundleId != null && version != null && title != null; let # Set some default values here @@ -60,7 +66,7 @@ stdenv.mkDerivation { security import ${certificateFile} -k $keychainName -P "${certificatePassword}" -A # Determine provisioning ID - PROVISIONING_PROFILE=$(grep UUID -A1 -a ${provisioningProfile} | grep -o "[-A-Z0-9]\{36\}") + PROVISIONING_PROFILE=$(grep UUID -A1 -a ${provisioningProfile} | grep -o "[-A-Za-z0-9]\{36\}") if [ ! -f "$HOME/Library/MobileDevice/Provisioning Profiles/$PROVISIONING_PROFILE.mobileprovision" ] then @@ -84,6 +90,12 @@ stdenv.mkDerivation { # Add IPA to Hydra build products mkdir -p $out/nix-support echo "file binary-dist \"$(echo $out/*.ipa)\"" > $out/nix-support/hydra-build-products + + ${stdenv.lib.optionalString enableWirelessDistribution '' + appname=$(basename $out/*.ipa .ipa) + sed -e "s|@INSTALL_URL@|${installURL}?bundleId=${bundleId}\&version=${version}\&title=$appname|" ${./install.html.template} > $out/$appname.html + echo "doc install \"$out/$appname.html\"" >> $out/nix-support/hydra-build-products + ''} ''} # Delete our temp keychain |