Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
language: node_js
node_js:
- "0.10"
before_install:
- sed -i 's/git@github.com:/https:\/\/github.com\//' .gitmodules
- git submodule update --init --recursive
- npm install -g grunt-cli
install:
- npm install
- grunt pack --no-color
script:
- exit 0
git:
submodules: false
11 changes: 7 additions & 4 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,15 @@ function shallowCopy(obj) {
return result;
}

var travis = process.env["TRAVIS"];
var buildNumber = process.env["TRAVIS_BUILD_NUMBER"] || process.env["BUILD_NUMBER"] || "non-ci";

module.exports = function(grunt) {
grunt.initConfig({
copyPackageTo: "\\\\telerik.com\\Resources\\BlackDragon\\Builds\\nativescript-cli",
copyPackageTo: process.env["CopyPackageTo"] || process.env["HOME"] || ".",

jobName: process.env["JOB_NAME"] || "local",
buildNumber: process.env["BUILD_NUMBER"] || "non-ci",
jobName: travis ? "travis" : (process.env["JOB_NAME"] || "local"),
buildNumber: buildNumber,
dateString: now.substr(0, now.indexOf("T")),

pkg: grunt.file.readJSON("package.json"),
Expand Down Expand Up @@ -104,7 +107,7 @@ module.exports = function(grunt) {

grunt.registerTask("set_package_version", function(version) {
var fs = require("fs");
var buildVersion = version !== undefined ? version : process.env["BUILD_NUMBER"];
var buildVersion = version !== undefined ? version : buildNumber;
if (process.env["BUILD_CAUSE_GHPRBCAUSE"]) {
buildVersion = "PR" + buildVersion;
}
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
nativescript-cli
================
[![Build Status](https://travis-ci.org/NativeScript/nativescript-cli.svg?branch=build)](https://travis-ci.org/NativeScript/nativescript-cli)

Command-line interface for building NativeScript projects