Windows2012中Jenkins搭建.NET自动编译测试与发布环境

安装7Zip

下载地址: http://www.7-zip.org/a/7z1602-x64.exe

安装Git

下载地址: https://github.com/git-for-windows/git/releases/download/v2.8.3.windows.1/Git-2.8.3-64-bit.exe

在使用 Jenkins CI 或其他连续性整合工具在自动化构建的时候,任何需要互动的认证过程(例如弹出Account的登入视窗),都会无法进行而导致构建过程卡住!

关闭互动操作

git config --global credential.interactive never

安装VS2015

下载地址: https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs

下载nuget命令行工具(mnuget.exe)

下载地址: http://dist.nuget.org/win-x86-commandline/latest/nuget.exe   (下载到D:\jenkins\nuget.exe)

为Jenkins安装MSBuild,Git,GitLab,Gitlab Hook插件

配置MSBuild参数

新建自由风格项目

丢弃旧的构建

添加参数化构建过程

添加Git源码管理

添加gitlab webhook

添加构建触发器

添加执行Batch脚本

安装nuget依赖库

增加MSBuild构建

 添加执行Batch脚本

 

posted @ 2016-05-19 17:28  Edward Guan  阅读(1618)  评论(0编辑  收藏  举报