如何将 Travis-CI 与 C# 或 F# 一起使用 [英] How do I use Travis-CI with C# or F#

查看:17
本文介绍了如何将 Travis-CI 与 C# 或 F# 一起使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Travis CI 持续集成服务官方支持多种语言,但是不是 C# 或 F#.

我可以在我的 .net 项目中使用它吗?

解决方案

Travis CI 现在 支持C#.从该页面大量引用:

<块引用>

概述

C#、F# 和 Visual Basic 项目的设置如下所示:

语言:csharp解决方案:解决方案名称.sln单核细胞增多症:- 最新的- 3.12.0- 3.10.0

<块引用>

脚本

默认情况下,Travis 将运行 xbuild solution-name.sln.Xbuild 是一个构建工具,旨在实现 Microsoft 的 MSBuild 工具.要覆盖它,您可以像这样设置脚本属性:

语言:csharp解决方案:解决方案名称.sln脚本:./build.sh

<块引用>

NuGet

默认情况下,Travis 将运行 nuget restore solution-name.sln,它会从您的解决方案文件中恢复所有 NuGet 包.要覆盖它,您可以像这样设置安装属性:

语言:csharp解决方案:解决方案名称.sln安装:- 须藤做某事- nuget 恢复解决方案名称.sln

Travis CI continuous integration service officially supports many languages, but not C# or F#.

Can I use it with my .net projects?

解决方案

Travis CI now supports C#. Quoting liberally from that page:

Overview

The setup for C#, F#, and Visual Basic projects looks like this:

language: csharp
solution: solution-name.sln
mono:
  - latest
  - 3.12.0
  - 3.10.0

Script

By default Travis will run xbuild solution-name.sln. Xbuild is a build tool designed to be an implementation for Microsoft's MSBuild tool. To override this, you can set the script attribute like this:

language: csharp
solution: solution-name.sln
script: ./build.sh

NuGet

By default, Travis will run nuget restore solution-name.sln, which restores all NuGet packages from your solution file. To override this, you can set the install attribute like this:

language: csharp
solution: solution-name.sln
install:
  - sudo dosomething
  - nuget restore solution-name.sln

这篇关于如何将 Travis-CI 与 C# 或 F# 一起使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