diff --git a/.github/workflows/aurora-dev.yml b/.github/workflows/aurora-dev.yml
new file mode 100644
index 000000000..0d63791e7
--- /dev/null
+++ b/.github/workflows/aurora-dev.yml
@@ -0,0 +1,106 @@
+name: Aurora CD
+
+on:
+ push:
+ branches: [ dev ]
+
+jobs:
+
+ build:
+
+ strategy:
+ matrix:
+ configuration: [Release]
+
+ runs-on: windows-latest # For a list of available runner types, refer to
+ # https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on
+
+ env:
+ Solution_Name: Project-Aurora/Project-Aurora.sln
+
+ steps:
+ - name: Generate build number
+ id: buildnumber
+ uses: einaregilsson/build-number@v3
+ with:
+ token: ${{secrets.github_token}}
+
+ - uses: rishabhgupta/split-by@v1
+ id: split
+ with:
+ string: ${{github.repository}}
+ split-by: '/'
+ - run: |
+ echo "${{github.repository}}"
+ - run: |
+ echo "${{ steps.split.outputs._0}}"
+ - run: |
+ echo "${{ steps.split.outputs._1}}"
+
+ - name: Checkout
+ uses: actions/checkout@v2
+ with:
+ fetch-depth: 0
+ submodules: true
+
+ # Install the .NET Core workload
+ - name: Install .NET Core
+ uses: actions/setup-dotnet@v1
+ with:
+ dotnet-version: 5.0.x
+
+ # Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild
+ - name: Setup MSBuild.exe
+ uses: microsoft/setup-msbuild@v1.0.2
+
+ # Restore the application to populate the obj folder with RuntimeIdentifiers
+ - name: Restore the application
+ run: msbuild $env:Solution_Name /t:Restore /p:Configuration=$env:Configuration
+ env:
+ Configuration: ${{ matrix.configuration }}
+
+ # Restore the application to populate the obj folder with RuntimeIdentifiers
+ - name: Build
+ run: msbuild $env:Solution_Name /p:Configuration=$env:Configuration
+ env:
+ APPVEYOR_BUILD_VERSION: v${{steps.buildnumber.outputs.build_number}}
+ OWNER: ${{ steps.split.outputs._0 }}
+ REPOSITORY: ${{ steps.split.outputs._1 }}
+ Configuration: ${{ matrix.configuration }}
+
+ # Decode the base 64 encoded pfx and save the Signing_Certificate
+ #- name: Decode the pfx
+ # run: |
+ # $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.Base64_Encoded_Pfx }}")
+ # $certificatePath = Join-Path -Path $env:Wap_Project_Directory -ChildPath GitHubActionsWorkflow.pfx
+ # [IO.File]::WriteAllBytes("$certificatePath", $pfx_cert_byte)
+
+ # Create the app package by building and packaging the Windows Application Packaging project
+ - name: Building the installer
+ run: |
+ "%programfiles(x86)%\Inno Setup 6\iscc.exe" /DEXTERNAL_VERSION=${{steps.buildnumber.outputs.build_number}} Installer\installer.iss
+ shell: cmd
+
+ - name: Archive Release
+ uses: vimtor/action-zip@v1
+ with:
+ files: Build\Release\
+ dest: Aurora-v${{steps.buildnumber.outputs.build_number}}.zip
+
+ - name: Installer Release
+ uses: svenstaro/upload-release-action@2.2.1
+ with:
+ repo_token: ${{ secrets.GITHUB_TOKEN }}
+ file: "Aurora-setup-v${{steps.buildnumber.outputs.build_number}}.exe"
+ tag: v${{steps.buildnumber.outputs.build_number}}
+ overwrite: false
+ prerelease: true
+
+ - name: Zip Release
+ uses: svenstaro/upload-release-action@2.2.1
+ with:
+ repo_token: ${{ secrets.GITHUB_TOKEN }}
+ file: Aurora-v${{steps.buildnumber.outputs.build_number}}.zip
+ tag: v${{steps.buildnumber.outputs.build_number}}
+ overwrite: false
+ prerelease: true
diff --git a/.github/workflows/aurora-release.yml b/.github/workflows/aurora-release.yml
new file mode 100644
index 000000000..7c02be901
--- /dev/null
+++ b/.github/workflows/aurora-release.yml
@@ -0,0 +1,104 @@
+name: Aurora CD
+
+on:
+ push:
+ branches: [ master ]
+
+jobs:
+
+ build:
+
+ strategy:
+ matrix:
+ configuration: [Release]
+
+ runs-on: windows-latest # For a list of available runner types, refer to
+ # https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on
+
+ env:
+ Solution_Name: Project-Aurora/Project-Aurora.sln
+
+ steps:
+ - name: Generate build number
+ id: buildnumber
+ uses: einaregilsson/build-number@v3
+ with:
+ token: ${{secrets.github_token}}
+
+ - uses: rishabhgupta/split-by@v1
+ id: split
+ with:
+ string: ${{github.repository}}
+ split-by: '/'
+ - run: |
+ echo "${{github.repository}}"
+ - run: |
+ echo "${{ steps.split.outputs._0}}"
+ - run: |
+ echo "${{ steps.split.outputs._1}}"
+
+ - name: Checkout
+ uses: actions/checkout@v2
+ with:
+ fetch-depth: 0
+ submodules: true
+
+ # Install the .NET Core workload
+ - name: Install .NET Core
+ uses: actions/setup-dotnet@v1
+ with:
+ dotnet-version: 5.0.x
+
+ # Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild
+ - name: Setup MSBuild.exe
+ uses: microsoft/setup-msbuild@v1.0.2
+
+ # Restore the application to populate the obj folder with RuntimeIdentifiers
+ - name: Restore the application
+ run: msbuild $env:Solution_Name /t:Restore /p:Configuration=$env:Configuration
+ env:
+ Configuration: ${{ matrix.configuration }}
+
+ # Restore the application to populate the obj folder with RuntimeIdentifiers
+ - name: Build
+ run: msbuild $env:Solution_Name /p:Configuration=$env:Configuration
+ env:
+ APPVEYOR_BUILD_VERSION: v${{steps.buildnumber.outputs.build_number}}
+ OWNER: ${{ steps.split.outputs._0 }}
+ REPOSITORY: ${{ steps.split.outputs._1 }}
+ Configuration: ${{ matrix.configuration }}
+
+ # Decode the base 64 encoded pfx and save the Signing_Certificate
+ #- name: Decode the pfx
+ # run: |
+ # $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.Base64_Encoded_Pfx }}")
+ # $certificatePath = Join-Path -Path $env:Wap_Project_Directory -ChildPath GitHubActionsWorkflow.pfx
+ # [IO.File]::WriteAllBytes("$certificatePath", $pfx_cert_byte)
+
+ # Create the app package by building and packaging the Windows Application Packaging project
+ - name: Building the installer
+ run: |
+ "%programfiles(x86)%\Inno Setup 6\iscc.exe" /DEXTERNAL_VERSION=${{steps.buildnumber.outputs.build_number}} Installer\installer.iss
+ shell: cmd
+
+ - name: Archive Release
+ uses: vimtor/action-zip@v1
+ with:
+ files: Build\Release\
+ dest: Aurora-v${{steps.buildnumber.outputs.build_number}}.zip
+
+ - name: Installer Release
+ uses: svenstaro/upload-release-action@2.2.1
+ with:
+ repo_token: ${{ secrets.GITHUB_TOKEN }}
+ file: "Aurora-setup-v${{steps.buildnumber.outputs.build_number}}.exe"
+ tag: v${{steps.buildnumber.outputs.build_number}}
+ overwrite: false
+
+ - name: Zip Release
+ uses: svenstaro/upload-release-action@2.2.1
+ with:
+ repo_token: ${{ secrets.GITHUB_TOKEN }}
+ file: Aurora-v${{steps.buildnumber.outputs.build_number}}.zip
+ tag: v${{steps.buildnumber.outputs.build_number}}
+ overwrite: false
diff --git a/Project-Aurora/Aurora-Updater/Program.cs b/Project-Aurora/Aurora-Updater/Program.cs
index 4f9216a61..06f8d5889 100755
--- a/Project-Aurora/Aurora-Updater/Program.cs
+++ b/Project-Aurora/Aurora-Updater/Program.cs
@@ -4,6 +4,7 @@
using System.Security.Principal;
using System.Windows.Forms;
using System.Linq;
+using System.Reflection;
using Version = SemVer.Version;
namespace Aurora_Updater
@@ -82,10 +83,13 @@ static void Main(string[] args)
MessageBoxButtons.OK);
return;
}
- versionMajor = new Version(_maj, true);
+ versionMajor = new Version(_maj.TrimStart('v') + ".0.0", true);
+
+ string owner = FileVersionInfo.GetVersionInfo(auroraPath).CompanyName;
+ string repository = FileVersionInfo.GetVersionInfo(auroraPath).ProductName;
//Initialize UpdateManager
- StaticStorage.Manager = new UpdateManager(versionMajor);
+ StaticStorage.Manager = new UpdateManager(versionMajor, owner, repository);
//Check if update retrieval was successful.
if (StaticStorage.Manager.updateState == UpdateStatus.Error)
@@ -109,7 +113,7 @@ static void Main(string[] args)
}
else
{
- Version latestV = new Version(StaticStorage.Manager.LatestRelease.TagName.TrimStart('v'), true);
+ Version latestV = new Version(StaticStorage.Manager.LatestRelease.TagName.TrimStart('v') + ".0.0", true);
if (latestV > versionMajor)
{
diff --git a/Project-Aurora/Aurora-Updater/UpdateManager.cs b/Project-Aurora/Aurora-Updater/UpdateManager.cs
index fa79fe818..c43dafade 100755
--- a/Project-Aurora/Aurora-Updater/UpdateManager.cs
+++ b/Project-Aurora/Aurora-Updater/UpdateManager.cs
@@ -75,11 +75,11 @@ public class UpdateManager
private GitHubClient gClient = new GitHubClient(new ProductHeaderValue("aurora-updater"));
public Release LatestRelease;
- public UpdateManager(Version version)
+ public UpdateManager(Version version, string author, string repoName)
{
LoadSettings();
PerformCleanup();
- FetchData(version);
+ FetchData(version, author, repoName);
}
public void LoadSettings()
@@ -109,20 +109,23 @@ public int GetTotalProgress()
return (int)((downloadProgess + extractProgess) / 2.0f * 100.0f);
}
- private bool FetchData(Version version)
+ private bool FetchData(Version version, string owner, string repositoryName)
{
try
{
if (Config.GetDevReleases || !String.IsNullOrWhiteSpace(version.PreRelease))
- LatestRelease = gClient.Repository.Release.GetAll("antonpup", "Aurora", new ApiOptions { PageCount = 1, PageSize = 1 }).Result[0];
+ LatestRelease = gClient.Repository.Release.GetAll(owner, repositoryName, new ApiOptions { PageCount = 1, PageSize = 1 }).Result[0];
else
- LatestRelease = gClient.Repository.Release.GetLatest("antonpup", "Aurora").Result;
+ LatestRelease = gClient.Repository.Release.GetLatest(owner, repositoryName).Result;
//Console.WriteLine(reply);
}
catch (Exception exc)
{
updateState = UpdateStatus.Error;
+ MessageBox.Show(
+ $"Could not find update.\r\nError:\r\n{exc}",
+ "Aurora Updater - Error");
return false;
}
diff --git a/Project-Aurora/Project-Aurora/Directory.Build.props b/Project-Aurora/Project-Aurora/Directory.Build.props
index b17c4a495..1fdb38d01 100644
--- a/Project-Aurora/Project-Aurora/Directory.Build.props
+++ b/Project-Aurora/Project-Aurora/Directory.Build.props
@@ -3,14 +3,18 @@
Aurora
Unified Lighting Effects across different RGB devices
- Aurora
Copyright © 2017
1.0.0.0
false
+ true
$(APPVEYOR_BUILD_VERSION)
- 0.8.1
+ v0
+ $(OWNER)
+ Aurora-RGB
+ $(REPOSITORY)
+ Aurora
diff --git a/Project-Aurora/Project-Aurora/Settings/Control_Settings.xaml b/Project-Aurora/Project-Aurora/Settings/Control_Settings.xaml
index 3f5289669..f45ed217e 100755
--- a/Project-Aurora/Project-Aurora/Settings/Control_Settings.xaml
+++ b/Project-Aurora/Project-Aurora/Settings/Control_Settings.xaml
@@ -1,384 +1,384 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Project-Aurora/Project-Aurora/Settings/Control_Settings.xaml.cs b/Project-Aurora/Project-Aurora/Settings/Control_Settings.xaml.cs
index e3e684fea..5ac84f138 100755
--- a/Project-Aurora/Project-Aurora/Settings/Control_Settings.xaml.cs
+++ b/Project-Aurora/Project-Aurora/Settings/Control_Settings.xaml.cs
@@ -80,12 +80,17 @@ public Control_Settings()
}
catch (Exception exc)
{
- Global.logger.Error("Error caught when updating startup task. Error: " + exc.ToString());
+ Global.logger.Error("Error caught when updating startup task. Error: " + exc);
}
string v = FileVersionInfo.GetVersionInfo(System.Reflection.Assembly.GetExecutingAssembly().Location).FileVersion;
+ string o = FileVersionInfo.GetVersionInfo(System.Reflection.Assembly.GetExecutingAssembly().Location).CompanyName;
+ string r = FileVersionInfo.GetVersionInfo(System.Reflection.Assembly.GetExecutingAssembly().Location).ProductName;
- this.lblVersion.Content = ((int.Parse(v[0].ToString()) > 0) ? "" : "beta ") + $"v{v}";
+ this.lblVersion.Content = (v[0].ToString().Length > 0 ? "" : "beta ") + $"{v} {o}/{r}";
+ this.LnkIssues.NavigateUri = new Uri($"https://github.com/{o}/{r}/issues/");
+ this.LnkRepository.NavigateUri = new Uri($"https://github.com/{o}/{r}");
+ this.LnkContributors.NavigateUri = new Uri($"https://github.com/{o}/{r}#contributors-");
var rzVersion = RzHelper.GetSdkVersion();
var rzSdkEnabled = RzHelper.IsSdkEnabled();
diff --git a/appveyor.yml b/appveyor.yml
deleted file mode 100644
index c393db37d..000000000
--- a/appveyor.yml
+++ /dev/null
@@ -1,53 +0,0 @@
-version: 0.8.1+{build}
-pull_requests:
- do_not_increment_build_number: true
-branches:
- except:
- - pi-lighting
-skip_branch_with_pr: true
-configuration: Release
-platform: x64
-image: Visual Studio 2019
-
-init:
- - ps: >-
- if ($env:APPVEYOR_REPO_TAG -eq "true")
- {
- Update-AppveyorBuild -Version "$($env:APPVEYOR_REPO_TAG_NAME.TrimStart("v"))"
- }
-
-before_build:
-- cmd: >-
- git submodule update --init --recursive
-
- cd Project-Aurora
-
- nuget restore
-
-after_build:
-- cmd: >-
- set PATH="C:\Program Files (x86)\Inno Setup 6";%PATH%
-
- ISCC.exe /DEXTERNAL_VERSION=%APPVEYOR_BUILD_VERSION% %APPVEYOR_BUILD_FOLDER%\Installer\installer.iss
-
-
-build:
- project: Project-Aurora\Project-Aurora.sln
- verbosity: minimal
-
-artifacts:
- - path: Build\Release
- name: Aurora-v$(appveyor_build_version)
- type: zip
- - path: Aurora-setup-v$(appveyor_build_version).exe
-
-deploy:
- description: 'Release description'
- provider: GitHub
- auth_token:
- secure: fH71/PvnIYe92vatcu/GCBXaAHNcwGWG7Olubsw5DCUy7eHWSs7QcY2u/WalhMfg
- artifact: Build\Aurora-v$(appveyor_build_version).zip,Aurora-setup-v$(appveyor_build_version).exe
- draft: true
- prerelease: false
- on:
- appveyor_repo_tag: true
\ No newline at end of file