-
Notifications
You must be signed in to change notification settings - Fork 63
Expand file tree
/
Copy pathVersionProvider.cs
More file actions
38 lines (30 loc) · 1.01 KB
/
VersionProvider.cs
File metadata and controls
38 lines (30 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
using cloudscribe.Core.SimpleContent.Integration;
using cloudscribe.Versioning;
using cloudscribe.Web.Common;
using System;
using System.Reflection;
namespace cloudscribe.Core.SimpleContent
{
public class VersionProvider : IVersionProvider
{
private Assembly assembly = typeof(AuthorNameResolver).Assembly;
public string Name
{
get { return assembly.GetName().Name; }
}
public Guid ApplicationId { get { return new Guid("f94177b4-919d-4910-acd1-4b3b1c210ecf"); } }
public Version CurrentVersion
{
get
{
var version = new Version(2, 0, 0, 0);
var versionString = typeof(CloudscribeCommonResources).Assembly.GetCustomAttribute<AssemblyFileVersionAttribute>().Version;
if (!string.IsNullOrWhiteSpace(versionString))
{
Version.TryParse(versionString, out version);
}
return version;
}
}
}
}