Skip to content

Commit e0c7478

Browse files
authored
Merge pull request #214 from pre-martin/feature/bundle-for-stream-dock
Bundle for Stream Dock
2 parents a140d0f + 818c70e commit e0c7478

4 files changed

Lines changed: 148 additions & 4 deletions

File tree

StreamDeckSimHub.Plugin/Bundle.ps1

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,19 @@ try {
1818
Pushd ..\build
1919
Rename-Item -Path "publish" -NewName "net.planetrenner.simhub.sdPlugin" -ErrorAction Stop
2020

21+
# Prepare for Stream Deck with Stream Deck CLI
22+
Copy-Item "net.planetrenner.simhub.sdPlugin\manifest-streamdeck.json" -Destination "net.planetrenner.simhub.sdPlugin\manifest.json"
23+
2124
streamdeck bundle net.planetrenner.simhub.sdPlugin
22-
#streamdeck bundle --ignore-validation net.planetrenner.simhub.sdPlugin
2325
if ($? -eq $False) {
24-
Write-Host "`nBundling with streamdeck cli failed`n"
26+
Write-Host "`nBundling with Stream Deck CLI failed`n"
2527
Exit 1
2628
}
2729

30+
# Prepare for Stream Dock
31+
Copy-Item "net.planetrenner.simhub.sdPlugin\manifest-streamdock.json" -Destination "net.planetrenner.simhub.sdPlugin\manifest.json"
32+
Compress-Archive -Path "net.planetrenner.simhub.sdPlugin\*" -DestinationPath "net.planetrenner.simhub-streamdock.zip" -Force
33+
2834
Popd
2935
}
3036
catch {

StreamDeckSimHub.Plugin/StreamDeckSimHub.Plugin.csproj

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@
5050

5151
<Target Name="SetManifestVersionAndBundle" AfterTargets="Publish">
5252
<!-- Replace version in manifest.json with the version from nbgv -->
53-
<Exec Command="pwsh -ExecutionPolicy Bypass -File .\ReplaceVersion.ps1 $(PublishDir)manifest.json $(AssemblyFileVersion)" />
53+
<Exec Command="pwsh -ExecutionPolicy Bypass -File .\ReplaceVersion.ps1 $(PublishDir)manifest-streamdeck.json $(AssemblyFileVersion)" />
54+
<Exec Command="pwsh -ExecutionPolicy Bypass -File .\ReplaceVersion.ps1 $(PublishDir)manifest-streamdock.json $(AssemblyFileVersion)" />
5455
<!-- Bundle as Stream Deck plugin -->
5556
<Exec Command="pwsh -ExecutionPolicy Bypass -File .\Bundle.ps1 $(PublishDir)" />
5657
</Target>
@@ -59,7 +60,10 @@
5960
<None Update="appsettings.json">
6061
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
6162
</None>
62-
<None Update="manifest.json">
63+
<None Update="manifest-streamdeck.json">
64+
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
65+
</None>
66+
<None Update="manifest-streamdock.json">
6367
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
6468
</None>
6569
<None Update="pi\js\common.js">
File renamed without changes.
Lines changed: 134 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,134 @@
1+
{
2+
"$schema": "https://schemas.elgato.com/streamdeck/plugins/manifest.json",
3+
"Actions": [
4+
{
5+
"Icon": "images/actions/hotkey",
6+
"Name": "Hotkey",
7+
"PropertyInspectorPath": "pi/hotkey.html",
8+
"States": [
9+
{
10+
"Image": "images/icons/off",
11+
"Name": "off"
12+
},
13+
{
14+
"Image": "images/icons/on",
15+
"Name": "on"
16+
}
17+
],
18+
"Tooltip": "Hotkey with SimHub state",
19+
"UUID": "net.planetrenner.simhub.hotkey"
20+
},
21+
{
22+
"Icon": "images/actions/flag",
23+
"Name": "Flags",
24+
"PropertyInspectorPath": "pi/flags.html",
25+
"States": [
26+
{
27+
"Image": "images/icons/flag-checkered",
28+
"Name": "on"
29+
}
30+
],
31+
"Tooltip": "Flags",
32+
"SupportedInMultiActions": false,
33+
"UUID": "net.planetrenner.simhub.flags"
34+
},
35+
{
36+
"Icon": "images/actions/generic-button",
37+
"Name": "Generic Button",
38+
"PropertyInspectorPath": "pi/genericButton.html",
39+
"States": [
40+
{
41+
"Image": "images/icons/generic-button"
42+
}
43+
],
44+
"Controllers": [
45+
"Encoder",
46+
"Keypad",
47+
"Information"
48+
],
49+
"Encoder": {
50+
"layout": "layout/dial-fullscreen.json"
51+
},
52+
"Tooltip": "Generic Button",
53+
"SupportedInMultiActions": false,
54+
"UUID": "net.planetrenner.simhub.generic-button"
55+
},
56+
{
57+
"Icon": "images/actions/hotkey4",
58+
"Name": "Hotkey 4-state",
59+
"PropertyInspectorPath": "pi/hotkey4.html",
60+
"States": [
61+
{
62+
"Image": "images/icons/0",
63+
"Name": "0"
64+
},
65+
{
66+
"Image": "images/icons/1",
67+
"Name": "1"
68+
},
69+
{
70+
"Image": "images/icons/2",
71+
"Name": "2"
72+
},
73+
{
74+
"Image": "images/icons/3",
75+
"Name": "3"
76+
}
77+
],
78+
"Tooltip": "Hotkey with SimHub state (4 states)",
79+
"UUID": "net.planetrenner.simhub.hotkey4"
80+
},
81+
{
82+
"Icon": "images/actions/input",
83+
"Name": "Input Trigger",
84+
"PropertyInspectorPath": "pi/input.html",
85+
"States": [
86+
{
87+
"Image": "images/icons/input",
88+
"Name": "Input"
89+
}
90+
],
91+
"Tooltip": "Input control for SimHub",
92+
"UUID": "net.planetrenner.simhub.input"
93+
},
94+
{
95+
"Controllers": [
96+
"Encoder"
97+
],
98+
"Encoder": {
99+
"layout": "layout/dial-layout.json"
100+
},
101+
"Icon": "images/actions/dial",
102+
"Name": "Dial",
103+
"PropertyInspectorPath": "pi/dial.html",
104+
"States": [
105+
{
106+
"Image": "images/icons/dial",
107+
"Name": "Dial"
108+
}
109+
],
110+
"Tooltip": "Dial with SimHub state",
111+
"UUID": "net.planetrenner.simhub.dial"
112+
}
113+
],
114+
"Author": "Martin Renner",
115+
"Category": "Stream Deck SimHub",
116+
"CategoryIcon": "images/category/simhub",
117+
"CodePath": "StreamDeckSimHub.exe",
118+
"Description": "Keep you StreamDeck buttons in sync with SimHub (and your simulation)<p>NOTE: SimHub Property Server has to be installed! See https://github.com/pre-martin/SimHubPropertyServer",
119+
"Icon": "images/store/plugin",
120+
"Name": "Stream Deck SimHub",
121+
"Version": "will be replaced",
122+
"UUID": "net.planetrenner.simhub",
123+
"URL": "https://github.com/pre-martin/StreamDeckSimHubPlugin",
124+
"SDKVersion": 2,
125+
"OS": [
126+
{
127+
"Platform": "windows",
128+
"MinimumVersion": "10"
129+
}
130+
],
131+
"Software": {
132+
"MinimumVersion": "6.5"
133+
}
134+
}

0 commit comments

Comments
 (0)