java online packaging APK package sharing

      This method can be used for channel distribution and the like, and the attachment is a jar package!      
	
       public static void main(String[] args) {
		PackApkApi pack = new PackApkApi();
		//apktool.jar file path
		pack.setApktool("d:\\APK\\tools\\apktool2.1.0.jar");
		//Signature file path
		pack.setKeyFile("D:/APK/keyStory/password.keystore");
		//signature password
		pack.setKeyPasswd("password123");
		//Complete the package APK output directory
		pack.setOutputPath("D:/appserver/apk/share/");
		//temporary working directory
		pack.setTempPath("D:/appserver/apk/temp/");
		
		HashMap<String, String> map = new HashMap<String, String>();
		map.put("PACK_ID", "123456");   
		pack.setMetas(map);
		
		System.out.println(pack.startApk("D:/appserver/apk/Clash Royale_20160331.apk"));
	}

 

 The packaging is successful and the AndroidManifest.xml resource file can be seen

<meta-data android:name="PACK_ID" android:value="123456"/>

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326503694&siteId=291194637