Automatic batch build of multiple android lib library projects-Jenkins practice

Source: Internet
Author: User

In the above section, we have finished building the Jenkin environment. Next we will start to practice this automatic build system.
Jenkins defines a set of building processes, and the building details need to be written. Some scripting languages are needed as the adhesive to help with this process. Currently, it supports linux shell, windows batch, ant, python, and other scripts. Here I use linux shell to complete automatic packaging of an android Application with multiple lib libraries. Of course, you must support automatic channel number change.
Next, let's perform the following operations:
I. Create a new job
Jenkins supports the construction of several software projects. Because ant is called for the core build operation, we choose to use a free-style software project here.



Ii. project configuration
All Channel names used in the project are constructed as parameters. Therefore, go to the configuration page of our new project, select the parameterized construction process, and select String Parameter.

3. Source Code Management
Source code management supports multiple code management tools. cvs and subversion are native. If you need to install the plug-in separately using git, enter the Source Code address of the project.
Recently, the company's servers were not very stable and the project was mounted on its own machines. I can't help but talk about ubuntu and install an svn server. Enter the Project address for the first time and jenkins will prompt you for verification. Click the second link in red and enter the user name and password of the project.
Similarly, we enter the addresses of other lib libraries that the project depends on. In this way, the project source code is configured completely.
4. The build trigger (Omitted) is used to configure the frequency and strategy of project building.
V. Project Construction-core
The idea is to use shell scripts to control ant to clean up projects, configure channels, compile, package, copy, rename, and so on. It is simple to say, but it is actually the most complicated. Because each project has different requirements, the script also changes. So here is a script, which is provided as an idea for everyone. Because the script is long, we will give it in the next article.
I also want to vomit the shell script here. There are a lot of commands and complicated usage, and the headers are all debugging dizzy. It is really difficult to use.
Download, non-technical personnel can also be used without permission.

Related Article

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.