Partas.GitNet
0.1.0
See the version list below for details.
dotnet add package Partas.GitNet --version 0.1.0
NuGet\Install-Package Partas.GitNet -Version 0.1.0
<PackageReference Include="Partas.GitNet" Version="0.1.0" />
<PackageVersion Include="Partas.GitNet" Version="0.1.0" />
<PackageReference Include="Partas.GitNet" />
paket add Partas.GitNet --version 0.1.0
#r "nuget: Partas.GitNet, 0.1.0"
#:package Partas.GitNet@0.1.0
#addin nuget:?package=Partas.GitNet&version=0.1.0
#tool nuget:?package=Partas.GitNet&version=0.1.0
GitNet
GitNet is a library and cli framework for automatically managing changelogs,
versioning, and tagging FSharp projects in a monorepo using ConventionalCommits spec,
and an early spec of a flavored semver that is purely made to delineate tags in a monorepo.
Using conventional commits, your ci will be able to automatically update your versions and commit changes/tags, and write your release notes in a structured manner.
There will be functions to separate each step, or an EZ mode function to just run everything with blind acceptance.
A CLI will be made to make this usable outside of FSX/FAKE.
You can see an early example of what the output looks like at this stage at the bottom of the repo.
This should be mostly done by the end of the week.
It's probably worth mentioning what GitNet plans to do differently.
For starters, this performs finer grained version bumps in a mono-repo. A commit must make changes to a directory/scope/project for that commit to be considered as a part of that project. A major bump version in one project will not result in your whole repo blowing out.
This will be best for F# users, as it will AUTOMATICALLY discover your projects unless configured to ignore them. It then observers whether commits have made changes to that project directory to 'map' the commit to that project.
It will discover assembly files and update them for you. It will update the fsproj for you with the new version details. All of this is configurable.
Motivation
I have a mono repo like Partas.Solid.Primitives which is a pain to manage and maintain.
Configuration
Design
- Output type
- Splitting
- Mono file
- File per scope
- File per epoch
- Formatting
- Scope grouping
- Scope prefixing
- Prefix per scope
- Epoch grouping
- Splitting
- Output path
- Output name (implicit to above)
- fine grained per project
- Project type
- Fsharp
- Ignore projects
- General
- Defining scopes to paths
- Fsharp
- Scoping names
- Autobump error (error on attempt to create the file if it requires bumping)
- Forced bump
- Bump for scope
- Bump target
- Bump all by patch/minor/major/epoch
- Author specific
- ignore author (for bots etc)
- Generate 'Release' notes for releases piped to output pre-formatted
- GH auto release
- Assembly file management
- Scope settings
- no scoping (just normal commit logging)
- explicit scopes (only log scoped)
- autoscope (makes scopes for those not ignored)
- explicit scopes and noscoping (log explicit scopes, and bundle the rest, no version management though)
- type/description keyword/footer → bump type
- grouping matcher
- format groupings
- format content in general
- exclude paths
- initial versions if unset
- github url
Implementation
- Output type
- Splitting
- Mono file
- File per scope
- File per epoch
- Formatting
- Scope grouping
- Scope prefixing
- Prefix per scope
- Epoch grouping
- Splitting
- Output path
- Output name (implicit to above)
- fine grained per project
- Project type
- Fsharp
- Ignore projects
- General
- Defining scopes to paths
- Fsharp
- Scoping names
- Autobump error (error on attempt to create the file if it requires bumping)
- Forced bump
- Bump for scope
- Bump target
- Bump all by patch/minor/major/epoch
- Author specific
- ignore author (for bots etc)
- Generate 'Release' notes for releases piped to output pre-formatted
- GH auto release
- Assembly file management
- Scope settings
- no scoping (just normal commit logging)
- explicit scopes (only log scoped)
- autoscope (makes scopes for those not ignored)
- explicit scopes and noscoping (log explicit scopes, and bundle the rest, no version management though)
- type/description keyword/footer → bump type
- grouping matcher
- format groupings
- format content in general
- exclude paths
- initial versions if unset
- github url
- Temporarily version projects during build time so they reference each other correctly.
API Brainstorming
let config =
// make config
let runtime = new GitNetRuntime(config)
let bumps,output =
runtime.Run()
|> runtime.WriteAssemblyFiles
// bumps - dictionary of scopes to their
// new sepoch semvers
// output - markdown output for the changelogs
runtime.VersionProjects(bumps) (* takes the
bumps and uses that to match the projects
which have their version and packageVersion
fields overwritten.
Disposal functions can be used to revert
the changes if desired.
`runtime.RevertVersionProjects()`
This can be dangerous, as you might accidentally use
old package versions in your build process.
If this is done in a CI process, you'll want
to commit the changes.
*)
runtime.CommitChanges("GitHub Actions", "noreply@github.com")
// Importantly, and an essential first step is to commit the tags
runtime.CommitTags(bumps.Values)
// The commit tag method just applies any sequence of tags to
// the repo. So you can make your own and shoot them in.
// Afterwards you'd probably want to regenerate the content of the
// markdown before you write it to a file.
<details>
RELEASE NOTES
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to a flavored version of Semantic Versioning.
<details>
<summary>See the spec for this SemVer flavor.</summary>
<h3>Epoch Scoped Semver</h3>
This flavor adds an optional marketable value called an EPOCH
.
There is also an optional disambiguating SCOPE
identifier for delineating tags for packages in a mono repo.
<blockquote>The motivation for this is to prevent resistance to utilising SemVer major bumps correctly, by allowing a separate marketable identifier which is easily compatible with the current SemVer spec.</blockquote> An Epoch/Scope (Sepoch) is an OPTIONAL prefix to a typical SemVer.
A Sepoch MUST BE bounded by
_
underscores_
.The identifiers MUST BE ALPHABETICAL (A-Za-z) identifiers.
The Epoch SHOULD BE upper case
The Epoch MUST come before the Scope, if both are present.
The Scope MUST additionally be bounded by
(
parenthesis)
.The Scope SHOULD BE capitalised/pascal cased.
A Sepoch CAN BE separated from SemVer by a single white space where this is allowed (ie not allowed in git tags).
Epoch DOES NOT influence precedence.
Scope MUST uniquely identify a single components versioning.
Different scopes CANNOT BE compared for precedence.
A SemVer without a Scope CAN BE compared to a Scoped SemVer for compatibility. But caution is advised.
There is no enforcement for ordering EPOCHs in this spec, as it would be overly restrictive and yield little value since we can delineate and earlier EPOCH from a later EPOCH by the SemVers.
Examples:
gitGraph
commit tag: "_ALPS_1.2.3"
branch develop
commit id: "add: ..."
commit
checkout main
cherry-pick id: "add: ..." tag: "_ALPS_2.1.3"
checkout develop
commit
commit
checkout main
merge develop tag: "_ALPS_3.4.5"
checkout develop
commit
commit
checkout main
merge develop tag: "_BRAVO_4.0.0" type: HIGHLIGHT
While there are breaking changes between versions 1 to 3, we expect that it is less than from 3 to 4. We expect the API surface would change more dramatically, or there is some other significant milestone improvement, in the change from version 3 epoch ALPS to version 4 epoch BRAVO.
_WILDLANDS(Core)_ 4.2.0
_WILDLANDS(Engine)_ 0.5.3
_DELTA(Core)_ 5.0.0
_DELTA(Engine)_ 0.5.3
Cannot be compared to Core
versions. Both Engine versions are equal, we can identify that
the ecosystems marketed change does not change the Engine packages API
</details> <details> <summary>Quick navigation</summary> <h3>Scopes:</h3> <ul> <li><a href="#ark">Ark</a></li> <li><a href="#cmdk">Cmdk</a></li> <li><a href="#corvu">Corvu</a></li> <li><a href="#generator">Generator</a></li> <li><a href="#jitbox">JitBox</a></li> <li><a href="#tests">Tests</a></li> <li><a href="#kobalte">Kobalte</a></li> <li><a href="#lucide">Lucide</a></li> <li><a href="#solid">Solid</a></li> </ul> </details>
Ark
UNRELEASED
Cmdk
UNRELEASED
Corvu
UNRELEASED
Generator
UNRELEASED
JitBox
UNRELEASED
- chorgi - cabboose@5f74a
1.0.1 - (2025-8-18)
Fixed
- assemblyinfo - cabboose@92498
1.0.0 - (2025-8-18)
Others
0.2.0 - (2025-8-18)
Added
- blubber - cabboose@fccf1
Tests
UNRELEASED
More components ported - cabboose@f06cf
upod - cabboose@f7eff
Init - cabboose@5d1e0
init repo - cabboose@81662
Kobalte
UNRELEASED
Lucide
UNRELEASED
Solid
UNRELEASED
</details>
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- Fake.DotNet.AssemblyInfoFile (>= 6.1.3)
- Fake.DotNet.Cli (>= 6.1.3)
- Fake.IO.FileSystem (>= 6.1.3)
- FSharp.Core (>= 9.0.202)
- FSharp.Formatting.Markdown (>= 1.0.0)
- FsToolkit.ErrorHandling (>= 5.0.1)
- Partas.GitNet.Markdown (>= 1.0.0)
- Partas.LibGit2Sharp.FSharp (>= 0.3.0)
- Partas.Tools.ConventionalCommits (>= 0.3.0)
- Partas.Tools.SepochSemver (>= 0.4.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
ALPHA release