From 1ccc2c891ec1743535039deea9bf534474395f84 Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Sun, 21 Jun 2020 00:16:13 -0600 Subject: [PATCH 01/14] Changing Essentialls over to using nuget --- .github/workflows/docker.yml | 18 +++++++++++------- .gitignore | 2 ++ .../PepperDashEssentials.csproj | 4 ++-- PepperDashEssentials/packages.config | 3 +++ .../PepperDash_Essentials_Core.csproj | 4 ++-- .../PepperDashEssentialsBase/packages.config | 3 +++ .../PepperDash_Essentials_DM.csproj | 4 ++-- .../Essentials_DM/packages.config | 3 +++ .../Essentials Devices Common.csproj | 4 ++-- .../Essentials Devices Common/packages.config | 3 +++ .../PepperDashEssentials/packages.config | 3 +++ 11 files changed, 36 insertions(+), 15 deletions(-) create mode 100644 PepperDashEssentials/packages.config create mode 100644 essentials-framework/Essentials Core/PepperDashEssentialsBase/packages.config create mode 100644 essentials-framework/Essentials DM/Essentials_DM/packages.config create mode 100644 essentials-framework/Essentials Devices Common/Essentials Devices Common/packages.config create mode 100644 essentials-framework/Essentials/PepperDashEssentials/packages.config diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 3eb3e42e..dedfa51e 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -30,13 +30,17 @@ jobs: with: fetch-depth: 0 # And any submodules - - name: Checkout submodules - shell: bash - run: | - git config --global url."https://github.com/".insteadOf "git@github.com:" - auth_header="$(git config --local --get http.https://github.com/.extraheader)" - git submodule sync --recursive - git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1 + #- name: Checkout submodules + # shell: bash + # run: | + # git config --global url."https://github.com/".insteadOf "git@github.com:" + # auth_header="$(git config --local --get http.https://github.com/.extraheader)" + # git submodule sync --recursive + # git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1 + - name: Add nuget.exe + uses: nuget/setup-nuget@v1 + - name: restore Nuget Packages + run: nuget restore .\PepperDashEssentials.sln -MSBuildVersion 4 # Fetch all tags - name: Fetch tags run: git fetch --tags diff --git a/.gitignore b/.gitignore index 5ba628b2..47084fd0 100644 --- a/.gitignore +++ b/.gitignore @@ -23,5 +23,7 @@ SIMPLSharpLogs/ *.projectinfo essentials-framework/EssentialDMTestConfig/ output/ +packages/ + PepperDashEssentials-0.0.0-buildType-test.zip diff --git a/PepperDashEssentials/PepperDashEssentials.csproj b/PepperDashEssentials/PepperDashEssentials.csproj index 6c606273..7a0ac68d 100644 --- a/PepperDashEssentials/PepperDashEssentials.csproj +++ b/PepperDashEssentials/PepperDashEssentials.csproj @@ -71,9 +71,9 @@ ..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll - + False - ..\essentials-framework\pepperdashcore-builds\PepperDash_Core.dll + ..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll False diff --git a/PepperDashEssentials/packages.config b/PepperDashEssentials/packages.config new file mode 100644 index 00000000..f1f7bd89 --- /dev/null +++ b/PepperDashEssentials/packages.config @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj index 55a157b4..c43222d9 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj @@ -83,9 +83,9 @@ ..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll - + False - ..\..\pepperdashcore-builds\PepperDash_Core.dll + ..\..\..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll False diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/packages.config b/essentials-framework/Essentials Core/PepperDashEssentialsBase/packages.config new file mode 100644 index 00000000..f1f7bd89 --- /dev/null +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/packages.config @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj b/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj index 76aae649..76e510aa 100644 --- a/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj +++ b/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj @@ -59,9 +59,9 @@ ..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll - + False - ..\..\pepperdashcore-builds\PepperDash_Core.dll + ..\..\..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll False diff --git a/essentials-framework/Essentials DM/Essentials_DM/packages.config b/essentials-framework/Essentials DM/Essentials_DM/packages.config new file mode 100644 index 00000000..f1f7bd89 --- /dev/null +++ b/essentials-framework/Essentials DM/Essentials_DM/packages.config @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj index ba12a129..b21872a1 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj @@ -63,9 +63,9 @@ ..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.Lighting.dll - + False - ..\..\pepperdashcore-builds\PepperDash_Core.dll + ..\..\..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll False diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/packages.config b/essentials-framework/Essentials Devices Common/Essentials Devices Common/packages.config new file mode 100644 index 00000000..f1f7bd89 --- /dev/null +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/packages.config @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/essentials-framework/Essentials/PepperDashEssentials/packages.config b/essentials-framework/Essentials/PepperDashEssentials/packages.config new file mode 100644 index 00000000..f1f7bd89 --- /dev/null +++ b/essentials-framework/Essentials/PepperDashEssentials/packages.config @@ -0,0 +1,3 @@ + + + \ No newline at end of file From df228fca6d34b3f0e43586254c1c543ae0fa9ede Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Sun, 21 Jun 2020 00:18:14 -0600 Subject: [PATCH 02/14] Add step to add github packages source --- .github/workflows/docker.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index dedfa51e..33bb8e22 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -39,6 +39,8 @@ jobs: # git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1 - name: Add nuget.exe uses: nuget/setup-nuget@v1 + - name: Add Github Packages source + run: nuget sources add -name github -source https://nuget.pkg.github.com/pepperdash/index.json -username Pepperdash -password ${{ secrets.GITHUB_TOKEN }} - name: restore Nuget Packages run: nuget restore .\PepperDashEssentials.sln -MSBuildVersion 4 # Fetch all tags From 7f8d4d94d036adb37ab8056ddaa9115630d818de Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Sun, 21 Jun 2020 13:57:47 -0600 Subject: [PATCH 03/14] update path to library --- PepperDashEssentials/PepperDashEssentials.csproj | 2 +- .../PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj | 2 +- .../Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj | 2 +- .../Essentials Devices Common/Essentials Devices Common.csproj | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/PepperDashEssentials/PepperDashEssentials.csproj b/PepperDashEssentials/PepperDashEssentials.csproj index 7a0ac68d..878b76b1 100644 --- a/PepperDashEssentials/PepperDashEssentials.csproj +++ b/PepperDashEssentials/PepperDashEssentials.csproj @@ -73,7 +73,7 @@ False - ..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll + ..\packages\PepperDashCore.1.0.38-alpha-135\lib\net35\PepperDash_Core.dll False diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj index c43222d9..006bd7bb 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj @@ -85,7 +85,7 @@ False - ..\..\..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll + ..\..\..\packages\PepperDashCore.1.0.38-alpha-135\lib\net35\PepperDash_Core.dll False diff --git a/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj b/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj index 76e510aa..0372274a 100644 --- a/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj +++ b/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj @@ -61,7 +61,7 @@ False - ..\..\..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll + ..\..\..\packages\PepperDashCore.1.0.38-alpha-135\lib\net35\PepperDash_Core.dll False diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj index b21872a1..cb593fcd 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj @@ -65,7 +65,7 @@ False - ..\..\..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll + ..\..\..\packages\PepperDashCore.1.0.38-alpha-135\lib\net35\PepperDash_Core.dll False From 9a9387b151c666f3c1645d374a56e4c6254ad060 Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Mon, 22 Jun 2020 08:54:00 -0600 Subject: [PATCH 04/14] add .nuspec for package creation & Update workflows --- .github/scripts/ZipBuildOutput.ps1 | 2 +- .github/workflows/.vscode/settings.json | 7 ++++ .github/workflows/docker.yml | 39 +++++++++++++++++++ .../PepperDash_Essentials_Core.nuspec | 21 ++++++++++ 4 files changed, 68 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/.vscode/settings.json create mode 100644 essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec diff --git a/.github/scripts/ZipBuildOutput.ps1 b/.github/scripts/ZipBuildOutput.ps1 index 5ca867ef..bf3c9d94 100644 --- a/.github/scripts/ZipBuildOutput.ps1 +++ b/.github/scripts/ZipBuildOutput.ps1 @@ -10,7 +10,7 @@ Get-ChildItem ($destination) $exclusions = @(git submodule foreach --quiet 'echo $name') # Trying to get any .json schema files (not currently working) # Gets any files with the listed extensions. -Get-ChildItem -recurse -Path "$($Env:GITHUB_WORKSPACE)" -include "*.clz", "*.cpz", "*.cplz", "*.dll" | ForEach-Object { +Get-ChildItem -recurse -Path "$($Env:GITHUB_WORKSPACE)" -include "*.clz", "*.cpz", "*.cplz", "*.dll", "*.nuspec" | ForEach-Object { $allowed = $true; # Exclude any files in submodules foreach ($exclude in $exclusions) { diff --git a/.github/workflows/.vscode/settings.json b/.github/workflows/.vscode/settings.json new file mode 100644 index 00000000..2c6fe730 --- /dev/null +++ b/.github/workflows/.vscode/settings.json @@ -0,0 +1,7 @@ +{ + "workbench.colorCustomizations": { + "activityBar.background": "#332848", + "titleBar.activeBackground": "#483764", + "titleBar.activeForeground": "#FBFBFD" + } +} \ No newline at end of file diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 33bb8e22..acc38178 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -117,6 +117,45 @@ jobs: asset_content_type: application/zip env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + Push_Nuget_Package: + needs: Build_Project + runs-on: windows-latest + steps: + - name: Download Build Version Info + uses: actions/download-artifact@v1 + with: + name: Version + - name: Set Version Number + shell: powershell + run: | + Get-ChildItem "./Version" + $version = Get-Content -Path ./Version/version.txt + Write-Host "Version: $version" + Write-Output "::set-env name=VERSION::$version" + Remove-Item -Path ./Version/version.txt + Remove-Item -Path ./Version + - name: Download Build output + uses: actions/download-artifact@v1 + with: + name: Build + path: ./ + - name: Unzip Build file + run: | + Get-ChildItem .\*.zip | Expand-Archive -DestinationPath .\ + Remove-Item -Path .\*.zip + - name: Copy Files to root & delete output directory + run: | + Remove-Item -Path .\* -Include @("*.cpz","*.md","*.cplz","*.json","*.dll","*.clz") + Get-ChildItem -Path .\output\* | Copy-Item -Destination .\ + Remove-Item -Path .\output -Recurse + - name: Add nuget.exe + uses: nuget/setup-nuget@v1 + - name: Add Github Packages source + run: nuget sources add -name github -source https://nuget.pkg.github.com/pepperdash/index.json -username Pepperdash -password ${{ secrets.GITHUB_TOKEN }} + - name: Create nuget package + run: nuget pack "./PepperDash_Essentials_Core.nuspec" -version ${{ env.VERSION }} + - name: Publish nuget package to Github registry + run: nuget push **/*.nupkg -source github # This step always runs and pushes the build to the internal build rep Internal_Push_Output: needs: Build_Project diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec new file mode 100644 index 00000000..c02debbc --- /dev/null +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec @@ -0,0 +1,21 @@ + + + + PepperDashEssentials + 1.5.6 + PepperDash Essentials + PepperDash Technologies + pepperdash + false + MIT + https://github.com/PepperDash/PepperDashCore + Copyright 2020 + PepperDash Essentials is an open source Crestron framework that can be configured as a standalone program capable of running a wide variety of system designs and can also be utilized as a plug-in architecture to augment other Simpl# Pro and Simpl Windows programs. Essentials Framework is a collection of C# / Simpl# Pro libraries that can be utilized in several different manners. It is currently operating as a 100% configuration-driven system, and can be extended to add different workflows and behaviors, either through the addition of further device "types" or via the plug-in mechanism. The framework is a collection of "things" that are all related and interconnected, but in general do not have dependencies on each other. + crestron 3series 4series + + + + + + + \ No newline at end of file From 17368a0a12ba5cab46d2ff543371454842f8d26c Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Mon, 22 Jun 2020 08:54:54 -0600 Subject: [PATCH 05/14] update master for nuget package creation --- .github/workflows/master.yml | 39 ++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/.github/workflows/master.yml b/.github/workflows/master.yml index 7bbbd646..3bd74dee 100644 --- a/.github/workflows/master.yml +++ b/.github/workflows/master.yml @@ -85,6 +85,45 @@ jobs: asset_content_type: application/zip env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + Push_Nuget_Package: + needs: Build_Project + runs-on: windows-latest + steps: + - name: Download Build Version Info + uses: actions/download-artifact@v1 + with: + name: Version + - name: Set Version Number + shell: powershell + run: | + Get-ChildItem "./Version" + $version = Get-Content -Path ./Version/version.txt + Write-Host "Version: $version" + Write-Output "::set-env name=VERSION::$version" + Remove-Item -Path ./Version/version.txt + Remove-Item -Path ./Version + - name: Download Build output + uses: actions/download-artifact@v1 + with: + name: Build + path: ./ + - name: Unzip Build file + run: | + Get-ChildItem .\*.zip | Expand-Archive -DestinationPath .\ + Remove-Item -Path .\*.zip + - name: Copy Files to root & delete output directory + run: | + Remove-Item -Path .\* -Include @("*.cpz","*.md","*.cplz","*.json","*.dll","*.clz") + Get-ChildItem -Path .\output\* | Copy-Item -Destination .\ + Remove-Item -Path .\output -Recurse + - name: Add nuget.exe + uses: nuget/setup-nuget@v1 + - name: Add Github Packages source + run: nuget sources add -name github -source https://nuget.pkg.github.com/pepperdash/index.json -username Pepperdash -password ${{ secrets.GITHUB_TOKEN }} + - name: Create nuget package + run: nuget pack "./PepperDash_Essentials_Core.nuspec" -version ${{ env.VERSION }} + - name: Publish nuget package to Github registry + run: nuget push **/*.nupkg -source github Internal_Push_Output: needs: Build_Project runs-on: windows-latest From 827678961cd62d3450a23e77ed276bd146814f9b Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Mon, 22 Jun 2020 08:56:56 -0600 Subject: [PATCH 06/14] update master workflow for nuget consumption --- .github/workflows/master.yml | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/.github/workflows/master.yml b/.github/workflows/master.yml index 3bd74dee..60fa3ce4 100644 --- a/.github/workflows/master.yml +++ b/.github/workflows/master.yml @@ -25,13 +25,19 @@ jobs: - name: Checkout repo uses: actions/checkout@v2 # And any submodules - - name: Checkout submodules - shell: bash - run: | - git config --global url."https://github.com/".insteadOf "git@github.com:" - auth_header="$(git config --local --get http.https://github.com/.extraheader)" - git submodule sync --recursive - git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1 + #- name: Checkout submodules + # shell: bash + # run: | + # git config --global url."https://github.com/".insteadOf "git@github.com:" + # auth_header="$(git config --local --get http.https://github.com/.extraheader)" + # git submodule sync --recursive + # git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1 + - name: Add nuget.exe + uses: nuget/setup-nuget@v1 + - name: Add Github Packages source + run: nuget sources add -name github -source https://nuget.pkg.github.com/pepperdash/index.json -username Pepperdash -password ${{ secrets.GITHUB_TOKEN }} + - name: restore Nuget Packages + run: nuget restore .\PepperDashEssentials.sln -MSBuildVersion 4 # Generate the appropriate version number - name: Set Version Number shell: powershell From 53e3e603b9d6d815e085a06636d99ccc49fcc24b Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Mon, 22 Jun 2020 09:42:09 -0600 Subject: [PATCH 07/14] added dependency on PepperDashCore --- .../PepperDash_Essentials_Core.nuspec | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec index c02debbc..76db24de 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec @@ -14,8 +14,11 @@ crestron 3series 4series - - - - + + + + + + + \ No newline at end of file From a1bb6685d46c60d6fc999501630ad77787eff291 Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Mon, 22 Jun 2020 10:01:44 -0600 Subject: [PATCH 08/14] fix dependencies section --- .../PepperDash_Essentials_Core.nuspec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec index 76db24de..d5bb4a57 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.nuspec @@ -13,12 +13,12 @@ PepperDash Essentials is an open source Crestron framework that can be configured as a standalone program capable of running a wide variety of system designs and can also be utilized as a plug-in architecture to augment other Simpl# Pro and Simpl Windows programs. Essentials Framework is a collection of C# / Simpl# Pro libraries that can be utilized in several different manners. It is currently operating as a 100% configuration-driven system, and can be extended to add different workflows and behaviors, either through the addition of further device "types" or via the plug-in mechanism. The framework is a collection of "things" that are all related and interconnected, but in general do not have dependencies on each other. crestron 3series 4series + + + - - - \ No newline at end of file From 49edaa33acdcb1d363fe7bf94d51868ff5fe6c74 Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Wed, 22 Jul 2020 15:27:57 -0600 Subject: [PATCH 09/14] updates for nuget --- .github/workflows/docker.yml | 2 +- .github/workflows/master.yml | 2 +- .../PepperDashEssentials.csproj | 4 ++-- PepperDashEssentials/packages.config | 3 --- README.md | 21 ++++++++++++------- .../PepperDash_Essentials_Core.csproj | 4 ++-- .../PepperDashEssentialsBase/packages.config | 3 --- .../PepperDash_Essentials_DM.csproj | 4 ++-- .../Essentials_DM/packages.config | 3 --- .../Essentials Devices Common.csproj | 4 ++-- .../Essentials Devices Common/packages.config | 3 --- essentials-framework/pepperdashcore-builds | 2 +- packages.config | 3 +++ 13 files changed, 28 insertions(+), 30 deletions(-) delete mode 100644 PepperDashEssentials/packages.config delete mode 100644 essentials-framework/Essentials Core/PepperDashEssentialsBase/packages.config delete mode 100644 essentials-framework/Essentials DM/Essentials_DM/packages.config delete mode 100644 essentials-framework/Essentials Devices Common/Essentials Devices Common/packages.config create mode 100644 packages.config diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index acc38178..dd77c6f9 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -42,7 +42,7 @@ jobs: - name: Add Github Packages source run: nuget sources add -name github -source https://nuget.pkg.github.com/pepperdash/index.json -username Pepperdash -password ${{ secrets.GITHUB_TOKEN }} - name: restore Nuget Packages - run: nuget restore .\PepperDashEssentials.sln -MSBuildVersion 4 + run: nuget install .\packages.config -OutputDirectory .\packages -ExcludeVersion # Fetch all tags - name: Fetch tags run: git fetch --tags diff --git a/.github/workflows/master.yml b/.github/workflows/master.yml index 60fa3ce4..0b8a49b9 100644 --- a/.github/workflows/master.yml +++ b/.github/workflows/master.yml @@ -37,7 +37,7 @@ jobs: - name: Add Github Packages source run: nuget sources add -name github -source https://nuget.pkg.github.com/pepperdash/index.json -username Pepperdash -password ${{ secrets.GITHUB_TOKEN }} - name: restore Nuget Packages - run: nuget restore .\PepperDashEssentials.sln -MSBuildVersion 4 + run: nuget install .\packages.config -OutputDirectory .\packages -ExcludeVersion # Generate the appropriate version number - name: Set Version Number shell: powershell diff --git a/PepperDashEssentials/PepperDashEssentials.csproj b/PepperDashEssentials/PepperDashEssentials.csproj index 878b76b1..e19aa397 100644 --- a/PepperDashEssentials/PepperDashEssentials.csproj +++ b/PepperDashEssentials/PepperDashEssentials.csproj @@ -71,9 +71,9 @@ ..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll - + False - ..\packages\PepperDashCore.1.0.38-alpha-135\lib\net35\PepperDash_Core.dll + ..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll False diff --git a/PepperDashEssentials/packages.config b/PepperDashEssentials/packages.config deleted file mode 100644 index f1f7bd89..00000000 --- a/PepperDashEssentials/packages.config +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/README.md b/README.md index 310b4b8a..334f6019 100644 --- a/README.md +++ b/README.md @@ -1,24 +1,31 @@ - # PepperDash Essentials Framework (c) 2020 ## License + Provided under MIT license ## Overview + PepperDash Essentials is an open source Crestron framework that can be configured as a standalone program capable of running a wide variety of system designs and can also be utilized as a plug-in architecture to augment other Simpl# Pro and Simpl Windows programs. Essentials Framework is a collection of C# / Simpl# Pro libraries that can be utilized in several different manners. It is currently operating as a 100% configuration-driven system, and can be extended to add different workflows and behaviors, either through the addition of further device "types" or via the plug-in mechanism. The framework is a collection of "things" that are all related and interconnected, but in general do not have dependencies on each other. ## Minimum Requirements + - Essentials Framework runs on any Crestron 3-series processor, **4-series** processor or Crestron's VC-4 platform. - To edit and compile the source, Microsoft Visual Studio 2008 Professional with SP1 is required. - Crestron's Simpl# Plugin is also required (must be obtained from Crestron). ## Dependencies -The [PepperDash.Core](https://github.com/PepperDash/PepperDashCore) SIMPL# library is required. It is referenced as a submodule and will be automatically checked out when cloning this repo if set to recurse submodules. This allows different builds of the PepperDash.Core library to be referenced by checking out the desired submodule commit. +The [PepperDash.Core](https://github.com/PepperDash/PepperDashCore) SIMPL# library is required. It is referenced via nuget. You must have nuget.exe installed and in the `PATH` environment variable to use the following command. Nuget.exe is available at [nuget.org](https://dist.nuget.org/win-x86-commandline/latest/nuget.exe). + +### Installing Dependencies + +To install dependencies once nuget.exe is installed, run the following command: `nuget install .\packages.config -OutputDirectory .\packages -excludeVersion`. To verify that the packages installed correctly, open Essentials and make sure that all references are found, then try and build it. ## Utilization + Essentials was originally conceptualized as a standalone application for running control system logic entirely in Simpl# Pro. It is primarily designed around accomplishing this goal, but during development, it became obvious that it could easily be leveraged to also serve as a partner application to one or more SIMPL Windows programs. Utilization of Essentials Framework falls into the following categories: @@ -32,13 +39,13 @@ Utilization of Essentials Framework falls into the following categories: - Advanced logic. Some logic operations that cannot be affectively accomplished in SIMPL Windows (ex. JSON/XML serialization/deserialization, database operations, etc.) can be done in the Simpl# Pro environment and the necessary input and output bridged to a SIMPL Windows program via EISC. 3. Hybrid Application that may contain elements of both standalone control and SIMPL partner application integration. -- There may be a use case where a device can only be defined in a single application, but that device may need to be interacted with from multiple applications. The device can be defined in an Essentials application, interacted with in that application and also bridged to one or more SIMPL Windows applications. - ## Documentation - For detailed documentation, see the [Wiki](https://github.com/PepperDash/EssentialsFramework/wiki). +- There may be a use case where a device can only be defined in a single application, but that device may need to be interacted with from multiple applications. The device can be defined in an Essentials application, interacted with in that application and also bridged to one or more SIMPL Windows applications. + +## Documentation + +For detailed documentation, see the [Wiki](https://github.com/PepperDash/EssentialsFramework/wiki). ## How-To (Getting Started) See [Getting Started](https://github.com/PepperDash/Essentials/wiki/Get-started#how-to-get-started) - - diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj index 006bd7bb..47bc402c 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj @@ -83,9 +83,9 @@ ..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll - + False - ..\..\..\packages\PepperDashCore.1.0.38-alpha-135\lib\net35\PepperDash_Core.dll + ..\..\..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll False diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/packages.config b/essentials-framework/Essentials Core/PepperDashEssentialsBase/packages.config deleted file mode 100644 index f1f7bd89..00000000 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/packages.config +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj b/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj index 0372274a..81426594 100644 --- a/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj +++ b/essentials-framework/Essentials DM/Essentials_DM/PepperDash_Essentials_DM.csproj @@ -59,9 +59,9 @@ ..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.UI.dll - + False - ..\..\..\packages\PepperDashCore.1.0.38-alpha-135\lib\net35\PepperDash_Core.dll + ..\..\..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll False diff --git a/essentials-framework/Essentials DM/Essentials_DM/packages.config b/essentials-framework/Essentials DM/Essentials_DM/packages.config deleted file mode 100644 index f1f7bd89..00000000 --- a/essentials-framework/Essentials DM/Essentials_DM/packages.config +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj index cb593fcd..62f3a571 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Essentials Devices Common.csproj @@ -63,9 +63,9 @@ ..\..\..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SSPDevices\Crestron.SimplSharpPro.Lighting.dll - + False - ..\..\..\packages\PepperDashCore.1.0.38-alpha-135\lib\net35\PepperDash_Core.dll + ..\..\..\packages\PepperDashCore\lib\net35\PepperDash_Core.dll False diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/packages.config b/essentials-framework/Essentials Devices Common/Essentials Devices Common/packages.config deleted file mode 100644 index f1f7bd89..00000000 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/packages.config +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/essentials-framework/pepperdashcore-builds b/essentials-framework/pepperdashcore-builds index 18cb0c27..b64665a6 160000 --- a/essentials-framework/pepperdashcore-builds +++ b/essentials-framework/pepperdashcore-builds @@ -1 +1 @@ -Subproject commit 18cb0c273eb8b750f657d74160ad82eff1b24bca +Subproject commit b64665a60ebfa8cd4dc680acccb3ef0d94cbbf82 diff --git a/packages.config b/packages.config new file mode 100644 index 00000000..42d552c6 --- /dev/null +++ b/packages.config @@ -0,0 +1,3 @@ + + + \ No newline at end of file From 80073c22b1d4f9abb69c5ffa9c87da171d636775 Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Wed, 22 Jul 2020 15:50:40 -0600 Subject: [PATCH 10/14] add information about adding different version --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index 334f6019..65ee000e 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,10 @@ The [PepperDash.Core](https://github.com/PepperDash/PepperDashCore) SIMPL# libra To install dependencies once nuget.exe is installed, run the following command: `nuget install .\packages.config -OutputDirectory .\packages -excludeVersion`. To verify that the packages installed correctly, open Essentials and make sure that all references are found, then try and build it. +### Installing Different versions of PepperDash Core + +If you need a different version of PepperDash Core, use the command `nuget install .\packages.config -OutputDirectory .\packages -excludeVersion -Version {versionToGet}`. Omitting the `-Version` option will pull the latest release version of PepperDash Core. + ## Utilization Essentials was originally conceptualized as a standalone application for running control system logic entirely in Simpl# Pro. It is primarily designed around accomplishing this goal, but during development, it became obvious that it could easily be leveraged to also serve as a partner application to one or more SIMPL Windows programs. From 03cf6ffd60c37f2650c2ad48cc3a7b523e844e6c Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Wed, 22 Jul 2020 16:31:50 -0600 Subject: [PATCH 11/14] change to allow console messages to print when debugging --- PepperDashEssentials/ControlSystem.cs | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/PepperDashEssentials/ControlSystem.cs b/PepperDashEssentials/ControlSystem.cs index 57cd454e..cd9a99cb 100644 --- a/PepperDashEssentials/ControlSystem.cs +++ b/PepperDashEssentials/ControlSystem.cs @@ -53,7 +53,7 @@ namespace PepperDash.Essentials if (Debug.DoNotLoadOnNextBoot) { - CrestronConsole.AddNewConsoleCommand(s => GoWithLoad(), "go", "Loads configuration file", + CrestronConsole.AddNewConsoleCommand(s => GoWithLoadDeferred(), "go", "Loads configuration file", ConsoleAccessLevelEnum.AccessOperator); } @@ -93,13 +93,18 @@ namespace PepperDash.Essentials if (!Debug.DoNotLoadOnNextBoot) { - GoWithLoad(); + GoWithLoad(null); return; } SystemMonitor.ProgramInitialization.ProgramInitializationComplete = true; } + private void GoWithLoadDeferred() + { + CrestronInvoke.BeginInvoke(GoWithLoad); + } + /// /// Determines if the program is running on a processor (appliance) or server (VC-4). /// @@ -172,7 +177,7 @@ namespace PepperDash.Essentials /// /// Begins the process of loading resources including plugins and configuration data /// - public void GoWithLoad() + public void GoWithLoad(object notUsed) { try { From 518c0a8bfb731348af0ff9ffb56665fd68dbc5f7 Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Wed, 29 Jul 2020 00:08:41 -0600 Subject: [PATCH 12/14] add push to nuget.org to workflows --- .github/workflows/docker.yml | 4 ++++ .github/workflows/main.yml | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index a1aae899..e14d60d6 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -155,10 +155,14 @@ jobs: uses: nuget/setup-nuget@v1 - name: Add Github Packages source run: nuget sources add -name github -source https://nuget.pkg.github.com/pepperdash/index.json -username Pepperdash -password ${{ secrets.GITHUB_TOKEN }} + - name: Add nuget.org API Key + run: nuget setApiKey ${{ secrets.NUGET_API_KEY }} - name: Create nuget package run: nuget pack "./PepperDash_Essentials_Core.nuspec" -version ${{ env.VERSION }} - name: Publish nuget package to Github registry run: nuget push **/*.nupkg -source github + - name: Publish nuget package to nuget.org + run: nuget push **/*.nupkg -Source https://api.nuget.org/v3/index.json # This step always runs and pushes the build to the internal build rep Internal_Push_Output: needs: Build_Project diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 0b8a49b9..959dd894 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -126,10 +126,14 @@ jobs: uses: nuget/setup-nuget@v1 - name: Add Github Packages source run: nuget sources add -name github -source https://nuget.pkg.github.com/pepperdash/index.json -username Pepperdash -password ${{ secrets.GITHUB_TOKEN }} + - name: Add nuget.org API Key + run: nuget setApiKey ${{ secrets.NUGET_API_KEY }} - name: Create nuget package run: nuget pack "./PepperDash_Essentials_Core.nuspec" -version ${{ env.VERSION }} - name: Publish nuget package to Github registry run: nuget push **/*.nupkg -source github + - name: Publish nuget package to nuget.org + run: nuget push **/*.nupkg -Source https://api.nuget.org/v3/index.json Internal_Push_Output: needs: Build_Project runs-on: windows-latest From dbafce0aa896c0b5288e8591f8375990ea45b9f5 Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Wed, 29 Jul 2020 14:42:26 -0600 Subject: [PATCH 13/14] fix RunRouteAction methods --- .../Room/Types/EssentialsHuddleVtc1Room.cs | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/PepperDashEssentials/Room/Types/EssentialsHuddleVtc1Room.cs b/PepperDashEssentials/Room/Types/EssentialsHuddleVtc1Room.cs index b7ce3030..72f17a73 100644 --- a/PepperDashEssentials/Room/Types/EssentialsHuddleVtc1Room.cs +++ b/PepperDashEssentials/Room/Types/EssentialsHuddleVtc1Room.cs @@ -405,12 +405,7 @@ namespace PepperDash.Essentials /// public void RunRouteAction(string routeKey, string sourceListKey) { - if (string.IsNullOrEmpty(sourceListKey)) - { - RunRouteAction(routeKey, new Action(() => { })); - } - else - throw new NotImplementedException(); + RunRouteAction(routeKey, new Action(() => { })); } /// @@ -421,12 +416,8 @@ namespace PepperDash.Essentials /// public void RunRouteAction(string routeKey, string sourceListKey, Action successCallback) { - if (string.IsNullOrEmpty(sourceListKey)) - { RunRouteAction(routeKey, successCallback); - } - else - throw new NotImplementedException(); + } /// From 55e50f68d31c45ce57cc0ae15d88f8f799306ec1 Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Thu, 30 Jul 2020 13:35:35 -0600 Subject: [PATCH 14/14] check h323 object for null --- .../VideoCodec/CiscoCodec/CiscoSparkCodec.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/CiscoCodec/CiscoSparkCodec.cs b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/CiscoCodec/CiscoSparkCodec.cs index bd4fee99..07f73de5 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/CiscoCodec/CiscoSparkCodec.cs +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/VideoCodec/CiscoCodec/CiscoSparkCodec.cs @@ -1638,7 +1638,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco { get { - if (CodecConfiguration.Configuration.H323.H323Alias.E164 != null) + if (CodecConfiguration.Configuration.H323 != null && CodecConfiguration.Configuration.H323.H323Alias.E164 != null) return CodecConfiguration.Configuration.H323.H323Alias.E164.Value; else return string.Empty; @@ -1648,7 +1648,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco { get { - if (CodecConfiguration.Configuration.H323.H323Alias.ID != null) + if (CodecConfiguration.Configuration.H323 != null && CodecConfiguration.Configuration.H323.H323Alias.ID != null) return CodecConfiguration.Configuration.H323.H323Alias.ID.Value; else return string.Empty;