Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: nhibernate/fluent-nhibernate
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v3.2.1
Choose a base ref
...
head repository: nhibernate/fluent-nhibernate
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref

Commits on Sep 14, 2023

  1. Update dependency cake.tool to v3.1.0 (#611)

    +semver:patch
    renovate[bot] authored Sep 14, 2023
    Copy the full SHA
    784a23c View commit details
  2. Update dependency FakeItEasy to v7.4.0 (#603)

    +semver:patch
    renovate[bot] authored Sep 14, 2023
    Copy the full SHA
    2da0fee View commit details
  3. Copy the full SHA
    069abc9 View commit details

Commits on Sep 15, 2023

  1. Add & use MsSQLiteDialect (#619)

    +semver:feature
    hazzik authored Sep 15, 2023
    Copy the full SHA
    18e308c View commit details
  2. Update dependency Microsoft.Data.Sqlite to 6.0.22 (#620)

    Closes #534
    
    +semver:patch
    hazzik authored Sep 15, 2023
    Copy the full SHA
    974d978 View commit details
  3. Copy the full SHA
    1220236 View commit details

Commits on Sep 17, 2023

  1. Copy the full SHA
    0dddee2 View commit details

Commits on Sep 18, 2023

  1. Fix version calculation on non windows (#621)

    +semver:patch
    hazzik authored Sep 18, 2023
    Copy the full SHA
    ef7694a View commit details

Commits on Nov 28, 2023

  1. Update dependency NUnit to v3.14.0 (#623)

    +semver:patch
    renovate[bot] authored Nov 28, 2023
    Copy the full SHA
    3ccb9c1 View commit details
  2. Update dependency FakeItEasy to v8 (#624)

    +semver:patch
    renovate[bot] authored Nov 28, 2023
    Copy the full SHA
    c63e228 View commit details

Commits on Nov 29, 2023

  1. Update dependency cake.tool to v4 (#630)

    +semver:patch
    renovate[bot] authored Nov 29, 2023
    Copy the full SHA
    245231b View commit details
  2. Copy the full SHA
    73d2b55 View commit details

Commits on Dec 7, 2023

  1. Copy the full SHA
    59b7bfa View commit details

Commits on Feb 7, 2024

  1. Update dependency FakeItEasy to v8.1.0 (#631)

    +semver:patch
    renovate[bot] authored Feb 7, 2024
    Copy the full SHA
    a2e2fab View commit details
  2. Copy the full SHA
    9052e19 View commit details
  3. Copy the full SHA
    5732fc5 View commit details
  4. Update dependency Cake.FileHelpers to v7 (#633)

    +semver:patch
    renovate[bot] authored Feb 7, 2024
    Copy the full SHA
    689ac8b View commit details

Commits on Feb 9, 2024

  1. Run tests using .NET Framework 4.8 (#638)

    +semver:patch
    hazzik authored Feb 9, 2024
    Copy the full SHA
    528ff4c View commit details

Commits on Feb 26, 2024

  1. Install NUnit.Analyzers package (#643)

    +semver:patch
    hazzik authored Feb 26, 2024
    Copy the full SHA
    1c01f7b View commit details
  2. Convert NUnit Asserts to fluent model (#644)

    +semver:patch
    hazzik authored Feb 26, 2024
    Copy the full SHA
    94699f3 View commit details
  3. Update dependency NUnit to v4 (#629)

    +semver:patch
    renovate[bot] authored Feb 26, 2024
    Copy the full SHA
    6c8df85 View commit details

Commits on Feb 27, 2024

  1. Package README.md to NuGet (#645)

    +semver:patch
    hazzik authored Feb 27, 2024
    Copy the full SHA
    9437211 View commit details

Commits on Feb 28, 2024

  1. Normalize line endings (#642)

    +semver:patch
    bethmaloney authored Feb 28, 2024
    Copy the full SHA
    4cb0374 View commit details

Commits on Mar 11, 2024

  1. Copy the full SHA
    ce48033 View commit details
  2. Obsolete APIs related to BinaryFormatter (#648)

    +semver:minor
    hazzik authored Mar 11, 2024
    Copy the full SHA
    13e3eb9 View commit details
  3. Remove unused usings (#649)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    1d18651 View commit details
  4. Replace null checks with is null / is not null (#650)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    ba6f6d0 View commit details
  5. Use null propagation where possible (#651)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    27c4785 View commit details
  6. Use auto properties where possible (#652)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    f6a633e View commit details
  7. Use .NET 8 SDK to build project (#655)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    32c9788 View commit details
  8. Use expression bodied properties (#653)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    f19aebc View commit details
  9. Use nameof where possible (#654)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    ae0011f View commit details
  10. Replace object.Equals with Type equals operator (#656)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    2c9a5a9 View commit details
  11. Make properties readonly where possible (#658)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    3e4405c View commit details
  12. Enable C#12 (#657)

    +semver:minor
    hazzik authored Mar 11, 2024
    Copy the full SHA
    7a9a86d View commit details
  13. Remove redundant Cast calls (#660)

    +semver:patch
    hazzik authored Mar 11, 2024
    Copy the full SHA
    550b06c View commit details

Commits on Mar 12, 2024

  1. Use C#12 primary constructors (#659)

    +semver:patch
    hazzik authored Mar 12, 2024
    Copy the full SHA
    366ab36 View commit details
  2. Implement missing IEquatable<> interfaces (#661)

    +semver:minor
    hazzik authored Mar 12, 2024
    Copy the full SHA
    47397ed View commit details
  3. Use Array.Empty where appropriate (#662)

    +semver:patch
    hazzik authored Mar 12, 2024
    Copy the full SHA
    6baa5ec View commit details
  4. Update dependency Polyfill to v4 (#663)

    +semver:patch
    renovate[bot] authored Mar 12, 2024
    Copy the full SHA
    dfd4110 View commit details

Commits on Mar 14, 2024

  1. Copy the full SHA
    2536ba1 View commit details
  2. Copy the full SHA
    c4da7ae View commit details

Commits on Mar 16, 2024

  1. Copy the full SHA
    49d38c1 View commit details

Commits on Mar 26, 2024

  1. Update dependency Polyfill to v4.1.0 (#666)

    +semver:patch
    renovate[bot] authored Mar 26, 2024
    Copy the full SHA
    2c365ad View commit details
  2. Remove redundant private modifiers (#667)

    +semver:patch
    hazzik authored Mar 26, 2024
    Copy the full SHA
    0eafff9 View commit details

Commits on Apr 2, 2024

  1. Copy the full SHA
    9675ab5 View commit details
  2. Update dependency Polyfill to v4.2.0 (#669)

    +semver:patch
    renovate[bot] authored Apr 2, 2024
    Copy the full SHA
    407387e View commit details
  3. Remove redundant private modifiers (#670)

    +semver:patch
    hazzik authored Apr 2, 2024
    Copy the full SHA
    3931d96 View commit details
  4. Fix overriding Id for automapping (#671)

    Fixes #431
    
    +semver:fix
    hazzik authored Apr 2, 2024
    Copy the full SHA
    33bd219 View commit details
  5. Copy the full SHA
    223392a View commit details
Showing 1,190 changed files with 87,044 additions and 91,513 deletions.
2 changes: 1 addition & 1 deletion .config/dotnet-tools.json
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@
"isRoot": true,
"tools": {
"cake.tool": {
"version": "3.0.0",
"version": "5.0.0",
"commands": [
"dotnet-cake"
]
19 changes: 15 additions & 4 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -2,10 +2,6 @@ root = true
; This file is for unifying the coding style for different editors and IDEs.
; More information at http://EditorConfig.org


[*]
end_of_line = crlf

[*.ps1]
indent_style = space
indent_size = 2
@@ -14,18 +10,33 @@ indent_size = 2
indent_style = space
indent_size = 4
insert_final_newline = true
max_line_length = off

csharp_style_namespace_declarations = file_scoped

dotnet_diagnostic.ide0161.severity = warning
dotnet_diagnostic.nunit1032.severity = suggestion
dotnet_diagnostic.nunit1028.severity = none
dotnet_diagnostic.nunit2045.severity = none

# ReSharper properties
resharper_default_private_modifier = implicit

# Microsoft .NET properties
dotnet_style_require_accessibility_modifiers = never:suggestion

[*.cake]
indent_style = space
indent_size = 4

[*.js]
indent_style = tab
indent_size = 2

[*.csproj]
indent_style = space
indent_size = 2

[*.props]
indent_style = space
indent_size = 2
30 changes: 28 additions & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,2 +1,28 @@
[core]
autocrlf=false
# Set the default behavior, in case people don't have core.autocrlf set.
* text=auto

# Explicitly declare text files you want to always be normalized and converted
# to native line endings on checkout.
*.cs text diff=csharp
*.xaml text
*.txt text
*.tt text
*.ps1 text
*.cmd text
*.msbuild text
*.md text

*.sln text eol=crlf
*.csproj text eol=crlf
*.vbproj text eol=crlf
*.fsproj text eol=crlf
*.dbproj text eol=crlf

# Resharper DotSettings files are in Unix format
*.DotSettings text eol=lf

# Binary files
*.png binary
*.jpg binary
*.dll binary
*.exe binary
10 changes: 7 additions & 3 deletions .github/renovate.json
Original file line number Diff line number Diff line change
@@ -1,18 +1,22 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": [
"config:base"
"config:recommended"
],
"labels": [
"build"
],
"packageRules": [
{
"matchSourceUrls": [ "https://github.com/nunit/nunit"],
"matchSourceUrls": [
"https://github.com/nunit/nunit"
],
"groupName": "NUnit"
},
{
"matchSourceUrls": [ "https://github.com/nunit/nunit-console"],
"matchSourceUrls": [
"https://github.com/nunit/nunit-console"
],
"groupName": "NUnit.Console"
}
]
46 changes: 23 additions & 23 deletions CODEOFCONDUCT.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
# Contributor Code of Conduct

As contributors and maintainers of this project, and in the interest of fostering an open and welcoming community, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.

We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, ethnicity, age, religion, or nationality.

Examples of unacceptable behavior by participants include:

- The use of sexualized language or imagery
- Personal attacks
- Trolling or insulting/derogatory comments
- Public or private harassment
- Publishing other's private information, such as physical or electronic addresses, without explicit permission
- Other unethical or unprofessional conduct

Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.

By adopting this Code of Conduct, project maintainers commit themselves to fairly and consistently applying these principles to every aspect of managing this project. Project maintainers who do not follow or enforce the Code of Conduct may be permanently removed from the project team.

This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community.

Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting a project maintainer. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. Maintainers are obligated to maintain confidentiality with regard to the reporter of an incident.

# Contributor Code of Conduct

As contributors and maintainers of this project, and in the interest of fostering an open and welcoming community, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.

We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, ethnicity, age, religion, or nationality.

Examples of unacceptable behavior by participants include:

- The use of sexualized language or imagery
- Personal attacks
- Trolling or insulting/derogatory comments
- Public or private harassment
- Publishing other's private information, such as physical or electronic addresses, without explicit permission
- Other unethical or unprofessional conduct

Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.

By adopting this Code of Conduct, project maintainers commit themselves to fairly and consistently applying these principles to every aspect of managing this project. Project maintainers who do not follow or enforce the Code of Conduct may be permanently removed from the project team.

This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community.

Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting a project maintainer. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. Maintainers are obligated to maintain confidentiality with regard to the reporter of an incident.

This Code of Conduct is adapted from the Contributor Covenant, version 1.3.0, available from http://contributor-covenant.org/version/1/3/0/
19 changes: 5 additions & 14 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,5 @@
# Contribution Guidelines

The wiki has a page on contributing to FNH:

https://github.com/nhibernate/fluent-nhibernate/wiki/Contributing

## Important
If you've just pulled the FNH code into a local git repository for the first time, its really important that you set the core.autocrlf setting to false to avoid running into whitespace/line ending issues. Do this using the following command:

```
git config core.autocrlf false
```


# Contribution Guidelines

The wiki has a page on contributing to FNH:

https://github.com/nhibernate/fluent-nhibernate/wiki/Contributing
2 changes: 1 addition & 1 deletion GitVersion.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
assembly-versioning-scheme: MajorMinor
mode: ContinuousDeployment
mode: ContinuousDelivery
78 changes: 37 additions & 41 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,41 +1,37 @@
![FluentNHibernate logo](https://raw.githubusercontent.com/nhibernate/fluent-nhibernate/main/docs/logo.png)

[![Build status](https://ci.appveyor.com/api/projects/status/684r2ot07i2lrcij/branch/main?svg=true)](https://ci.appveyor.com/project/nhibernate/fluent-nhibernate/branch/main)
[![NuGet](https://img.shields.io/nuget/v/FluentNHibernate.svg)](https://www.nuget.org/packages/FluentNHibernate)

## What is FluentNHibernate?
Fluent, XML-less, compile safe, automated, convention-based mappings for NHibernate. *Get your fluent on.*

## Where can I get it?

Install using the [FluentNHibernate NuGet package](https://www.nuget.org/packages/FluentNHibernate):

```
dotnet add package FluentNHibernate
```

## How do I use it?

* Read the [introduction](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Getting-started).
* Get latest version from NuGet
- [.NETCore2.0, NETStandard2.0 or NET 4.6.1 with NHibernate 5.x](https://www.nuget.org/packages/FluentNHibernate)
- [.NET 4.0 with NHibernate 4.x](https://www.nuget.org/packages/FluentNHibernate/2.0.3)
- [.NET 3.5 with NHibernate 3 if you like it vintage](https://www.nuget.org/packages/FluentNHibernate.Net35)

* Create your [first project](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Getting-started#wiki-yourfirstproject).

## Further reading

Once you've followed the above, you can compare our [auto mapping](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Auto-mapping) to our [fluent interface](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Fluent-mapping) to see which suits your application, read through our [API documentation](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Fluent-configuration), or just see what's available for reading in our [wiki](https://github.com/FluentNHibernate/fluent-nhibernate/wiki).

Contributors
---------------------------------------------

Fluent NHibernate wouldn't be possible without the time and effort of its contributors. The team comprises of [James Gregory](http://jagregory.com), [Paul Batum](http://www.paulbatum.com), Andrew Stewart, [Hudson Akridge](https://github.com/HudsonAkridge), [Gleb Chermennov](https://github.com/chester89) and [Jorge Rodríguez Galán](https://github.com/jrgcubano).

**Our valued committers are:** Aaron Jensen, Alexander Gross, Andrew Stewart, Barry Dahlberg, Bobby Johnson, Brian Donahue, Cameron Harris, Chad Myers, Chris Chilvers, Craig Neuwirt, Dan Malcolm, Daniel Mirapalheta, David Archer, David Longnecker, David R. Longnecker, Derick Bailey, Erik Ojebo, Firo, Hudson Akridge, Ivan Zlatev, James Freiwirth, James Gregory, James Kovacs, Jeremy Skinner, Lee Henson, Louis DeJardin, Patric Forsgard, Paul Batum, Roelof Blom, Stuart Childs, Tom Janssens, Tuna Toksoz, U-BSOD\pruiz, di97mni, dschilling, felixg, jeremydmiller, kevm, leebrandt, maxild, robsosno, [Jorge Rodríguez Galán](https://github.com/jrgcubano) and many more.</p>

Thanks goes to [Jeremy Miller](http://codebetter.com/blogs/jeremy.miller) for the original idea and implementation.

Fluent NHibernate is &copy; 2008-2018 [James Gregory](http://jagregory.com) and contributors under the [BSD license](https://github.com/nhibernate/fluent-nhibernate/blob/main/LICENSE)

![FluentNHibernate logo](https://raw.githubusercontent.com/nhibernate/fluent-nhibernate/main/docs/logo.png)

[![Build status](https://ci.appveyor.com/api/projects/status/684r2ot07i2lrcij/branch/main?svg=true)](https://ci.appveyor.com/project/nhibernate/fluent-nhibernate/branch/main)
[![NuGet](https://img.shields.io/nuget/v/FluentNHibernate.svg)](https://www.nuget.org/packages/FluentNHibernate)

## What is FluentNHibernate?
Fluent, XML-less, compile safe, automated, convention-based mappings for NHibernate. *Get your fluent on.*

## Where can I get it?

Install using the [FluentNHibernate NuGet package](https://www.nuget.org/packages/FluentNHibernate):

```
dotnet add package FluentNHibernate
```

## How do I use it?

* Read the [introduction](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Getting-started).
* Get latest version from [NuGet](https://www.nuget.org/packages/FluentNHibernate)
* Create your [first project](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Getting-started#wiki-yourfirstproject).

## Further reading

Once you've followed the above, you can compare our [auto mapping](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Auto-mapping) to our [fluent interface](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Fluent-mapping) to see which suits your application, read through our [API documentation](https://github.com/FluentNHibernate/fluent-nhibernate/wiki/Fluent-configuration), or just see what's available for reading in our [wiki](https://github.com/FluentNHibernate/fluent-nhibernate/wiki).

Contributors
---------------------------------------------

Fluent NHibernate wouldn't be possible without the time and effort of its contributors. The team comprises of [James Gregory](http://jagregory.com), [Paul Batum](http://www.paulbatum.com), Andrew Stewart, [Hudson Akridge](https://github.com/HudsonAkridge), [Gleb Chermennov](https://github.com/chester89) and [Jorge Rodríguez Galán](https://github.com/jrgcubano).

**Our valued committers are:** Aaron Jensen, Alexander Gross, Andrew Stewart, Barry Dahlberg, Bobby Johnson, Brian Donahue, Cameron Harris, Chad Myers, Chris Chilvers, Craig Neuwirt, Dan Malcolm, Daniel Mirapalheta, David Archer, David Longnecker, David R. Longnecker, Derick Bailey, Erik Ojebo, Firo, Hudson Akridge, Ivan Zlatev, James Freiwirth, James Gregory, James Kovacs, Jeremy Skinner, Lee Henson, Louis DeJardin, Patric Forsgard, Paul Batum, Roelof Blom, Stuart Childs, Tom Janssens, Tuna Toksoz, U-BSOD\pruiz, di97mni, dschilling, felixg, jeremydmiller, kevm, leebrandt, maxild, robsosno, [Jorge Rodríguez Galán](https://github.com/jrgcubano) and many more.</p>

Thanks goes to [Jeremy Miller](http://codebetter.com/blogs/jeremy.miller) for the original idea and implementation.

Fluent NHibernate is &copy; 2008-2018 [James Gregory](http://jagregory.com) and contributors under the [BSD license](https://github.com/nhibernate/fluent-nhibernate/blob/main/LICENSE)

14 changes: 7 additions & 7 deletions build.cake
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#addin "nuget:?package=Cake.FileHelpers&version=6.1.3"
#tool "dotnet:?package=GitReleaseManager.Tool&version=0.13.0"
#tool "dotnet:?package=GitVersion.Tool&version=5.12.0"
#addin "nuget:?package=Cake.FileHelpers&version=7.0.0"
#tool "dotnet:?package=GitReleaseManager.Tool&version=0.18.0"
#tool "dotnet:?package=GitVersion.Tool&version=6.0.5"

#load "./build/parameters.cake"

@@ -85,7 +85,7 @@ Task("Test")
{
DotNetTest(project.ToString(), new DotNetTestSettings
{
Framework = "net461",
Framework = "net48",
NoBuild = true,
NoRestore = true,
Configuration = parameters.Configuration
@@ -108,21 +108,21 @@ Task("Copy-Files")
PublishProjects(
SrcProjects, "net461",
parameters.Paths.Directories.ArtifactsBinFullFx.FullPath,
parameters.Version.DotNetAsterix,
parameters.Version.VersionSuffix,
parameters.Configuration,
msBuildSettings
);
PublishProjects(
SrcProjects, "netstandard2.0",
parameters.Paths.Directories.ArtifactsBinNetStandard20.FullPath,
parameters.Version.DotNetAsterix,
parameters.Version.VersionSuffix,
parameters.Configuration,
msBuildSettings
);
PublishProjects(
SrcProjects, "netcoreapp2.0",
parameters.Paths.Directories.ArtifactsBinNetCoreApp2.FullPath,
parameters.Version.DotNetAsterix,
parameters.Version.VersionSuffix,
parameters.Configuration,
msBuildSettings
);
54 changes: 27 additions & 27 deletions build/version.cake
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@ public class BuildVersion
{
public string Version { get; private set; }
public string SemVersion { get; private set; }
public string DotNetAsterix { get; private set; }
public string VersionSuffix { get; private set; }
public string Milestone { get; private set; }
public string AppVersion { get; private set; }
public string AssemblyVersion { get; private set; }
@@ -20,45 +20,45 @@ public class BuildVersion
string assemblyVersion = null;
string informationalVersion = null;
string milestone = null;
string preReleaseTag = null;

if (context.IsRunningOnWindows())
context.Information("Calculating Semantic Version");
if (!parameters.IsLocalBuild || parameters.IsPublishBuild || parameters.IsReleaseBuild)
{
context.Information("Calculating Semantic Version");
if (!parameters.IsLocalBuild || parameters.IsPublishBuild || parameters.IsReleaseBuild)
{
context.GitVersion(new GitVersionSettings{
UpdateAssemblyInfo = false,
OutputType = GitVersionOutput.BuildServer
});

version = context.EnvironmentVariable("GitVersion_MajorMinorPatch");
semVersion = context.EnvironmentVariable("GitVersion_LegacySemVerPadded");
assemblyVersion = context.EnvironmentVariable("GitVersion_AssemblySemVer");
informationalVersion = context.EnvironmentVariable("GitVersion_InformationalVersion");
milestone = string.Concat("v", version);
}

GitVersion assertedVersions = context.GitVersion(new GitVersionSettings
{
OutputType = GitVersionOutput.Json,
context.GitVersion(new GitVersionSettings{
UpdateAssemblyInfo = false,
OutputType = GitVersionOutput.BuildServer
});

version = assertedVersions.MajorMinorPatch;
semVersion = assertedVersions.LegacySemVerPadded;
assemblyVersion = assertedVersions.AssemblySemVer;
informationalVersion = assertedVersions.InformationalVersion;
version = context.EnvironmentVariable("GitVersion_MajorMinorPatch");
semVersion = context.EnvironmentVariable("GitVersion_SemVer");
preReleaseTag = context.EnvironmentVariable("GitVersion_PreReleaseTag");
assemblyVersion = context.EnvironmentVariable("GitVersion_AssemblySemVer");
informationalVersion = context.EnvironmentVariable("GitVersion_InformationalVersion");
milestone = string.Concat("v", version);

context.Information("Calculated Semantic Version: {0}", semVersion);
}

GitVersion assertedVersions = context.GitVersion(new GitVersionSettings
{
OutputType = GitVersionOutput.Json,
});

version = assertedVersions.MajorMinorPatch;
semVersion = assertedVersions.SemVer;
preReleaseTag = assertedVersions.PreReleaseTag;
assemblyVersion = assertedVersions.AssemblySemVer;
informationalVersion = assertedVersions.InformationalVersion;
milestone = string.Concat("v", version);

context.Information("Calculated Semantic Version: {0}", semVersion);

var appVersion = typeof(ICakeContext).Assembly.GetName().Version.ToString();

return new BuildVersion
{
Version = version,
SemVersion = semVersion,
DotNetAsterix = semVersion.Substring(version.Length).TrimStart('-'),
VersionSuffix = preReleaseTag,
Milestone = milestone,
AppVersion = appVersion,
AssemblyVersion = assemblyVersion,
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"sdk": {
"version": "6.0.403",
"version": "8.0.100",
"rollForward": "latestFeature"
}
}
Loading