Skip to content

Commit cfe37ce

Browse files
committed
Jenkins / .net CI support
1 parent db0ee4f commit cfe37ce

File tree

2 files changed

+35
-0
lines changed

2 files changed

+35
-0
lines changed

jenkins.sh

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#!/usr/bin/env bash
2+
3+
# Set up NVM
4+
export NVM_DIR="/home/dotnet-bot/.nvm"
5+
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh"
6+
7+
nvm install $1
8+
9+
npm uninstall typescript
10+
npm uninstall tslint
11+
npm install
12+
npm update
13+
npm test

netci.groovy

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
// Import the utility functionality.
2+
import jobs.generation.Utilities;
3+
4+
// Defines a the new of the repo, used elsewhere in the file
5+
def project = GithubProject
6+
def branch = GithubBranchName
7+
8+
def nodeVersions = ['stable', '4']
9+
10+
nodeVersions.each { nodeVer ->
11+
12+
def newJobName = "typescript_node.${nodeVer}"
13+
def newJob = job(Utilities.getFullJobName(project, newJobName, true)) {
14+
steps {
15+
shell("./jenkins.sh ${nodeVer}")
16+
}
17+
}
18+
19+
Utilities.standardJobSetup(newJob, project, true, "*/${branch}")
20+
Utilities.setMachineAffinity(newJob, 'Ubuntu', '20161020')
21+
Utilities.addGithubPRTriggerForBranch(newJob, branch, "TypeScript Test Run ${newJobName}")
22+
}

0 commit comments

Comments
 (0)