Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding github workflow file. #1

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
73 changes: 73 additions & 0 deletions .github/workflows/dotnet-core.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: .NET Core

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

env:
# Stop wasting time caching packages
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
# Disable sending usage data to Microsoft
DOTNET_CLI_TELEMETRY_OPTOUT: true
# Project name to pack and publish
PROJECT_NAME: DynamicsCRMProvider

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a two jobs called "windows" and "mono"
windows:

# The type of runner that the job will run on
runs-on: windows-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2

# Setup .net core
- name: Setup .NET Core
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be called .net 4.6

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have added another workflow file that uses .net framework

uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.101
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should be whatever it is for .net 4.6.
not even sure that github actions support it you will need to check it since .net 4.6 isn't cross platform.


# Build project using a specific script
- name: Build
shell: cmd
run: call .\build.cmd

# Publish artifacts resulted from build
- name: Upload Artifact
uses: actions/upload-artifact@v2
with:
name: DLL Build Result
path: ./.fake/*.dll
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this I think should be 'bin'

mono:

# The type of runner that the job will run on
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-latest, macos-latest ]

# Steps represent a sequence of tasks that will be executed as part of the job
steps:

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2

# Setup .net core
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.101

# Build project using a specific script
- name: Build
shell: bash
run: |
chmod +x ./build.sh
./build.sh
42 changes: 42 additions & 0 deletions .github/workflows/dotnet-framework.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: .NET Framework

# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: windows-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2

# Setup MSBuild
- name: setup MSBuild
uses: microsoft/setup-msbuild@v1

# Setup Nuget
- name: Setup NuGet
uses: NuGet/[email protected]

# Build project using a specific script
- name: Build
shell: cmd
run: call .\build.cmd

# Publish artifacts resulted from build
- name: Upload Artifact
uses: actions/upload-artifact@v2
with:
name: DLL Build Result
path: ./bin
14 changes: 7 additions & 7 deletions build.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,10 @@ Target "AssemblyInfo" (fun _ ->
Attribute.FileVersion release.AssemblyVersion ]

let getProjectDetails projectPath =
let projectName = System.IO.Path.GetFileNameWithoutExtension(projectPath)
let projectName = System.IO.Path.GetFileNameWithoutExtension(projectPath: string)
( projectPath,
projectName,
System.IO.Path.GetDirectoryName(projectPath),
System.IO.Path.GetDirectoryName(projectPath: string),
(getAssemblyInfoAttributes projectName)
)

Expand Down Expand Up @@ -318,7 +318,7 @@ Target "ReleaseDocs" (fun _ ->
Branches.push tempDocsDir
)

#load "paket-files/fsharp/FAKE/modules/Octokit/Octokit.fsx"
#load "paket-files/FoothillSolutions/FAKE/modules/Octokit/Octokit.fsx"
open Octokit

Target "Release" (fun _ ->
Expand Down Expand Up @@ -349,10 +349,10 @@ Target "All" DoNothing
==> "Build"
==> "CopyBinaries"
// ==> "RunTests"
// =?> ("GenerateReferenceDocs",isLocalBuild)
// =?> ("GenerateDocs",isLocalBuild)
// ==> "All"
// =?> ("ReleaseDocs",isLocalBuild)
=?> ("GenerateReferenceDocs",isLocalBuild)
=?> ("GenerateDocs",isLocalBuild)
==> "All"
=?> ("ReleaseDocs",isLocalBuild)

"All"
#if MONO
Expand Down
4 changes: 2 additions & 2 deletions paket.dependencies
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ source https://nuget.org/api/v2
nuget FSharp.Formatting
nuget NUnit
nuget NUnit.Runners
nuget FAKE 4.64.18
nuget SourceLink.Fake
nuget Microsoft.CrmSdk.CoreAssemblies

github FoothillSolutions/FAKE modules/Octokit/Octokit.fsx
github FoothillSolutions/FAKE:release/next
github FoothillSolutions/FAKE:release/next modules/Octokit/Octokit.fsx
github fsprojects/FSharp.TypeProviders.StarterPack src/ProvidedTypes.fsi
github fsprojects/FSharp.TypeProviders.StarterPack src/ProvidedTypes.fs
6 changes: 3 additions & 3 deletions paket.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
RESTRICTION: == net462
NUGET
remote: https://www.nuget.org/api/v2
FAKE (4.64.18)
FSharp.Formatting (4.1)
Microsoft.CrmSdk.CoreAssemblies (9.0.2.26)
NUnit (3.12)
Expand All @@ -24,8 +23,9 @@ NUGET
SourceLink.Fake (1.1)
GITHUB
remote: FoothillSolutions/FAKE
modules/Octokit/Octokit.fsx (74421063dd3915e8e1e407926b38b8b25df50e36)
Octokit (>= 0.20)
remote: FoothillSolutions/FAKE
modules/Octokit/Octokit.fsx (62cbd242f336419aad54a5d9e797282be675f84d)
Octokit (>= 0.20)
remote: fsprojects/FSharp.TypeProviders.StarterPack
src/ProvidedTypes.fs (b45779c1571b54a2bc6bafa12690a8d9763150d1)
src/ProvidedTypes.fsi (b45779c1571b54a2bc6bafa12690a8d9763150d1)