Skip to content

Commit eb51a38

Browse files
authored
Merge pull request #3 from fsprojects/develop
Release package to NuGet with GitHub Actions
2 parents 9446a39 + 70fec7b commit eb51a38

19 files changed

+166
-121
lines changed

.github/workflows/build.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: .NET Core
2+
3+
on:
4+
push:
5+
branches-ignore:
6+
- master
7+
- develop
8+
9+
jobs:
10+
build:
11+
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- uses: actions/checkout@v2
16+
- name: Setup .NET Core
17+
uses: actions/setup-dotnet@v1
18+
- name: Build with dotnet
19+
run: |
20+
DOTNET_CLI_TELEMETRY_OPTOUT=1
21+
dotnet build --nologo --configuration Release

.github/workflows/publish_ci.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: publish to MyGet
2+
3+
on:
4+
push:
5+
branches:
6+
- develop
7+
8+
jobs:
9+
build:
10+
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
- name: Setup .NET Core
16+
uses: actions/setup-dotnet@v1
17+
- name: Build with dotnet
18+
run: |
19+
sed -i "s|<Version>\(.*\)</Version>|<Version>\1-ci-$GITHUB_RUN_ID</Version>|" src/FSharp.Collections.Immutable/FSharp.Collections.Immutable.fsproj
20+
dotnet pack --nologo --configuration Release -o nuget
21+
- name: MyGet push
22+
run: |
23+
source=https://www.myget.org/F/fsharp-collections-immutable/api/v3/index.json
24+
key=${{secrets.MyGet_Key}}
25+
dotnet nuget push -s $source -k $key nuget/*.nupkg

.github/workflows/publish_release.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: publish to NuGet
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
jobs:
9+
publish:
10+
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
16+
# Required for a specific dotnet version that doesn't come with ubuntu-latest / windows-latest
17+
# Visit bit.ly/2synnZl to see the list of SDKs that are pre-installed with ubuntu-latest / windows-latest
18+
# - name: Setup dotnet
19+
# uses: actions/setup-dotnet@v1
20+
# with:
21+
# dotnet-version: 3.1.100
22+
23+
# Publish
24+
- name: publish on version change
25+
uses: rohith/publish-nuget@v2
26+
with:
27+
PROJECT_FILE_PATH: src/FSharp.Collections.Immutable/FSharp.Collections.Immutable.fsproj # Relative to repository root
28+
# VERSION_FILE_PATH: Directory.Build.props # Filepath with version info, relative to repository root. Defaults to project file
29+
# VERSION_REGEX: <Version>(.*)<\/Version> # Regex pattern to extract version info in a capturing group
30+
# TAG_COMMIT: true # Flag to enable / disalge git tagging
31+
# TAG_FORMAT: v* # Format of the git tag, [*] gets replaced with version
32+
NUGET_KEY: ${{secrets.NuGet_Key}}

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -215,3 +215,5 @@ FakesAssemblies/
215215
GeneratedArtifacts/
216216
_Pvt_Extensions/
217217
ModelManifest.xml
218+
.ionide/
219+
.idea/

FSharp.Collections.Immutable.sln

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
Microsoft Visual Studio Solution File, Format Version 12.00
2+
# Visual Studio Version 16
3+
VisualStudioVersion = 16.0.29021.104
4+
MinimumVisualStudioVersion = 10.0.40219.1
5+
Project("{6EC3EE1D-3C4E-46DD-8F32-0CC8E7565705}") = "FSharp.Collections.Immutable", "src\FSharp.Collections.Immutable\FSharp.Collections.Immutable.fsproj", "{9805E74C-D028-4D05-9256-5C2FDC9B6EA8}"
6+
EndProject
7+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{9BE8C74B-E5EF-4A0E-8E77-CDCD967B6E88}"
8+
ProjectSection(SolutionItems) = preProject
9+
.github\workflows\build.yml = .github\workflows\build.yml
10+
.github\workflows\publish_ci.yml = .github\workflows\publish_ci.yml
11+
.github\workflows\publish_release.yml = .github\workflows\publish_release.yml
12+
EndProjectSection
13+
EndProject
14+
Global
15+
GlobalSection(SolutionConfigurationPlatforms) = preSolution
16+
Debug|Any CPU = Debug|Any CPU
17+
Release|Any CPU = Release|Any CPU
18+
EndGlobalSection
19+
GlobalSection(ProjectConfigurationPlatforms) = postSolution
20+
{9805E74C-D028-4D05-9256-5C2FDC9B6EA8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
21+
{9805E74C-D028-4D05-9256-5C2FDC9B6EA8}.Debug|Any CPU.Build.0 = Debug|Any CPU
22+
{9805E74C-D028-4D05-9256-5C2FDC9B6EA8}.Release|Any CPU.ActiveCfg = Release|Any CPU
23+
{9805E74C-D028-4D05-9256-5C2FDC9B6EA8}.Release|Any CPU.Build.0 = Release|Any CPU
24+
EndGlobalSection
25+
GlobalSection(SolutionProperties) = preSolution
26+
HideSolutionNode = FALSE
27+
EndGlobalSection
28+
GlobalSection(ExtensibilityGlobals) = postSolution
29+
SolutionGuid = {5A4E44BA-0D9F-4E81-A35E-83A38C3E43CF}
30+
EndGlobalSection
31+
GlobalSection(CodealikeProperties) = postSolution
32+
SolutionGuid = f92c102d-027e-479b-995c-b971032fea8c
33+
EndGlobalSection
34+
EndGlobal

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# FSharp.Collections.Immutable
2+
3+
F# bindings for System.Collections.Immutable
4+
5+
![.NET Core](https://github.com/fsprojects/FSharp.Collections.Immutable/workflows/.NET%20Core/badge.svg)

Source/FSharp.Collections.Immutable/FSharp.Collections.Immutable.sln

Lines changed: 0 additions & 25 deletions
This file was deleted.

Source/FSharp.Collections.Immutable/FSharp.Collections.Immutable/FSharp.Collections.Immutable.fsproj

Lines changed: 0 additions & 72 deletions
This file was deleted.

Source/FSharp.Collections.Immutable/FSharp.Collections.Immutable/Script.fsx

Lines changed: 0 additions & 3 deletions
This file was deleted.

Source/FSharp.Collections.Immutable/FSharp.Collections.Immutable/packages.config

Lines changed: 0 additions & 4 deletions
This file was deleted.

0 commit comments

Comments
 (0)