BAT batch processing: one-click generation of APK package script sharing

Source: Internet
Author: User
Tags tortoisesvn

BAT batch processing: one-click generation of APK package script sharing

This article mainly introduces BAT batch processing, one-click APK package generation script sharing. This script applies to cocos2dx + lua projects. For more information, see

BAT batch processing: one-click generation of APK package script sharing

Put the bat file in the project. android directory of your project under the cocos2dx directory (you need to modify the variable ).

ASmaker is used to implement the lua file batch encryption algorithm in the Resources folder by referring to my previous rc4 algorithm.

The latest svn Engineering Code and cocos2dx engine code before each apk package.

?

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

57

58

59

60

61

@ Echo off

Rem Tool Path

Set JAVA_HOME = "C: \ Program Files \ Java \ jdk1.8.0 _ 05"

Set ANT_HOME = "D: \ ProgramSoftware \ apache-ant-1.9.4"

Set ANDROID_HOME = "D: \ ProgramSoftware \ android sdk \ sdk"

Set NDK_HOME = "D: \ ProgramSoftware \ android-ndk-r9d-windows-x86_64 \ android-ndk-r9d"

Set SVN_HOME = "C: \ Program Files \ TortoiseSVN \ bin \"

 

Rem target path

Set WORK_DIR = "D: \ engine \ projects \ XXXXX \ proj. android"

Rem set PRO_DIR = "D: \ engine \ projects \ XXXXX"

Set RESOURCES_DIR = % WORK_DIR % \ .. \ Resources

Set ASSETS_DIR = % WORK_DIR % \ assets

 

 

 

Rem first deletes the old assets

If exist D: \ engine \ projects \ XXXXX \ proj. android \ assets (

Echo "deleting assets"

Rd/q/s D: \ engine \ projects \ XXXXX \ proj. android \ assets

)

 

Rem then deletes the old Resources

If exist D: \ engine \ projects \ XXXXX \ Resources (

Echo "deleting Resources"

Rd/q/s D: \ engine \ projects \ XXXXX \ Resources

)

 

Rem deletes the old APK

If exist D: \ engine \ projects \ XXXXX \ proj. android \ bin \ XXXXX-release.apk (

Echo "deleting old APK"

Del/q/f D: \ engine \ projects \ XXXXX \ proj. android \ bin \ XXXXX-release.apk

)

 

Rem call ant clean

 

Rem svn

"C:/Program Files/TortoiseSVN/bin/TortoiseProc.exe"/command: update/path: "D: \ engine \ projects \ XXXXX"/closeonend: 1

"C:/Program Files/TortoiseSVN/bin/TortoiseProc.exe"/command: update/path: "D: \ engine"/closeonend: 1

 

Pushd D: \ engine \ projects \ XXXXX \ proj. android

 

Rem luajit Resources

For/r D: \ engine \ projects \ XXXXX \ Resources % I in (*. lua) do (

Echo % I

Luajit.exe-B % I

)

 

Rem ASmaker assets

ASmaker-I D: \ engine \ projects \ XXXXX \ Resources-o D: \ engine \ projects \ XXXXX \ proj. android \ assets

 

Rem ndk

Call "D: \ ProgramSoftware \ android-ndk-r9d-windows-x86_64 \ android-ndk-r9d \ ndk-build"-C "D: \ engine \ projects \ XXXXX \ proj. android "" NDK_MODULE_PATH = D: \ engine; D: \ engine \ cocos2dx \ platform \ third_party \ android \ prebuilt"

 

Rem ant release

Call "D: \ ProgramSoftware \ android sdk \ tools \ android" update project-p "D: \ engine \ projects \ XXXXX \ proj. android"

Call ant release

 

Popd

 

Pause

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.