Skip to content
This repository has been archived by the owner on Feb 22, 2022. It is now read-only.

Commit

Permalink
Merge pull request #203 from panesofglass/build
Browse files Browse the repository at this point in the history
Update build
  • Loading branch information
panesofglass authored Oct 10, 2018
2 parents 1007f52 + 192eb36 commit 744a6aa
Show file tree
Hide file tree
Showing 8 changed files with 51 additions and 30 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ $tf/
_ReSharper*/
*.[Rr]e[Ss]harper
*.DotSettings.user
.idea/

# JustCode is a .NET coding addin-in
.JustCode
Expand Down
12 changes: 7 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
language: csharp

mono: 5.2.0
dotnet: 2.0.0
dotnet: 2.1.402

mono:
- 5.2.0

install:
- mozroots --import --sync
Expand All @@ -13,10 +15,10 @@ matrix:
- os: linux # Ubuntu 14.04
dist: trusty
sudo: required
dotnet: 2.0.0
dotnet: 2.1.402
- os: osx # OSX 10.12
osx_image: xcode9.1
dotnet: 2.0.0
dotnet: 2.1.402
dist: trusty
sudo: required

Expand All @@ -27,4 +29,4 @@ script:

branches:
except:
- gh-pages
- gh-pages
6 changes: 0 additions & 6 deletions NuGet.config

This file was deleted.

15 changes: 5 additions & 10 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
version: 4.0.0-aci-{build}

image: Visual Studio 2017
build_script:
- ps: dotnet --info
- ps: dotnet restore
- ps: dotnet pack -c Release --include-symbols --version-suffix "aci-${env:APPVEYOR_BUILD_NUMBER}"

test: off

- ps: |
.\build.ps1
if ($lastexitcode -ne 0){ exit $lastexitcode }
artifacts:
- path: '**\*.nupkg'
- path: '**\BenchmarkDotNet.Artifacts\**\*.*'
- path: bin\*.nupkg
21 changes: 21 additions & 0 deletions build.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
[xml]$doc = Get-Content .\src\Directory.Build.props
$version = $doc.Project.PropertyGroup.VersionPrefix # the version under development, update after a release
$versionSuffix = '-build.0' # manually incremented for local builds

function isVersionTag($tag){
$v = New-Object Version
[Version]::TryParse($tag, [ref]$v)
}

if ($env:appveyor){
$versionSuffix = '-build.' + $env:appveyor_build_number
if ($env:appveyor_repo_tag -eq 'true' -and (isVersionTag($env:appveyor_repo_tag_name))){
$version = $env:appveyor_repo_tag_name
$versionSuffix = ''
}
Update-AppveyorBuild -Version "$version$versionSuffix"
}

dotnet build -c Release Freya.sln /p:Version=$version$versionSuffix
dotnet pack --no-build -c Release src/Freya /p:Version=$version$versionSuffix -o $psscriptroot/bin
dotnet pack --no-build -c Release src/Freya.Hopac /p:Version=$version$versionSuffix -o $psscriptroot/bin
10 changes: 9 additions & 1 deletion src/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,14 @@
<RepositoryUrl>https://github.com/xyncro/freya</RepositoryUrl>
<PackageTags>$(PackageTags);functional;web;freya;f#;fsharp</PackageTags>
<PackageTags Condition="'$(Hopac)' == 'true'">$(PackageTags);hopac</PackageTags>
<GenerateDocumentationFile>true</GenerateDocumentationFile>

<!-- SourceLink related properties https://github.com/dotnet/SourceLink#using-sourcelink -->
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<AllowedOutputExtensionsInPackageBuildOutputFolder>$(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb</AllowedOutputExtensionsInPackageBuildOutputFolder>
</PropertyGroup>
<Import Condition="Exists('version.props')" Project="version.props"/>
<ItemGroup>
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.0.0-*" PrivateAssets="All" />
</ItemGroup>
</Project>
8 changes: 4 additions & 4 deletions src/Freya.Hopac/Freya.Hopac.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
<Import Project="..\Freya.Common.targets" />
<ItemGroup>
<!-- set PrivateAssets=None to ensure that all assets, including Build and Analyzer, are included in the nuspec -->
<PackageReference Include="Freya.Machines.Http.Hopac" Version="4.0.0-alpha-*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http.Cors.Hopac" Version="4.0.0-alpha-*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http.Patch.Hopac" Version="4.0.0-alpha-*" PrivateAssets="None" />
<PackageReference Include="Freya.Routers.Uri.Template.Hopac" Version="4.0.0-alpha-*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http.Hopac" Version="4.0.*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http.Cors.Hopac" Version="4.0.*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http.Patch.Hopac" Version="4.0.*" PrivateAssets="None" />
<PackageReference Include="Freya.Routers.Uri.Template.Hopac" Version="4.0.*" PrivateAssets="None" />
</ItemGroup>
</Project>
8 changes: 4 additions & 4 deletions src/Freya/Freya.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
<Import Project="..\Freya.Common.targets" />
<ItemGroup>
<!-- set PrivateAssets=None to ensure that all assets, including Build and Analyzer, are included in the nuspec -->
<PackageReference Include="Freya.Machines.Http" Version="4.0.0-alpha-*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http.Cors" Version="4.0.0-alpha-*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http.Patch" Version="4.0.0-alpha-*" PrivateAssets="None" />
<PackageReference Include="Freya.Routers.Uri.Template" Version="4.0.0-alpha-*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http" Version="4.0.*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http.Cors" Version="4.0.*" PrivateAssets="None" />
<PackageReference Include="Freya.Machines.Http.Patch" Version="4.0.*" PrivateAssets="None" />
<PackageReference Include="Freya.Routers.Uri.Template" Version="4.0.*" PrivateAssets="None" />
</ItemGroup>
</Project>

0 comments on commit 744a6aa

Please sign in to comment.