Implemented wireless adhoc distribution support for titanium apps
This commit is contained in:
parent
bffdf03e4f
commit
7eb93f944b
@ -2,10 +2,12 @@
|
||||
{ name, src, target, androidPlatformVersions ? [ "8" ], androidAbiVersions ? [ "armeabi" "armeabi-v7a" ], tiVersion ? null
|
||||
, release ? false, androidKeyStore ? null, androidKeyAlias ? null, androidKeyStorePassword ? null
|
||||
, iosMobileProvisioningProfile ? null, iosCertificateName ? null, iosCertificate ? null, iosCertificatePassword ? null
|
||||
, enableWirelessDistribution ? false, installURL ? null
|
||||
}:
|
||||
|
||||
assert (release && target == "android") -> androidKeyStore != null && androidKeyAlias != null && androidKeyStorePassword != null;
|
||||
assert (release && target == "iphone") -> iosMobileProvisioningProfile != null && iosCertificateName != null && iosCertificate != null && iosCertificatePassword != null;
|
||||
assert enableWirelessDistribution -> installURL != null;
|
||||
|
||||
let
|
||||
androidsdkComposition = androidsdk {
|
||||
@ -132,6 +134,15 @@ stdenv.mkDerivation {
|
||||
cp -av build/iphone/build/* $out
|
||||
mkdir -p $out/nix-support
|
||||
echo "file binary-dist \"$(echo $out/Release-iphoneos/*.ipa)\"" > $out/nix-support/hydra-build-products
|
||||
|
||||
${stdenv.lib.optionalString enableWirelessDistribution ''
|
||||
appname=$(basename $out/Release-iphoneos/*.ipa .ipa)
|
||||
bundleId=$(grep '<id>[a-zA-Z0-9.]*</id>' tiapp.xml | sed -e 's|<id>||' -e 's|</id>||' -e 's/ //g')
|
||||
version=$(grep '<version>[a-zA-Z0-9.]*</version>' tiapp.xml | sed -e 's|<version>||' -e 's|</version>||' -e 's/ //g')
|
||||
|
||||
sed -e "s|@INSTALL_URL@|${installURL}?bundleId=$bundleId\&version=$version\&title=$appname|" ${../xcodeenv/install.html.template} > $out/$appname.html
|
||||
echo "doc install \"$out/$appname.html\"" >> $out/nix-support/hydra-build-products
|
||||
''}
|
||||
''
|
||||
else if target == "iphone" then ""
|
||||
else throw "Target: ${target} is not supported!"}
|
||||
|
@ -5,6 +5,7 @@
|
||||
, rename ? false
|
||||
, newBundleId ? "com.example.kitchensink", iosMobileProvisioningProfile ? null, iosCertificate ? null, iosCertificateName ? "Example", iosCertificatePassword ? ""
|
||||
, allowUnfree ? false
|
||||
, enableWirelessDistribution ? false, installURL ? null
|
||||
}:
|
||||
|
||||
let
|
||||
@ -90,6 +91,7 @@ rec {
|
||||
release = true;
|
||||
rename = true;
|
||||
inherit newBundleId iosMobileProvisioningProfile iosCertificate iosCertificateName iosCertificatePassword;
|
||||
inherit enableWirelessDistribution installURL;
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -1,5 +1,6 @@
|
||||
{ titaniumenv, fetchgit, target, androidPlatformVersions ? [ "14" ], tiVersion ? "3.2.3.GA", release ? false
|
||||
, rename ? false, stdenv ? null, newBundleId ? null, iosMobileProvisioningProfile ? null, iosCertificate ? null, iosCertificateName ? null, iosCertificatePassword ? null
|
||||
, enableWirelessDistribution ? false, installURL ? null
|
||||
}:
|
||||
|
||||
assert rename -> (stdenv != null && newBundleId != null && iosMobileProvisioningProfile != null && iosCertificate != null && iosCertificateName != null && iosCertificatePassword != null);
|
||||
@ -37,4 +38,5 @@ titaniumenv.buildApp {
|
||||
androidKeyStorePassword = "mykeystore";
|
||||
|
||||
inherit iosMobileProvisioningProfile iosCertificate iosCertificateName iosCertificatePassword;
|
||||
inherit enableWirelessDistribution installURL;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user