Class: FlashSDK::ADT
- Inherits:
-
Sprout::Executable::Base
- Object
- Sprout::Executable::Base
- FlashSDK::ADT
- Defined in:
- lib/flashsdk/adt.rb
Overview
Creates AIR certificates and compiles AIR packages for distribution.
Following is an example of how this tool might be used to create a certificate and AIR package:
mxmlc 'bin/SomeProject.swf' do |t|
t.input = 'src/SomeProject.as'
end
adt 'cert/SomeProject.pfx' do |t|
t.certificate = true
t.cn = 'SelfCertificate'
t.key_type = '2048-RSA'
t.pfx_file = 'cert/SomeProject.pfx'
# Don't check the .password file into version control:
t.password = File.read('cert/.password')
end
adt 'bin/SomeProject.air' => ['bin/SomeProject.swf', 'cert/SomeProject.pfx'] do |t|
t.package = true
t.package_input = 'SomeProject.xml'
t.package_output = 'bin/SomeProject.air'
t.storetype = 'PKCS12'
t.keystore = 'cert/SomeProject.pfx'
# Don't check the .password file into version control:
t.storepass = File.read('cert/.password')
t.included_files << 'bin/SomeProject.swf'
end
desc "Compile, certify and package the AIR application"
task package => 'bin/SomeProject.air'
Instance Method Summary collapse
-
#appid ⇒ Object
The appid of the app being installed/uninstalled (ex: com.foo.Bar).
-
#certificate ⇒ Object
Set true to create a certificate.
-
#checkstore ⇒ Object
Check Store Signing options.
-
#cn ⇒ Object
The Certificate name.
-
#country ⇒ Object
Country, follows certificate.
-
#default_prefix ⇒ Object
Ensure the default prefix is ‘-’.
-
#executable ⇒ Object
The default executable target.
-
#file_options ⇒ Object
Allows file options in the form of -C <dir> <fileOrDir>+.
-
#included_files ⇒ Object
A list of files to include in the.
-
#included_paths ⇒ Object
A list of paths (directories) to search for contents that will be included in the packaged AIR application.
-
#installApp ⇒ Object
Install an app on a device.
-
#key_type ⇒ Object
Key Type, follows certificate.
-
#keypass ⇒ Object
A Signing Option.
-
#keystore ⇒ Object
A Signing Option.
-
#launchApp ⇒ Object
Launch an app on a device.
-
#migrate ⇒ Object
Expects Signing Options, plus two files:.
-
#org_name ⇒ Object
Organization name, follows certificate.
-
#org_unit ⇒ Object
Organization unit, follows certificate.
-
#package ⇒ Object
Create an AIR package.
-
#package_input ⇒ Object
The XML application descriptor that should be used to create an AIR application.
-
#package_output ⇒ Object
The AIR file that should be created after packaging is complete.
-
#password ⇒ Object
When creating a certificate, this is the file where the password can be found.
-
#pfx_file ⇒ Object
PFX File.
-
#pkg_name ⇒ Object
The the Ruby file that will load the expected Sprout::Specification.
-
#pkg_version ⇒ Object
The default pkg version.
-
#platform ⇒ Object
The platform to use (ex: android).
-
#providername ⇒ Object
A Signing Option.
-
#provisioning_profile ⇒ Object
Provisioning profile for iOS apps.
-
#sign ⇒ Object
Expects two files:.
-
#storepass ⇒ Object
Provide the password directly to the ADT task so that it doesn’t attempt to prompt.
-
#storetype ⇒ Object
A Signing Option.
-
#target ⇒ Object
Use a specific target, like apk-debug for Android or ipa-debug for iOS.
-
#tsa ⇒ Object
A Signing Option.
-
#uninstallApp ⇒ Object
Uninstall an app from a device.
-
#version ⇒ Object
The AIR runtime version to use.
Instance Method Details
#appid ⇒ Object
The appid of the app being installed/uninstalled (ex: com.foo.Bar)
66 |
# File 'lib/flashsdk/adt.rb', line 66 add_param :appid, String, { :delimiter => ' ' } |
#certificate ⇒ Object
Set true to create a certificate.
If this value is true, you can optionally set org_unit, org_name and country.
If this value is true, you MUST set cn
, key_type
, and pfx_file
.
adt 'cert/SampleCert.pfx' do |t|
t.certificate = true
t.cn = 'SelfCertificate'
t.key_type = '1024-RSA'
t.pfx_file = 'cert/SampleCert.pfx'
t.password = 'samplepassword'
end
88 |
# File 'lib/flashsdk/adt.rb', line 88 add_param :certificate, Boolean, { :hidden_value => true } |
#checkstore ⇒ Object
Check Store Signing options
128 |
# File 'lib/flashsdk/adt.rb', line 128 add_param :checkstore, String |
#cn ⇒ Object
The Certificate name.
191 |
# File 'lib/flashsdk/adt.rb', line 191 add_param :cn, String, { :delimiter => ' ' } |
#country ⇒ Object
Country, follows certificate.
186 |
# File 'lib/flashsdk/adt.rb', line 186 add_param :country, String |
#default_prefix ⇒ Object
Ensure the default prefix is ‘-’
268 |
# File 'lib/flashsdk/adt.rb', line 268 set :default_prefix, '-' |
#executable ⇒ Object
The default executable target.
264 |
# File 'lib/flashsdk/adt.rb', line 264 set :executable, :adt |
#file_options ⇒ Object
Allows file options in the form of -C <dir> <fileOrDir>+
For example if you defined:
t. << 'dir path/to/asset.xml'
In your adt task defintion, then:
-C dir path/to/asset.xml
Would be appended to your arguments.
246 |
# File 'lib/flashsdk/adt.rb', line 246 add_param :file_options, Strings, { :shell_name => '-C', :delimiter => ' ' } |
#included_files ⇒ Object
A list of files to include in the
221 |
# File 'lib/flashsdk/adt.rb', line 221 add_param :included_files, Files, { :hidden_name => true } |
#included_paths ⇒ Object
A list of paths (directories) to search for contents that will be included in the packaged AIR application.
If files are hidden from the file system, they will not be included.
231 |
# File 'lib/flashsdk/adt.rb', line 231 add_param :included_paths, Paths, { :hidden_name => true } |
#installApp ⇒ Object
Install an app on a device
46 |
# File 'lib/flashsdk/adt.rb', line 46 add_param :installApp, Boolean, { :hidden_value => true } |
#key_type ⇒ Object
Key Type, follows certificate.
196 |
# File 'lib/flashsdk/adt.rb', line 196 add_param :key_type, String, { :hidden_name => true } |
#keypass ⇒ Object
A Signing Option
111 |
# File 'lib/flashsdk/adt.rb', line 111 add_param :keypass, String, { :delimiter => ' ' } |
#keystore ⇒ Object
A Signing Option
99 |
# File 'lib/flashsdk/adt.rb', line 99 add_param :keystore, String, { :delimiter => ' ' } |
#launchApp ⇒ Object
Launch an app on a device
56 |
# File 'lib/flashsdk/adt.rb', line 56 add_param :launchApp, Boolean, { :hidden_value => true } |
#migrate ⇒ Object
Expects Signing Options, plus two files:
1) The Air file in 2) The Air file out
216 |
# File 'lib/flashsdk/adt.rb', line 216 add_param :migrate, Files |
#org_name ⇒ Object
Organization name, follows certificate.
181 |
# File 'lib/flashsdk/adt.rb', line 181 add_param :org_name, String |
#org_unit ⇒ Object
Organization unit, follows certificate.
176 |
# File 'lib/flashsdk/adt.rb', line 176 add_param :org_unit, String |
#package ⇒ Object
Create an AIR package.
71 |
# File 'lib/flashsdk/adt.rb', line 71 add_param :package, Boolean, { :hidden_value => true } |
#package_input ⇒ Object
The XML application descriptor that should be used to create an AIR application.
171 |
# File 'lib/flashsdk/adt.rb', line 171 add_param :package_input, File, { :hidden_name => true } |
#package_output ⇒ Object
The AIR file that should be created after packaging is complete.
164 |
# File 'lib/flashsdk/adt.rb', line 164 add_param :package_output, String, { :hidden_name => true } |
#password ⇒ Object
When creating a certificate, this is the file where the password can be found.
207 |
# File 'lib/flashsdk/adt.rb', line 207 add_param :password, String, { :hidden_name => true, :delimiter => ' ' } |
#pfx_file ⇒ Object
PFX File
201 |
# File 'lib/flashsdk/adt.rb', line 201 add_param :pfx_file, String, { :hidden_name => true } |
#pkg_name ⇒ Object
The the Ruby file that will load the expected Sprout::Specification.
Default value is ‘flex4’
254 |
# File 'lib/flashsdk/adt.rb', line 254 set :pkg_name, 'flex4' |
#pkg_version ⇒ Object
The default pkg version
259 |
# File 'lib/flashsdk/adt.rb', line 259 set :pkg_version, ">= #{FlashSDK::VERSION}" |
#platform ⇒ Object
The platform to use (ex: android)
61 |
# File 'lib/flashsdk/adt.rb', line 61 add_param :platform, String, { :delimiter => ' ' } |
#providername ⇒ Object
A Signing Option
117 |
# File 'lib/flashsdk/adt.rb', line 117 add_param :providername, String, { :delimiter => ' ' } |
#provisioning_profile ⇒ Object
Provisioning profile for iOS apps
133 |
# File 'lib/flashsdk/adt.rb', line 133 add_param :provisioning_profile, String, { :delimiter => ' ' } |
#sign ⇒ Object
Expects two files:
1) The Airi file (?) 2) The Air file
147 |
# File 'lib/flashsdk/adt.rb', line 147 add_param :sign, Files, { :delimiter => ' ' } |
#storepass ⇒ Object
Provide the password directly to the ADT task so that it doesn’t attempt to prompt.
105 |
# File 'lib/flashsdk/adt.rb', line 105 add_param :storepass, String, { :delimiter => ' ' } |
#storetype ⇒ Object
A Signing Option
93 |
# File 'lib/flashsdk/adt.rb', line 93 add_param :storetype, String, { :delimiter => ' ' } |
#target ⇒ Object
Use a specific target, like apk-debug for Android or ipa-debug for iOS
158 |
# File 'lib/flashsdk/adt.rb', line 158 add_param :target, String, { :delimiter => ' ' } |
#tsa ⇒ Object
A Signing Option
123 |
# File 'lib/flashsdk/adt.rb', line 123 add_param :tsa, String |
#uninstallApp ⇒ Object
Uninstall an app from a device
51 |
# File 'lib/flashsdk/adt.rb', line 51 add_param :uninstallApp, Boolean, { :hidden_value => true } |
#version ⇒ Object
The AIR runtime version to use.
152 |
# File 'lib/flashsdk/adt.rb', line 152 add_param :version, String, { :delimiter => ' ' } |