Skip to content

Commit da498ef

Browse files
committed
Revert "Merge branch 'master' of https://github.com/ArthurGamerHD/Artemis"
This reverts commit 850a403.
1 parent 850a403 commit da498ef

636 files changed

Lines changed: 2860 additions & 4467 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/docfx.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Master - DocFX
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches:
7+
- master
8+
9+
jobs:
10+
docfx:
11+
name: Build DocFX Documentation
12+
runs-on: windows-latest
13+
steps:
14+
- name: Checkout
15+
uses: actions/checkout@v4
16+
- name: Setup .NET
17+
uses: actions/setup-dotnet@v4
18+
with:
19+
dotnet-version: "8.0.x"
20+
- name: Setup DocFX
21+
run: dotnet tool update -g docfx
22+
- name: Build Core
23+
run: dotnet build src/Artemis.Core/Artemis.Core.csproj
24+
- name: Build UI.Shared
25+
run: dotnet build src/Artemis.UI.Shared/Artemis.UI.Shared.csproj
26+
- name: Build DocFX
27+
run: docfx docfx/docfx_project/docfx.json
28+
- name: Upload to FTP
29+
uses: SamKirkland/FTP-Deploy-Action@v4.3.5
30+
with:
31+
server: www360.your-server.de
32+
protocol: ftps
33+
username: ${{ secrets.FTP_USER }}
34+
password: ${{ secrets.FTP_PASSWORD }}
35+
local-dir: docfx/docfx_project/_site/
36+
server-dir: /docs/

.github/workflows/master.yml

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,9 @@ jobs:
2222
run: |
2323
$MidnightUtc = [DateTime]::UtcNow.Date
2424
$BranchName = "${{ github.ref_name }}".replace('/','-').replace('.','-')
25+
$ApiVersion = (Select-Xml -Path 'src/Artemis.Core/Artemis.Core.csproj' -XPath '//PluginApiVersion').Node.InnerText
2526
$NumberOfCommitsToday = (git log --after=$($MidnightUtc.ToString("o")) --oneline | Measure-Object -Line).Lines
26-
$VersionNumber = "1.$($MidnightUtc.ToString("yyyy.MMdd")).$NumberOfCommitsToday"
27+
$VersionNumber = "$ApiVersion.$($MidnightUtc.ToString("yyyy.MMdd")).$NumberOfCommitsToday"
2728
# If we're not in master, add the branch name to the version so it counts as prerelease
2829
if ($BranchName -ne "master") { $VersionNumber += "-$BranchName" }
2930
"version-number=$VersionNumber" >> $Env:GITHUB_OUTPUT
@@ -51,12 +52,26 @@ jobs:
5152
uses: actions/checkout@v4
5253
with:
5354
path: Artemis
55+
- name: Checkout Plugins
56+
uses: actions/checkout@v4
57+
with:
58+
repository: Artemis-RGB/Artemis.Plugins
59+
path: Artemis.Plugins
5460
- name: Setup .NET
5561
uses: actions/setup-dotnet@v4
5662
with:
57-
dotnet-version: '10.0.x'
63+
dotnet-version: '9.0.x'
5864
- name: Publish Artemis
5965
run: dotnet publish --configuration Release -p:Version=${{ needs.version.outputs.version-number }} --runtime ${{ matrix.rid }} --output build/${{ matrix.rid }} --self-contained Artemis/src/Artemis.UI.${{ matrix.csproj }}/Artemis.UI.${{ matrix.csproj }}.csproj
66+
- name: Publish Plugins
67+
run: |
68+
New-Item -ItemType "Directory" -Path build/${{ matrix.rid }}/Plugins/
69+
Get-ChildItem -File -Recurse -Filter *.csproj Artemis.Plugins/src/ |
70+
Foreach-Object -Parallel {
71+
dotnet publish --configuration Release --runtime ${{ matrix.rid }} --output build-plugins/$($_.BaseName) --no-self-contained $($_.FullName);
72+
Compress-Archive -Path "build-plugins/$($_.BaseName)" -DestinationPath "build/${{ matrix.rid }}/Plugins/$($_.BaseName).zip";
73+
}
74+
shell: pwsh
6075
- name: Upload Artifact
6176
uses: actions/upload-artifact@v4
6277
with:

