Skip to content

Commit

Permalink
automatic version from assembly
Browse files Browse the repository at this point in the history
  • Loading branch information
RagingKore committed May 14, 2024
1 parent c43901c commit 83750f0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/EventStore.Plugins/Plugin.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ namespace EventStore.Plugins;
[PublicAPI]
public abstract class Plugin : IPlugableComponent, IDisposable {
protected Plugin(
string? name = null, string version = "0.0.1",
string? name = null, string? version = null,
string? diagnosticsName = null,
params KeyValuePair<string, object?>[] diagnosticsTags) {
Name = name ?? GetType().Name
.Replace("Subsystem", "")
.Replace("Plugin", "")
.Replace("Component", "");

Version = version;
Version = version ?? GetType().Assembly.GetName().Version?.ToString() ?? "0.0.1";

DiagnosticsName = diagnosticsName ?? Name;
DiagnosticsTags = diagnosticsTags;
Expand Down

0 comments on commit 83750f0

Please sign in to comment.