Replies: 6 comments 11 replies
-
I'm not sure if common is a good naming. Maybe Contract or Abstractions? Everything else looks good for me. |
Beta Was this translation helpful? Give feedback.
-
Naming is hard, you know ;), but I agree, |
Beta Was this translation helpful? Give feedback.
-
My question is what should we do with |
Beta Was this translation helpful? Give feedback.
-
Well the current state of the code base: we have Then we have the consumer apps or the packages/tools that the GitVersion user will actually use - These 2 apps will reference the The idea behind the |
Beta Was this translation helpful? Give feedback.
-
Okay, I've finally found some time to take a look at this. I don't think we need to adjust the proposed diagram much. I suggest we do is merge I'm also a bit unsure about whether we want to publish all of the projects marked with Lastly,
|
Beta Was this translation helpful? Give feedback.
-
Here is a conceptual components diagram that I think we should split the current code
Those that are in yellow will be packaged as nuget packages.
Details:
GitVersion.Common
- will contain the interfaces needed for version calculation, for build agents and output, git interfaces as well as common infrastructure interfaces like ILogger, IFileSystem and so on.GitVersion.Core
- will contain the implementation of infrastructure interfaces as well as the version calculation logic and configuration reading, writing, computing the effective configuration.GitVersion.BuildAgents
- will contain different build agents implementations. The package will be referenced byGitVersion.App
andGitVersion.MsBuild
GitVersion.Output
- will contain different output options implementations like file, envvars, a formatted string and so on. The package will be referenced byGitVersion.App
andGitVersion.MsBuild
GitVersion.LibGit2Sharp
- will contain a libgit2sharp implementation of the git interfaces. The package will be referenced byGitVersion.App
andGitVersion.MsBuild
GitVersion.ManagedGit
- will contain a managed git implementation of the git interfaces. The package will be referenced byGitVersion.App
andGitVersion.MsBuild
GitVersion.App
- the dotnet tool that referencesGitVersion.Core
as libs andGitVersion.BuildAgents
,GitVersion.Output
and (GitVersion.LibGit2Sharp
orGitVersion.ManagedGit
)GitVersion.MsBuild
- similar toGitVersion.App
In case someone wants to use the GitVersion as a lib and use the version calculation in their code, they will be able to reference the
GitVersion.Core
, eitherGitVersion.LibGit2Sharp
orGitVersion.ManagedGit
and optionallyGitVersion.BuildAgents
andGitVersion.Output
. The consumer will be able to provide he's own BuildAgent implementation or output format they needBeta Was this translation helpful? Give feedback.
All reactions