.github/workflows/nuget.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,9 @@ jobs:
2222
run: |
2323
$MidnightUtc = [DateTime]::UtcNow.Date
2424
$BranchName = "${{ github.ref_name }}".replace('/','-').replace('.','-')
25+
$ApiVersion = (Select-Xml -Path 'src/Artemis.Core/Artemis.Core.csproj' -XPath '//PluginApiVersion').Node.InnerText
2526
$NumberOfCommitsToday = (git log --after=$($MidnightUtc.ToString("o")) --oneline | Measure-Object -Line).Lines
26-
$VersionNumber = "1.$($MidnightUtc.ToString("yyyy.MMdd")).$NumberOfCommitsToday"
27+
$VersionNumber = "$ApiVersion.$($MidnightUtc.ToString("yyyy.MMdd")).$NumberOfCommitsToday"
2728
# If we're not in master, add the branch name to the version so it counts as prerelease
2829
if ($BranchName -ne "master") { $VersionNumber += "-$BranchName" }
2930
"version-number=$VersionNumber" >> $Env:GITHUB_OUTPUT
@@ -36,7 +37,7 @@ jobs:
3637
- name: Setup .NET
3738
uses: actions/setup-dotnet@v4
3839
with:
39-
dotnet-version: '10.0.x'
40+
dotnet-version: '9.0.x'
4041
- name: Checkout
4142
uses: actions/checkout@v4
4243
- name: Pack Artemis.Core

ci/azure-pipelines-docfx.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# .NET Desktop
2+
# Build and run tests for .NET Desktop or Windows classic desktop solutions.
3+
# Add steps that publish symbols, save build artifacts, and more:
4+
# https://docs.microsoft.com/azure/devops/pipelines/apps/windows/dot-net
5+
6+
trigger:
7+
- master
8+
pr: none
9+
10+
pool:
11+
vmImage: 'windows-latest'
12+
13+
variables:
14+
artemisSolution: '**/Artemis.sln'
15+
rgbSolution: '**/RGB.NET.sln'
16+
pluginProjects: '**/Artemis.Plugins.*.csproj'
17+
BuildId: $(Build.BuildId)
18+
BuildNumber: $(Build.BuildNumber)
19+
SourceBranch: $(Build.SourceBranch)
20+
SourceVersion: $(Build.SourceVersion)
21+
22+
steps:
23+
- checkout: self
24+
path: s/Artemis
25+
26+
- task: DotNetCoreCLI@2
27+
displayName: 'dotnet build Artemis'
28+
inputs:
29+
command: 'build'
30+
projects: '$(artemisSolution)'
31+
feedsToUse: 'config'
32+
nugetConfigPath: '$(Pipeline.Workspace)/s/Artemis/src/NuGet.Config'
33+
34+
- task: PowerShell@2
35+
displayName: "DockFX build"
36+
inputs:
37+
targetType: 'inline'
38+
script: |
39+
choco install docfx -y
40+
docfx.exe .\docfx_project\docfx.json
41+
workingDirectory: '$(Pipeline.Workspace)/s/Artemis/docfx'
42+
43+
- task: FtpUpload@2
44+
displayName: "DockFX FTP upload"
45+
inputs:
46+
credentialsOption: 'inputs'
47+
serverUrl: 'ftp://www360.your-server.de'
48+
username: '$(ftp_user)'
49+
password: '$(ftp_password)'
50+
rootDirectory: '$(Pipeline.Workspace)/s/Artemis/docfx/docfx_project/_site'
51+
filePatterns: '**'
52+
remoteDirectory: '/docs'
53+
clean: true
54+
preservePaths: true
55+
trustSSL: false

ci/azure-pipelines.yml

