diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
new file mode 100644
index 00000000..5fb11cc8
--- /dev/null
+++ b/.github/workflows/main.yml
@@ -0,0 +1,18 @@
+name: Build Non-Release Branch
+
+on:
+ push:
+ branches:
+ - feature/*
+ - bugfix/*
+ - hotfix/*
+
+jobs:
+ build:
+ name: Build
+ runs-on: self-hosted
+ steps:
+ - run: Invoke-WebRequest -URI "http://localhost:8080/job/Essentials%20Builds/build?token=$($Env:projectToken)" -Headers @{Authorization = "Basic $([System.Convert]::ToBase64String([System.Text.Encoding]::ASCII.GetBytes("ndorin:$($Env:token)")))"} -Method POST -UseBasicParsing
+ env:
+ token: ${{ secrets.TOKEN }}
+ projectToken: ${{ secrets.PROJECTTOKEN}}
diff --git a/PepperDashEssentials/ControlSystem.cs b/PepperDashEssentials/ControlSystem.cs
index 62aee267..a88d932b 100644
--- a/PepperDashEssentials/ControlSystem.cs
+++ b/PepperDashEssentials/ControlSystem.cs
@@ -96,10 +96,12 @@ namespace PepperDash.Essentials
string directoryPrefix;
directoryPrefix = Crestron.SimplSharp.CrestronIO.Directory.GetApplicationRootDirectory();
-
- var version = Crestron.SimplSharp.Reflection.Assembly.GetExecutingAssembly().GetName().Version;
- Global.SetAssemblyVersion(string.Format("{0}.{1}.{2}", version.Major, version.Minor, version.Build));
+ var fullVersion = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyInformationalVersionAttribute), false);
+
+ AssemblyInformationalVersionAttribute fullVersionAtt = fullVersion[0] as AssemblyInformationalVersionAttribute;
+
+ Global.SetAssemblyVersion(fullVersionAtt.InformationalVersion);
if (CrestronEnvironment.DevicePlatform != eDevicePlatform.Server) // Handles 3-series running Windows CE OS
{
diff --git a/PepperDashEssentials/Properties/AssemblyInfo.cs b/PepperDashEssentials/Properties/AssemblyInfo.cs
index 83beada4..36e6828b 100644
--- a/PepperDashEssentials/Properties/AssemblyInfo.cs
+++ b/PepperDashEssentials/Properties/AssemblyInfo.cs
@@ -1,8 +1,10 @@
using System.Reflection;
+using Crestron.SimplSharp.Reflection;
-[assembly: AssemblyTitle("PepperDashEssentials")]
-[assembly: AssemblyCompany("PepperDash Technology Corp")]
-[assembly: AssemblyProduct("PepperDashEssentials")]
-[assembly: AssemblyCopyright("Copyright © PepperDash Technology Corp 2018")]
-[assembly: AssemblyVersion("1.4.0.*")]
-
+[assembly: System.Reflection.AssemblyTitle("PepperDashEssentials")]
+[assembly: System.Reflection.AssemblyCompany("PepperDash Technology Corp")]
+[assembly: System.Reflection.AssemblyProduct("PepperDashEssentials")]
+[assembly: System.Reflection.AssemblyCopyright("Copyright © PepperDash Technology Corp 2020")]
+[assembly: System.Reflection.AssemblyVersion("0.0.0.*")]
+[assembly: System.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
+[assembly: Crestron.SimplSharp.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
diff --git a/PepperDashEssentials/Properties/UpdateAssemblyVersion.ps1 b/PepperDashEssentials/Properties/UpdateAssemblyVersion.ps1
index 46392b31..396b5cf0 100644
--- a/PepperDashEssentials/Properties/UpdateAssemblyVersion.ps1
+++ b/PepperDashEssentials/Properties/UpdateAssemblyVersion.ps1
@@ -1,13 +1,23 @@
function Update-SourceVersion
{
Param ([string]$Version)
- $NewVersion = ‘AssemblyVersion("‘ + $Version + ‘.*")’;
+ $fullVersion = $Version
+ $baseVersion = [regex]::Match($Version, "(\d+.\d+.\d+).*").captures.groups[1].value
+ $NewAssemblyVersion = ‘AssemblyVersion("‘ + $baseVersion + ‘.*")’
+ echo "AssemblyVersion = $NewAssemblyVersion"
+ $NewAssemblyInformationalVersion = ‘AssemblyInformationalVersion("‘ + $Version + ‘")’
+ echo "AssemblyInformationalVersion = $NewAssemblyInformationalVersion"
+
foreach ($o in $input)
- {
+ {
Write-output $o.FullName
$TmpFile = $o.FullName + “.tmp”
get-content $o.FullName |
- %{$_ -replace ‘AssemblyVersion\("(\d+\.\d+\.\d+)\.\*"\)’, $NewVersion } > $TmpFile
+ %{
+ $_ -replace ‘AssemblyVersion\(".*"\)’, $NewAssemblyVersion} |
+ %{
+ $_ -replace ‘AssemblyInformationalVersion\(".*"\)’, $NewAssemblyInformationalVersion
+ } > $TmpFile
move-item $TmpFile $o.FullName -force
}
}
@@ -21,9 +31,10 @@ function Update-AllAssemblyInfoFiles ( $version )
}
# validate arguments
-$r= [System.Text.RegularExpressions.Regex]::Match($args[0], "^\d+\.\d+\.\d+$");
+$r= [System.Text.RegularExpressions.Regex]::Match($args[0], "\d+\.\d+\.\d+.*");
if ($r.Success)
{
+ echo "Updating Assembly Version to $args ...";
Update-AllAssemblyInfoFiles $args[0];
}
else
diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Properties/AssemblyInfo.cs b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Properties/AssemblyInfo.cs
index 5c1f9863..c1b3b688 100644
--- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Properties/AssemblyInfo.cs
+++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Properties/AssemblyInfo.cs
@@ -1,7 +1,11 @@
using System.Reflection;
+using Crestron.SimplSharp.Reflection;
+
+[assembly: System.Reflection.AssemblyTitle("PepperDashEssentialsBase")]
+[assembly: System.Reflection.AssemblyCompany("PepperDash Technology Corp")]
+[assembly: System.Reflection.AssemblyProduct("PepperDashEssentials")]
+[assembly: System.Reflection.AssemblyCopyright("Copyright © PepperDash Technology Corp 2020")]
+[assembly: System.Reflection.AssemblyVersion("0.0.0.*")]
+[assembly: System.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
+[assembly: Crestron.SimplSharp.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
-[assembly: AssemblyTitle("PepperDashEssentialsBase")]
-[assembly: AssemblyCompany("PepperDash Technology Corp")]
-[assembly: AssemblyProduct("PepperDashEssentialsBase")]
-[assembly: AssemblyCopyright("Copyright © Pepperdash 2019")]
-[assembly: AssemblyVersion("1.4.0.*")]
\ No newline at end of file
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Essentials_DM.csproj b/essentials-framework/Essentials DM/Essentials_DM/Essentials_DM.csproj
index 322cbdab..e862f8a1 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Essentials_DM.csproj
+++ b/essentials-framework/Essentials DM/Essentials_DM/Essentials_DM.csproj
@@ -82,6 +82,10 @@
..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpPro.exe
False
+
+ False
+ ..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpReflectionInterface.dll
+
diff --git a/essentials-framework/Essentials DM/Essentials_DM/Properties/AssemblyInfo.cs b/essentials-framework/Essentials DM/Essentials_DM/Properties/AssemblyInfo.cs
index d11fa984..1f506f3a 100644
--- a/essentials-framework/Essentials DM/Essentials_DM/Properties/AssemblyInfo.cs
+++ b/essentials-framework/Essentials DM/Essentials_DM/Properties/AssemblyInfo.cs
@@ -1,7 +1,10 @@
using System.Reflection;
+using Crestron.SimplSharp.Reflection;
-[assembly: AssemblyTitle("Essentials_DM")]
-[assembly: AssemblyCompany("PepperDash Technology Corp")]
-[assembly: AssemblyProduct("Essentials_DM")]
-[assembly: AssemblyCopyright("Copyright © 2019")]
-[assembly: AssemblyVersion("1.3.*")]
\ No newline at end of file
+[assembly: System.Reflection.AssemblyTitle("Essentials_DM")]
+[assembly: System.Reflection.AssemblyCompany("PepperDash Technology Corp")]
+[assembly: System.Reflection.AssemblyProduct("PepperDashEssentials")]
+[assembly: System.Reflection.AssemblyCopyright("Copyright © PepperDash Technology Corp 2020")]
+[assembly: System.Reflection.AssemblyVersion("0.0.0.*")]
+[assembly: System.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
+[assembly: Crestron.SimplSharp.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
\ No newline at end of file
diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Properties/AssemblyInfo.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Properties/AssemblyInfo.cs
index 95a08a40..ccea4891 100644
--- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Properties/AssemblyInfo.cs
+++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Properties/AssemblyInfo.cs
@@ -1,7 +1,10 @@
using System.Reflection;
+using Crestron.SimplSharp.Reflection;
-[assembly: AssemblyTitle("Essentials_Devices_Common")]
-[assembly: AssemblyCompany("PepperDash Technology Corp")]
-[assembly: AssemblyProduct("Essentials_Devices_Common")]
-[assembly: AssemblyCopyright("Copyright © 2019")]
-[assembly: AssemblyVersion("1.4.*")]
\ No newline at end of file
+[assembly: System.Reflection.AssemblyTitle("Essentials_Devices_Common")]
+[assembly: System.Reflection.AssemblyCompany("PepperDash Technology Corp")]
+[assembly: System.Reflection.AssemblyProduct("PepperDashEssentials")]
+[assembly: System.Reflection.AssemblyCopyright("Copyright © PepperDash Technology Corp 2020")]
+[assembly: System.Reflection.AssemblyVersion("0.0.0.*")]
+[assembly: System.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
+[assembly: Crestron.SimplSharp.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
\ No newline at end of file