在发布AIR程序时,客户端有可能没有安装AIR运行环境,所在安装之前需要在客户端先安装AIR运行环境,但如果提示用户自己去安装的话,友好度非常不好,搞不好用户还会不会安装。
下面提供一种将AIR运行环境和AIR程序一起发布的方法,非常方便实用。
关于打包AIR项目和运行环境,官网的文章如下:
http://www.adobe.com/products/air/runtime_distribution3.html
先下载
- Download installer files
- 解压后目录为:
- 2009-10-10 09:14 <DIR> Adobe AIR
2009-10-10 09:14 41,856 Adobe AIR Installer.exe
2009-10-10 09:14 31,232 setup.msi
2009-10-10 09:14 656,459 setup.swf - 需要在根目录下创建名为 .airinstall.cfg 的文件 。
- 文件中直接写入需要打包的.air 项目的相对路径即可。
比如,目标文件为 MyTest.air,放在根目录下。那么.airinstall.cfg中就只有一行: MyTest.air 。
现在就可以双击Adobe AIR Installer.exe开始安装了。如果喜欢,可以直接把它改成喜欢的名字。
不过另外两个setup文件是不可以改名的。