Lines changed: 216 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,216 @@
1+
# .NET Desktop
2+
# Build and run tests for .NET Desktop or Windows classic desktop solutions.
3+
# Add steps that publish symbols, save build artifacts, and more:
4+
# https://docs.microsoft.com/azure/devops/pipelines/apps/windows/dot-net
5+
6+
trigger:
7+
- master
8+
pr: none
9+
10+
resources:
11+
repositories:
12+
- repository: Plugins
13+
type: github
14+
endpoint: github.com_SpoinkyNL
15+
name: Artemis-RGB/Artemis.Plugins
16+
ref: master
17+
18+
variables:
19+
windowsProject: "**/Artemis.UI.Windows/Artemis.UI.Windows.csproj"
20+
linuxProject: "**/Artemis.UI.Linux/Artemis.UI.Linux.csproj"
21+
pluginProjects: "**/Artemis.Plugins.*.csproj"
22+
BuildId: $(Build.BuildId)
23+
BuildNumber: $(Build.BuildNumber)
24+
SourceBranch: $(Build.SourceBranch)
25+
SourceVersion: $(Build.SourceVersion)
26+
27+
jobs:
28+
- job: Windows
29+
pool:
30+
vmImage: "windows-latest"
31+
steps:
32+
- checkout: self
33+
path: s/Artemis
34+
- checkout: Plugins
35+
path: s/Artemis.Plugins
36+
37+
- task: DotNetCoreCLI@2
38+
displayName: "Artemis - Publish"
39+
inputs:
40+
command: "publish"
41+
publishWebProjects: false
42+
projects: "$(windowsProject)"
43+
arguments: '--configuration Release --runtime win10-x64 --output $(Build.ArtifactStagingDirectory)/windows-build /nowarn:cs1591'
44+
zipAfterPublish: false
45+
modifyOutputPath: false
46+
47+
- task: PowerShell@2
48+
displayName: "Artemis - Create buildinfo.json"
49+
inputs:
50+
targetType: "inline"
51+
script: |
52+
$OFS = "`r`n"
53+
SET-Content -Path 'buildinfo.json' -Value ('{' + $OFS + ' "BuildId": 0,' + $OFS + ' "BuildNumber": 0.0,' + $OFS + ' "SourceBranch": "",' + $OFS + ' "SourceVersion": ""' + $OFS + '}')
54+
workingDirectory: "$(Build.ArtifactStagingDirectory)/windows-build"
55+
56+
- task: FileTransform@1
57+
displayName: "Artemis - Populate buildinfo.json"
58+
inputs:
59+
folderPath: "$(Build.ArtifactStagingDirectory)/windows-build"
60+
fileType: "json"
61+
targetFiles: "**/buildinfo.json"
62+
63+
- task: PowerShell@2
64+
displayName: "Plugins - Insert build number into plugin.json"
65+
inputs:
66+
targetType: "inline"
67+
script: |
68+
Get-ChildItem -Recurse -Filter plugin.json |
69+
Foreach-Object {
70+
$buidNumber = "1.0.1." + $Env:BUILD_BUILDID;
71+
$a = Get-Content $_.FullName | ConvertFrom-Json
72+
$a.Version = $buidNumber;
73+
$a | ConvertTo-Json | Set-Content $_.FullName
74+
}
75+
workingDirectory: "Artemis.Plugins"
76+
77+
- task: DotNetCoreCLI@2
78+
displayName: "Plugins - Publish"
79+
inputs:
80+
command: "publish"
81+
publishWebProjects: false
82+
arguments: "--configuration Release --runtime win10-x64 --output $(Build.ArtifactStagingDirectory)/windows-build/Plugins"
83+
projects: "$(pluginProjects)"
84+
zipAfterPublish: true
85+
86+
- task: PublishPipelineArtifact@1
87+
displayName: "Upload build to Azure Pipelines"
88+
inputs:
89+
targetPath: "$(Build.ArtifactStagingDirectory)/windows-build"
90+
artifact: "Artemis build - Windows"
91+
publishLocation: "pipeline"
92+
93+
- task: ArchiveFiles@2
94+
displayName: "ZIP binaries"
95+
inputs:
96+
rootFolderOrFile: "$(Build.ArtifactStagingDirectory)/windows-build"
97+
includeRootFolder: false
98+
archiveType: "zip"
99+
archiveFile: "$(Build.ArtifactStagingDirectory)/archive/artemis-build-windows.zip"
100+
replaceExistingArchive: true
101+
102+
- task: PowerShell@2
103+
displayName: "Calculate ZIP hash"
104+
inputs:
105+
targetType: "inline"
106+
script: '(Get-FileHash .\artemis-build-windows.zip).Hash | Out-File -FilePath .\hash-windows.txt'
107+
workingDirectory: "$(Build.ArtifactStagingDirectory)/archive"
108+
109+
- task: FtpUpload@2
110+
displayName: "Upload binaries to FTP"
111+
inputs:
112+
credentialsOption: "inputs"
113+
serverUrl: "ftp://artemis-rgb.com"
114+
username: "devops"
115+
password: "$(ftp_password)"
116+
rootDirectory: "$(Build.ArtifactStagingDirectory)/archive"
117+
filePatterns: "**"
118+
remoteDirectory: "/builds.artemis-rgb.com/binaries/$(Build.SourceBranchName)/$(Build.BuildNumber)"
119+
clean: false
120+
preservePaths: true
121+
trustSSL: false
122+
123+
- job: Linux
124+
pool:
125+
vmImage: "ubuntu-latest"
126+
steps:
127+
- checkout: self
128+
path: s/Artemis
129+
- checkout: Plugins
130+
path: s/Artemis.Plugins
131+
132+
- task: DotNetCoreCLI@2
133+
displayName: "Artemis - Publish"
134+
inputs:
135+
command: "publish"
136+
publishWebProjects: false
137+
projects: "$(linuxProject)"
138+
arguments: '--configuration Release --runtime linux-x64 --output $(Build.ArtifactStagingDirectory)/linux-build /nowarn:cs1591'
139+
zipAfterPublish: false
140+
modifyOutputPath: false
141+
142+
- task: PowerShell@2
143+
displayName: "Artemis - Create buildinfo.json"
144+
inputs:
145+
targetType: "inline"
146+
script: |
147+
$OFS = "`r`n"
148+
SET-Content -Path 'buildinfo.json' -Value ('{' + $OFS + ' "BuildId": 0,' + $OFS + ' "BuildNumber": 0.0,' + $OFS + ' "SourceBranch": "",' + $OFS + ' "SourceVersion": ""' + $OFS + '}')
149+
workingDirectory: "$(Build.ArtifactStagingDirectory)/linux-build"
150+
151+
- task: FileTransform@1
152+
displayName: "Artemis - Populate buildinfo.json"
153+
inputs:
154+
folderPath: "$(Build.ArtifactStagingDirectory)/linux-build"
155+
fileType: "json"
156+
targetFiles: "**/buildinfo.json"
157+
158+
- task: PowerShell@2
159+
displayName: "Plugins - Insert build number into plugin.json"
160+
inputs:
161+
targetType: "inline"
162+
script: |
163+
Get-ChildItem -Recurse -Filter plugin.json |
164+
Foreach-Object {
165+
$buidNumber = "1.0.1." + $Env:BUILD_BUILDID;
166+
$a = Get-Content $_.FullName | ConvertFrom-Json
167+
$a.Version = $buidNumber;
168+
$a | ConvertTo-Json | Set-Content $_.FullName
169+
}
170+
workingDirectory: "Artemis.Plugins"
171+
172+
- task: DotNetCoreCLI@2
173+
displayName: "Plugins - Publish"
174+
inputs:
175+
command: "publish"
176+
publishWebProjects: false
177+
arguments: "--configuration Release --runtime linux-x64 --output $(Build.ArtifactStagingDirectory)/linux-build/Plugins"
178+
projects: "$(pluginProjects)"
179+
zipAfterPublish: true
180+
181+
- task: PublishPipelineArtifact@1
182+
displayName: "Upload build to Azure Pipelines"
183+
inputs:
184+
targetPath: "$(Build.ArtifactStagingDirectory)/linux-build"
185+
artifact: "Artemis build - Linux"
186+
publishLocation: "pipeline"
187+
188+
- task: ArchiveFiles@2
189+
displayName: "ZIP binaries"
190+
inputs:
191+
rootFolderOrFile: "$(Build.ArtifactStagingDirectory)/linux-build"
192+
includeRootFolder: false
193+
archiveType: "zip"
194+
archiveFile: "$(Build.ArtifactStagingDirectory)/archive/artemis-build-linux.zip"
195+
replaceExistingArchive: true
196+
197+
- task: PowerShell@2
198+
displayName: "Calculate ZIP hash"
199+
inputs:
200+
targetType: "inline"
201+
script: '(Get-FileHash .\artemis-build-linux.zip).Hash | Out-File -FilePath .\hash-linux.txt'
202+
workingDirectory: "$(Build.ArtifactStagingDirectory)/archive"
203+
204+
- task: FtpUpload@2
205+
displayName: "Upload binaries to FTP"
206+
inputs:
207+
credentialsOption: "inputs"
208+
serverUrl: "ftp://artemis-rgb.com"
209+
username: "devops"
210+
password: "$(ftp_password)"
211+
rootDirectory: "$(Build.ArtifactStagingDirectory)/archive"
212+
filePatterns: "**"
213+
remoteDirectory: "/builds.artemis-rgb.com/binaries/$(Build.SourceBranchName)/$(Build.BuildNumber)"
214+
clean: false
215+
preservePaths: true
216+
trustSSL: false

0 commit comments

Comments
 (0)