第一步:

fork

第二步:

添加.travis.yml

在repository根目录添加.travis.yml文件,在其中添加以下内容.

language: c
before_install:
- wget http://dl.google.com/android/ndk/android-ndk-r10e-linux-x86_64.bin
- sudo chmod a+x android-ndk-r10e-linux-x86_64.bin
- ./android-ndk-r10e-linux-x86_64.bin > /dev/null
- ./android-configure ./android-ndk-r10e
script:
- make
- rm node
- cp -a out/Release/node node
- tar czvf android.gz node
deploy:
provider: releases
api_key: $CI_USER_TOKEN
file: android.gz
skip_cleanup: true
on:
tags: true
在before_install配置好ndk生成makefile
在script段编译,并打包目标文件.
deploy那一段用于上传文件到github releases

第三步:

添加token

进入https://github.com/settings/tokens

点击Generate new token,选中repo生成字串(token)并复制.

第四步:

设置travis-ci

没有注册的先打开https://travis-ci.org注册

打开https://travis-ci.org/profile/用户名,开启node的repository.

打开https://travis-ci.org/用户名/node/settings

点最下面的add添加环境变量CI_USER_TOKEN(之前的配置文件中设定的),值即前一步生成的token

第五步:

发布

进入https://github.com/用户名/node/releases 单击Draft a new release 发布新的Tag

第六步:

睡一觉

起来后就可以在https://github.com/用户名/node/releases 看见编译好的文件.

主要的陷阱:

1.必须压缩文件,否则上传时会出现503错误.

2.添加环境变量时Display value in build log 要设为off.

例子:

https://github.com/hjiayz/node/releases

用travis-ci编译android版nodejs的更多相关文章

  1. 编译android版libmpg

    环境:ubutnu 12.04,android SDK 1. 下载libmpg的一个android工程,得到一个Android-libmpg-master.zip.https://github.com ...

  2. Travis CI Could not find or load main class org.gradle.wrapper.GradleWrapperMain 错误

    问题 在 Travis CI 编译的时候出现 Error: Could not find or load main class org.gradle.wrapper.GradleWrapperMain ...

  3. Travis CI用来持续集成你的项目

    这里持续集成基于GitHub搭建的博客为项目 工具: zqz@ubuntu:~$ node --version v4.2.6 zqz@ubuntu:~$ git --version git versi ...

  4. [转]Travis Ci的最接底气的中文使用教程

    相信大家对Travis Ci已经不再陌生了,Github上已经有大部分的项目已经采用了它. Travis Ci是一个基于晕的持续集成项目,目前已经支持大部分主流语言了,如:C.PHP.Ruby.Pyt ...

  5. 使用 Travis CI 自动部署 Hexo 站点至 GitHub Pages

    Hexo 与 GitHub Pages 安装配置请参考:Hexo 与 GitHub Pages 本文源码与生成的静态文件在同一项目下,源码在 source 分支,静态文件在 master 分支 新增 ...

  6. 利用Travis CI+GitHub实现持续集成和自动部署

    前言 如果你手动部署过项目,一定会深感持续集成的必要性,因为手动部署实在又繁琐又耗时,虽然部署流程基本固定,依然容易出错. 如果你很熟悉持续集成,一定会同意这样的观点:"使用它已经成为一种标 ...

  7. 转:Android开发实践:用脚本编译Android工程

    转自: http://ticktick.blog.51cto.com/823160/1365947 一般情况下,我们都是使用Eclipse+ADT插件或者Android studio软件来编译Andr ...

  8. [转]编译Android源代码常见错误解决办法

    1. 编译时出现/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../libz.so when ...

  9. JDK版本更换后编译android系统出错

    一:javac: 目标发行版 1.5 与默认的源发行版 1.7 冲突 1.设置jdk环境变量 编译android源码只支持jdk 1.6,所以如果需要编译源码必须下载jdk 1.6,不能下载最新的jd ...

随机推荐

  1. 10474 - Where is the Marble?(模拟)

    传送门: UVa10474 - Where is the Marble? Raju and Meena love to play with Marbles. They have got a lot o ...

  2. EntityFramework Code-First教程(一)

    前言:学习了EF框架这么久,还没有好好总结一番,正好遇到一国外的网站,发现不错,随即翻译过来,一是让自己复习一遍,二是供广大初学者学习,翻译过程中加入了一些自己的理解,如有错误,还请指出,多谢多谢.好 ...

  3. Sass 基础(六)

    join() 函数 join()函数是将两个列表连接合并成一个列表. >>join(10px 20px, 30px 40px) (10px 20px 20px 40px) >> ...

  4. 不再手写import - VSCode自动引入Vue组件和Js模块

    :first-child{margin-top:0!important}.markdown-body>:last-child{margin-bottom:0!important}.markdow ...

  5. VUE插件整理

    转自:https://blog.csdn.net/miaozhenzhong/article/details/80138174 1.VsCode官方插件地址: https://marketplace. ...

  6. vue项目中使用vuex

    1.运行 cnpm i vuex -S 2.导入包 import Vuex from 'vuex' 3.注册vuex到vue中 Vue.use(vuex) 4. var store = new Vue ...

  7. ABAP术语-Business Object

    Business Object 原文:http://www.cnblogs.com/qiangsheng/archive/2008/01/07/1028364.html Represents a ce ...

  8. (第03节)三种ApplcationContext的实现

  9. 【vlan-hybird】

    根据项目要求搭建号拓扑图如下: 分别配置pc1-5的ip地址: 配置交换机sw1: 配置交换机sw2

  10. 在ReactNative中使用Typescript

    在ReactNative中使用Typescript 少侠放心,跟着我的这个步骤走,保你完美在RN项目中使用Typescript,废话不多说,走你 1.全局安装create-react-native-a ...