diff --git a/.github/scripts/GenerateVersionNumber.ps1 b/.github/scripts/GenerateVersionNumber.ps1
index 81100e6..0a655e8 100644
--- a/.github/scripts/GenerateVersionNumber.ps1
+++ b/.github/scripts/GenerateVersionNumber.ps1
@@ -1,44 +1,22 @@
-$latestVersions = $(git tag --merged origin/main)
-$latestVersion = [version]"0.0.0"
-Foreach ($version in $latestVersions) {
- Write-Host $version
- try {
- if (([version]$version) -ge $latestVersion) {
- $latestVersion = $version
- Write-Host "Setting latest version to: $latestVersion"
- }
- }
- catch {
- Write-Host "Unable to convert $($version). Skipping"
- continue;
- }
-}
+$latestVersion = [version]"2.0.0"
$newVersion = [version]$latestVersion
$phase = ""
$newVersionString = ""
+
switch -regex ($Env:GITHUB_REF) {
- '^refs\/heads\/main*.' {
- $newVersionString = "{0}.{1}.{2}" -f $newVersion.Major, $newVersion.Minor, $newVersion.Build
+ '^refs\/pull\/*.' {
+ $phase = 'beta';
+ $newVersionString = "{0}-{1}-{2}" -f $newVersion, $phase, $Env:GITHUB_RUN_NUMBER
}
- '^refs\/heads\/feature\/*.' {
+ '^refs\/heads\/feature-2\/*.' {
$phase = 'alpha'
- $newVersionString = "{0}.{1}.{2}-{3}-{4}" -f $newVersion.Major, $newVersion.Minor, ($newVersion.Build + 1), $phase, $Env:GITHUB_RUN_NUMBER
+ $newVersionString = "{0}-{1}-{2}" -f $newVersion, $phase, $Env:GITHUB_RUN_NUMBER
}
- '^refs\/heads\/release\/*.' {
- $splitRef = $Env:GITHUB_REF -split "/"
- $version = [version]($splitRef[-1] -replace "v", "")
- $phase = 'rc'
- $newVersionString = "{0}.{1}.{2}-{3}-{4}" -f $version.Major, $version.Minor, $version.Build, $phase, $Env:GITHUB_RUN_NUMBER
- }
- '^refs\/heads\/development*.' {
+ 'development-2' {
$phase = 'beta'
- $newVersionString = "{0}.{1}.{2}-{3}-{4}" -f $newVersion.Major, $newVersion.Minor, ($newVersion.Build + 1), $phase, $Env:GITHUB_RUN_NUMBER
- }
- '^refs\/heads\/hotfix\/*.' {
- $phase = 'hotfix'
- $newVersionString = "{0}.{1}.{2}-{3}-{4}" -f $newVersion.Major, $newVersion.Minor, ($newVersion.Build + 1), $phase, $Env:GITHUB_RUN_NUMBER
- }
+ $newVersionString = "{0}-{1}-{2}" -f $newVersion, $phase, $Env:GITHUB_RUN_NUMBER
+ }
}
diff --git a/.github/workflows/add-issues-to-project.yml b/.github/workflows/add-issues-to-project.yml
new file mode 100644
index 0000000..8811c0c
--- /dev/null
+++ b/.github/workflows/add-issues-to-project.yml
@@ -0,0 +1,37 @@
+name: Add bugs to bugs project
+
+on:
+ issues:
+ types:
+ - opened
+ - labeled
+
+jobs:
+ check-secret:
+ runs-on: ubuntu-latest
+ outputs:
+ my-key: ${{ steps.my-key.outputs.defined }}
+ steps:
+ - id: my-key
+ if: "${{ env.MY_KEY != '' }}"
+ run: echo "::set-output name=defined::true"
+ env:
+ MY_KEY: ${{ secrets.PROJECT_URL }}
+ throw-error:
+ name: Check
+ runs-on: ubuntu-latest
+ needs: [check-secret]
+ if: needs.check-secret.outputs.my-key != 'true'
+ steps:
+ - run: echo "The Project URL Repo Secret is empty"
+ add-to-project:
+ name: Add issue to project
+ runs-on: ubuntu-latest
+ needs: [check-secret]
+ if: needs.check-secret.outputs.my-key == 'true'
+ steps:
+ - uses: actions/add-to-project@main
+ with:
+ project-url: ${{ secrets.PROJECT_URL }}
+ github-token: ${{ secrets.GH_PROJECTS_PASSWORD }}
+
diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml
index f71cf3a..af0d3d1 100644
--- a/.github/workflows/docker.yml
+++ b/.github/workflows/docker.yml
@@ -3,16 +3,16 @@ name: Branch Build Using Docker
on:
push:
branches:
- - feature/*
- - hotfix/*
- - release/*
- - development
+ - feature-2/*
+ - hotfix-2/*
+ - release-2/*
+ - development-2
env:
# solution path doesn't need slashes unless there it is multiple folders deep
# solution name does not include extension. .sln is assumed
SOLUTION_PATH: Pepperdash Core
- SOLUTION_FILE: PepperDash Core
+ SOLUTION_FILE: PepperDash Core 4-series
# Do not edit this, we're just creating it here
VERSION: 0.0.0-buildtype-buildnumber
# Defaults to debug for build type
@@ -20,135 +20,70 @@ env:
# Defaults to main as the release branch. Change as necessary
RELEASE_BRANCH: main
jobs:
- Build_Project:
- runs-on: windows-2019
- steps:
- # First we checkout the source repo
- - name: Checkout repo
- uses: actions/checkout@v2
- 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
- # Fetch all tags
+ Build_Project_4-Series:
+ runs-on: windows-latest
+ steps:
+ - uses: actions/checkout@v3
+ # Fetch all tags
- name: Fetch tags
run: git fetch --tags
# Generate the appropriate version number
- name: Set Version Number
+ id: setVersion
shell: powershell
run: |
- $version = ./.github/scripts/GenerateVersionNumber.ps1
- echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- # Use the version number to set the version of the assemblies
- - name: Update AssemblyInfo.cs
- shell: powershell
- run: |
- Write-Output ${{ env.VERSION }}
- ./.github/scripts/UpdateAssemblyVersion.ps1 ${{ env.VERSION }}
- # Login to Docker
- - name: Login to Docker
- uses: azure/docker-login@v1
- with:
- username: ${{ secrets.dockerhub_user }}
- password: ${{ secrets.dockerhub_password }}
+ $latestVersion = [version]"2.0.0"
+
+ $newVersion = [version]$latestVersion
+ $phase = ""
+ $newVersionString = ""
+
+ switch -regex ($Env:GITHUB_REF) {
+ '^refs\/pull\/*.' {
+ $phase = 'beta';
+ $newVersionString = "{0}-{1}-{2}" -f $newVersion, $phase, $Env:GITHUB_RUN_NUMBER
+ }
+ '^refs\/heads\/feature-2\/*.' {
+ $phase = 'alpha'
+ $newVersionString = "{0}-{1}-{2}" -f $newVersion, $phase, $Env:GITHUB_RUN_NUMBER
+ }
+ 'development-2' {
+ $phase = 'beta'
+ $newVersionString = "{0}-{1}-{2}" -f $newVersion, $phase, $Env:GITHUB_RUN_NUMBER
+ }
+ }
+ echo "version=$newVersionString" | Out-File -FilePath $env:GITHUB_OUTPUT -Encoding utf8 -Append
+ - name: Setup MS Build
+ uses: microsoft/setup-msbuild@v1.1
+ - name: restore Nuget Packages
+ run: nuget restore ./$($Env:SOLUTION_PATH)/$($Env:SOLUTION_FILE)
+ env:
+ SOLUTION_FILE: PepperDash Core 4-Series.sln
# Build the solutions in the docker image
- - name: Build Solution
- shell: powershell
- run: |
- Invoke-Expression "docker run --rm --mount type=bind,source=""$($Env:GITHUB_WORKSPACE)"",target=""c:/project"" pepperdash/sspbuilder c:\cihelpers\vsidebuild.exe -Solution ""c:\project\$($Env:SOLUTION_PATH)\$($Env:SOLUTION_FILE).sln"" -BuildSolutionConfiguration $($ENV:BUILD_TYPE)"
- - name: Zip Build Output
- shell: powershell
- run: ./.github/scripts/ZipBuildOutput.ps1
- # Write the version to a file to be consumed by the push jobs
- - name: Write Version
- run: Write-Output "$($Env:VERSION)" | Out-File -FilePath "$($Env:GITHUB_HOME)\output\version.txt"
- # Upload the build output as an artifact
- - name: Upload Build Output
- uses: actions/upload-artifact@v1
- with:
- name: Build
- path: ./${{ env.SOLUTION_FILE}}-${{ env.VERSION}}.zip
- # Upload the Version file as an artifact
- - name: Upload version.txt
- uses: actions/upload-artifact@v1
- with:
- name: Version
- path: ${{env.GITHUB_HOME}}\output\version.txt
- # Create the release on the source repo
+ - name: Build Solution
+ run: msbuild .\$($Env:SOLUTION_PATH)\$($Env:SOLUTION_FILE).sln /p:Platform="Any CPU" /p:Configuration="Debug" /p:Version="${{ steps.setVersion.outputs.version }}"
- name: Create tag for non-rc builds
- if: contains(env.VERSION, 'alpha') || contains(env.VERSION, 'beta')
+ if: contains(steps.setVersion.outputs.version, 'alpha') || contains(steps.setVersion.outputs.version, 'beta')
run: |
- git tag $($Env:VERSION)
+ git tag ${{ steps.setVersion.outputs.version }}
git push --tags origin
+ # Create the release on the source repo
- name: Create Release
id: create_release
- # using contributor's version to allow for pointing at the right commit
- if: contains(env.VERSION,'-rc-') || contains(env.VERSION,'-hotfix-')
- uses: fleskesvor/create-release@feature/support-target-commitish
+ if: contains(steps.setVersion.outputs.version,'-rc-') || contains(steps.setVersion.outputs.version,'-hotfix-')
+ uses: actions/create-release@v1
with:
- tag_name: ${{ env.VERSION }}
- release_name: ${{ env.VERSION }}
+ tag_name: ${{ steps.setVersion.outputs.version }}
+ release_name: ${{ steps.setVersion.outputs.version }}
prerelease: ${{contains('debug', env.BUILD_TYPE)}}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Upload the build package to the release
- - name: Upload Release Package
- if: contains(env.VERSION,'-rc-') || contains(env.VERSION,'-hotfix-')
- id: upload_release
- uses: actions/upload-release-asset@v1
- with:
- upload_url: ${{ steps.create_release.outputs.upload_url }}
- asset_path: ./${{ env.SOLUTION_FILE}}-${{ env.VERSION}}.zip
- asset_name: ${{ env.SOLUTION_FILE}}-${{ env.VERSION}}.zip
- 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"
- echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- 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: Add nuget.org API Key
- run: nuget setApiKey ${{ secrets.NUGET_API_KEY }}
- - name: Create nuget package
- run: nuget pack "./PepperDash_Core.nuspec" -version ${{ env.VERSION }}
+ run: nuget setApiKey ${{ secrets.NUGET_API_KEY }}
- name: Publish nuget package to Github registry
- run: nuget push **/*.nupkg -source github
+ run: nuget push ".\package\PepperDashCore.${{ steps.setVersion.outputs.version }}.nupkg" -Source github
- name: Publish nuget package to nuget.org
- run: nuget push **/*.nupkg -Source https://api.nuget.org/v3/index.json
+ run: nuget push ".\package\PepperDashCore.${{ steps.setVersion.outputs.version }}.nupkg" -Source https://api.nuget.org/v3/index.json
\ No newline at end of file
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index 25bb227..3ebeb23 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -18,20 +18,14 @@ env:
# Defaults to main as the release branch. Change as necessary
RELEASE_BRANCH: main
jobs:
- Build_Project:
- runs-on: windows-2019
+ Build_Project_4-Series:
+ runs-on: windows-latest
steps:
# First we checkout the source repo
- 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
+ with:
+ fetch-depth: 0
# Generate the appropriate version number
- name: Set Version Number
shell: powershell
@@ -44,77 +38,74 @@ jobs:
run: |
Write-Output ${{ env.VERSION }}
./.github/scripts/UpdateAssemblyVersion.ps1 ${{ env.VERSION }}
- # Login to Docker
- - name: Login to Docker
- uses: azure/docker-login@v1
- with:
- username: ${{ secrets.dockerhub_user }}
- password: ${{ secrets.dockerhub_password }}
+ - name: Setup MS-Build
+ uses: microsoft/setup-msbuild@v1
+ - name: restore Nuget Packages
+ run: nuget restore ./4-series/$($Env:SOLUTION_FILE).sln
# Build the solutions in the docker image
- name: Build Solution
shell: powershell
run: |
- Invoke-Expression "docker run --rm --mount type=bind,source=""$($Env:GITHUB_WORKSPACE)"",target=""c:/project"" pepperdash/sspbuilder c:\cihelpers\vsidebuild.exe -Solution ""c:\project\$($Env:SOLUTION_PATH)\$($Env:SOLUTION_FILE).sln"" -BuildSolutionConfiguration $($ENV:BUILD_TYPE)"
+ msbuild "./$($Env:SOLUTION_PATH)/$($Env:SOLUTION_FILE) 4-Series.sln" /p:platform="Any CPU" /p:configuration="Release"
# Zip up the output files as needed
- name: Zip Build Output
shell: powershell
- run: ./.github/scripts/ZipBuildOutput.ps1
+ run: |
+ $destination = "$($Env:GITHUB_HOME)\output"
+ New-Item -ItemType Directory -Force -Path ($destination)
+ Get-ChildItem ($destination)
+ $exclusions = @("packages", "3-series")
+ # 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", "*.nuspec" | ForEach-Object {
+ $allowed = $true;
+ # Exclude any files in submodules
+ foreach ($exclude in $exclusions) {
+ if ((Split-Path $_.FullName -Parent).contains("$($exclude)")) {
+ $allowed = $false;
+ break;
+ }
+ }
+ if ($allowed) {
+ Write-Host "allowing $($_)"
+ $_;
+ }
+ } | Copy-Item -Destination ($destination) -Force
+ Write-Host "Getting matching files..."
+ # Get any files from the output folder that match the following extensions
+ Get-ChildItem -Path $destination | Where-Object {($_.Extension -eq ".clz") -or ($_.Extension -eq ".cpz" -or ($_.Extension -eq ".cplz"))} | ForEach-Object {
+ # Replace the extensions with dll and xml and create an array
+ $filenames = @($($_ -replace "cpz|clz|cplz", "dll"), $($_ -replace "cpz|clz|cplz", "xml"))
+ Write-Host "Filenames:"
+ Write-Host $filenames
+ if ($filenames.length -gt 0) {
+ # Attempt to get the files and return them to the output directory
+ Get-ChildItem -Recurse -Path "$($Env:GITHUB_WORKSPACE)" -include $filenames | Copy-Item -Destination ($destination) -Force
+ }
+ }
+ Get-ChildItem -Path $destination\*.cplz | Rename-Item -NewName { "$($_.BaseName)-4s-$($Env:VERSION)$($_.Extension)" }
+ Compress-Archive -Path $destination -DestinationPath "$($Env:GITHUB_WORKSPACE)\$($Env:SOLUTION_FILE)-4s-$($Env:VERSION).zip" -Force
+ Write-Host "Output Contents post Zip"
+ Get-ChildItem -Path $destination
# Write the version to a file to be consumed by the push jobs
- name: Write Version
run: Write-Output "$($Env:VERSION)" | Out-File -FilePath "$($Env:GITHUB_HOME)\output\version.txt"
- name: Upload Build Output
uses: actions/upload-artifact@v1
with:
- name: Build
- path: ./${{ env.SOLUTION_FILE}}-${{ env.VERSION}}.zip
- # Upload the Version file as an artifact
- - name: Upload version.txt
- uses: actions/upload-artifact@v1
- with:
- name: Version
- path: ${{env.GITHUB_HOME}}\output\version.txt
+ name: ${{ env.SOLUTION_FILE}}-4s-${{ env.VERSION}}.zip
+ path: ./${{ env.SOLUTION_FILE}}-4s-${{ env.VERSION}}.zip
# Upload the build package to the release
- name: Upload Release Package
id: upload_release
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
- asset_path: ./${{ env.SOLUTION_FILE}}-${{ env.VERSION}}.zip
- asset_name: ${{ env.SOLUTION_FILE}}-${{ env.VERSION}}.zip
+ asset_path: ./${{ env.SOLUTION_FILE}}-4s-${{ env.VERSION}}.zip
+ asset_name: ${{ env.SOLUTION_FILE}}-4s-${{ env.VERSION}}.zip
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"
- echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- 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
@@ -122,8 +113,8 @@ jobs:
- name: Add nuget.org API Key
run: nuget setApiKey ${{ secrets.NUGET_API_KEY }}
- name: Create nuget package
- run: nuget pack "./PepperDash_Core.nuspec" -version ${{ env.VERSION }}
+ run: nuget pack "./Pepperdash Core/Pepperdash Core/PepperDash_Core_4-Series.csproj.nuspec" -version ${{ env.VERSION }}
- name: Publish nuget package to Github registry
- run: nuget push **/*.nupkg -source github
+ 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
+ run: nuget push "./*.nupkg" -Source https://api.nuget.org/v3/index.json
diff --git a/.gitignore b/.gitignore
index 4da46f9..8a30d25 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,25 +1,398 @@
-#ignore thumbnails created by windows
-Thumbs.db
-#Ignore files build by Visual Studio
+## Ignore Visual Studio temporary files, build results, and
+## files generated by popular Visual Studio add-ons.
+##
+## Get latest from https://github.com/github/gitignore/blob/main/VisualStudio.gitignore
+
+# User-specific files
+*.rsuser
+*.suo
*.user
-*.aps
-*.pch
-*.vspscc
+*.userosscache
+*.sln.docstates
+
+# User-specific files (MonoDevelop/Xamarin Studio)
+*.userprefs
+
+# Mono auto generated files
+mono_crash.*
+
+# Build results
+[Dd]ebug/
+[Dd]ebugPublic/
+[Rr]elease/
+[Rr]eleases/
+x64/
+x86/
+[Ww][Ii][Nn]32/
+[Aa][Rr][Mm]/
+[Aa][Rr][Mm]64/
+bld/
+[Bb]in/
+[Oo]bj/
+[Ll]og/
+[Ll]ogs/
+
+# Visual Studio 2015/2017 cache/options directory
+.vs/
+# Uncomment if you have tasks that create the project's static files in wwwroot
+#wwwroot/
+
+# Visual Studio 2017 auto generated files
+Generated\ Files/
+
+# MSTest test Results
+[Tt]est[Rr]esult*/
+[Bb]uild[Ll]og.*
+
+# NUnit
+*.VisualState.xml
+TestResult.xml
+nunit-*.xml
+
+# Build Results of an ATL Project
+[Dd]ebugPS/
+[Rr]eleasePS/
+dlldata.c
+
+# Benchmark Results
+BenchmarkDotNet.Artifacts/
+
+# .NET Core
+project.lock.json
+project.fragment.lock.json
+artifacts/
+
+# ASP.NET Scaffolding
+ScaffoldingReadMe.txt
+
+# StyleCop
+StyleCopReport.xml
+
+# Files built by Visual Studio
*_i.c
*_p.c
-*.ncb
-*.suo
-*.bak
-*.cache
+*_h.h
*.ilk
-*.log
-[Bb]in/
-[Dd]ebug*/
+*.meta
+*.obj
+*.iobj
+*.pch
+*.pdb
+*.ipdb
+*.pgc
+*.pgd
+*.rsp
*.sbr
-obj/
-[Rr]elease*/
+*.tlb
+*.tli
+*.tlh
+*.tmp
+*.tmp_proj
+*_wpftmp.csproj
+*.log
+*.tlog
+*.vspscc
+*.vssscc
+.builds
+*.pidb
+*.svclog
+*.scc
+
+# Chutzpah Test files
+_Chutzpah*
+
+# Visual C++ cache files
+ipch/
+*.aps
+*.ncb
+*.opendb
+*.opensdf
+*.sdf
+*.cachefile
+*.VC.db
+*.VC.VC.opendb
+
+# Visual Studio profiler
+*.psess
+*.vsp
+*.vspx
+*.sap
+
+# Visual Studio Trace Files
+*.e2e
+
+# TFS 2012 Local Workspace
+$tf/
+
+# Guidance Automation Toolkit
+*.gpState
+
+# ReSharper is a .NET coding add-in
_ReSharper*/
-SIMPLSharpLogs/
-*.projectinfo
+*.[Rr]e[Ss]harper
+*.DotSettings.user
+
+# TeamCity is a build add-in
+_TeamCity*
+
+# DotCover is a Code Coverage Tool
+*.dotCover
+
+# AxoCover is a Code Coverage Tool
+.axoCover/*
+!.axoCover/settings.json
+
+# Coverlet is a free, cross platform Code Coverage Tool
+coverage*.json
+coverage*.xml
+coverage*.info
+
+# Visual Studio code coverage results
+*.coverage
+*.coveragexml
+
+# NCrunch
+_NCrunch_*
+.*crunch*.local.xml
+nCrunchTemp_*
+
+# MightyMoose
+*.mm.*
+AutoTest.Net/
+
+# Web workbench (sass)
+.sass-cache/
+
+# Installshield output folder
+[Ee]xpress/
+
+# DocProject is a documentation generator add-in
+DocProject/buildhelp/
+DocProject/Help/*.HxT
+DocProject/Help/*.HxC
+DocProject/Help/*.hhc
+DocProject/Help/*.hhk
+DocProject/Help/*.hhp
+DocProject/Help/Html2
+DocProject/Help/html
+
+# Click-Once directory
+publish/
+
+# Publish Web Output
+*.[Pp]ublish.xml
+*.azurePubxml
+# Note: Comment the next line if you want to checkin your web deploy settings,
+# but database connection strings (with potential passwords) will be unencrypted
+*.pubxml
+*.publishproj
+
+# Microsoft Azure Web App publish settings. Comment the next line if you want to
+# checkin your Azure Web App publish settings, but sensitive information contained
+# in these scripts will be unencrypted
+PublishScripts/
+
+# NuGet Packages
*.nupkg
-lib/
+# NuGet Symbol Packages
+*.snupkg
+# The packages folder can be ignored because of Package Restore
+**/[Pp]ackages/*
+# except build/, which is used as an MSBuild target.
+!**/[Pp]ackages/build/
+# Uncomment if necessary however generally it will be regenerated when needed
+#!**/[Pp]ackages/repositories.config
+# NuGet v3's project.json files produces more ignorable files
+*.nuget.props
+*.nuget.targets
+
+# Microsoft Azure Build Output
+csx/
+*.build.csdef
+
+# Microsoft Azure Emulator
+ecf/
+rcf/
+
+# Windows Store app package directories and files
+AppPackages/
+BundleArtifacts/
+Package.StoreAssociation.xml
+_pkginfo.txt
+*.appx
+*.appxbundle
+*.appxupload
+
+# Visual Studio cache files
+# files ending in .cache can be ignored
+*.[Cc]ache
+# but keep track of directories ending in .cache
+!?*.[Cc]ache/
+
+# Others
+ClientBin/
+~$*
+*~
+*.dbmdl
+*.dbproj.schemaview
+*.jfm
+*.pfx
+*.publishsettings
+orleans.codegen.cs
+
+# Including strong name files can present a security risk
+# (https://github.com/github/gitignore/pull/2483#issue-259490424)
+#*.snk
+
+# Since there are multiple workflows, uncomment next line to ignore bower_components
+# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
+#bower_components/
+
+# RIA/Silverlight projects
+Generated_Code/
+
+# Backup & report files from converting an old project file
+# to a newer Visual Studio version. Backup files are not needed,
+# because we have git ;-)
+_UpgradeReport_Files/
+Backup*/
+UpgradeLog*.XML
+UpgradeLog*.htm
+ServiceFabricBackup/
+*.rptproj.bak
+
+# SQL Server files
+*.mdf
+*.ldf
+*.ndf
+
+# Business Intelligence projects
+*.rdl.data
+*.bim.layout
+*.bim_*.settings
+*.rptproj.rsuser
+*- [Bb]ackup.rdl
+*- [Bb]ackup ([0-9]).rdl
+*- [Bb]ackup ([0-9][0-9]).rdl
+
+# Microsoft Fakes
+FakesAssemblies/
+
+# GhostDoc plugin setting file
+*.GhostDoc.xml
+
+# Node.js Tools for Visual Studio
+.ntvs_analysis.dat
+node_modules/
+
+# Visual Studio 6 build log
+*.plg
+
+# Visual Studio 6 workspace options file
+*.opt
+
+# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
+*.vbw
+
+# Visual Studio 6 auto-generated project file (contains which files were open etc.)
+*.vbp
+
+# Visual Studio 6 workspace and project file (working project files containing files to include in project)
+*.dsw
+*.dsp
+
+# Visual Studio 6 technical files
+*.ncb
+*.aps
+
+# Visual Studio LightSwitch build output
+**/*.HTMLClient/GeneratedArtifacts
+**/*.DesktopClient/GeneratedArtifacts
+**/*.DesktopClient/ModelManifest.xml
+**/*.Server/GeneratedArtifacts
+**/*.Server/ModelManifest.xml
+_Pvt_Extensions
+
+# Paket dependency manager
+.paket/paket.exe
+paket-files/
+
+# FAKE - F# Make
+.fake/
+
+# CodeRush personal settings
+.cr/personal
+
+# Python Tools for Visual Studio (PTVS)
+__pycache__/
+*.pyc
+
+# Cake - Uncomment if you are using it
+# tools/**
+# !tools/packages.config
+
+# Tabs Studio
+*.tss
+
+# Telerik's JustMock configuration file
+*.jmconfig
+
+# BizTalk build output
+*.btp.cs
+*.btm.cs
+*.odx.cs
+*.xsd.cs
+
+# OpenCover UI analysis results
+OpenCover/
+
+# Azure Stream Analytics local run output
+ASALocalRun/
+
+# MSBuild Binary and Structured Log
+*.binlog
+
+# NVidia Nsight GPU debugger configuration file
+*.nvuser
+
+# MFractors (Xamarin productivity tool) working folder
+.mfractor/
+
+# Local History for Visual Studio
+.localhistory/
+
+# Visual Studio History (VSHistory) files
+.vshistory/
+
+# BeatPulse healthcheck temp database
+healthchecksdb
+
+# Backup folder for Package Reference Convert tool in Visual Studio 2017
+MigrationBackup/
+
+# Ionide (cross platform F# VS Code tools) working folder
+.ionide/
+
+# Fody - auto-generated XML schema
+FodyWeavers.xsd
+
+# VS Code files for those working on multiple tools
+.vscode/*
+!.vscode/settings.json
+!.vscode/tasks.json
+!.vscode/launch.json
+!.vscode/extensions.json
+*.code-workspace
+
+# Local History for Visual Studio Code
+.history/
+
+# Windows Installer files from build outputs
+*.cab
+*.msi
+*.msix
+*.msm
+*.msp
+
+# JetBrains Rider
+*.sln.iml
diff --git a/Pepperdash Core/PepperDash Core 4-Series.sln b/Pepperdash Core/PepperDash Core 4-Series.sln
new file mode 100644
index 0000000..f488172
--- /dev/null
+++ b/Pepperdash Core/PepperDash Core 4-Series.sln
@@ -0,0 +1,25 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.1.32228.430
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PepperDash_Core_4-Series", "Pepperdash Core\PepperDash_Core_4-Series.csproj", "{E7376F15-9E7B-418E-83C2-ADFB5D4DFD8D}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {E7376F15-9E7B-418E-83C2-ADFB5D4DFD8D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {E7376F15-9E7B-418E-83C2-ADFB5D4DFD8D}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {E7376F15-9E7B-418E-83C2-ADFB5D4DFD8D}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {E7376F15-9E7B-418E-83C2-ADFB5D4DFD8D}.Release|Any CPU.Build.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {E4615FA3-8C8C-4DC0-897B-E85408B4E341}
+ EndGlobalSection
+EndGlobal
diff --git a/Pepperdash Core/Pepperdash Core.sln b/Pepperdash Core/Pepperdash Core.sln
deleted file mode 100644
index 527f806..0000000
--- a/Pepperdash Core/Pepperdash Core.sln
+++ /dev/null
@@ -1,19 +0,0 @@
-Microsoft Visual Studio Solution File, Format Version 10.00
-# Visual Studio 2008
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PepperDash_Core", "Pepperdash Core\PepperDash_Core.csproj", "{87E29B4C-569B-4368-A4ED-984AC1440C96}"
-EndProject
-Global
- GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug|Any CPU = Debug|Any CPU
- Release|Any CPU = Release|Any CPU
- EndGlobalSection
- GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {87E29B4C-569B-4368-A4ED-984AC1440C96}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {87E29B4C-569B-4368-A4ED-984AC1440C96}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {87E29B4C-569B-4368-A4ED-984AC1440C96}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {87E29B4C-569B-4368-A4ED-984AC1440C96}.Release|Any CPU.Build.0 = Release|Any CPU
- EndGlobalSection
- GlobalSection(SolutionProperties) = preSolution
- HideSolutionNode = FALSE
- EndGlobalSection
-EndGlobal
diff --git a/Pepperdash Core/Pepperdash Core/Comm/ControlPropertiesConfig.cs b/Pepperdash Core/Pepperdash Core/Comm/ControlPropertiesConfig.cs
index 47e0ec8..7bb7557 100644
--- a/Pepperdash Core/Pepperdash Core/Comm/ControlPropertiesConfig.cs
+++ b/Pepperdash Core/Pepperdash Core/Comm/ControlPropertiesConfig.cs
@@ -1,9 +1,11 @@
-using System;
+extern alias Full;
+
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
-using Newtonsoft.Json;
+using Full.Newtonsoft.Json;
namespace PepperDash.Core
{
diff --git a/Pepperdash Core/Pepperdash Core/Comm/GenericSecureTcpIpServer.cs b/Pepperdash Core/Pepperdash Core/Comm/GenericSecureTcpIpServer.cs
index d53a801..7731556 100644
--- a/Pepperdash Core/Pepperdash Core/Comm/GenericSecureTcpIpServer.cs
+++ b/Pepperdash Core/Pepperdash Core/Comm/GenericSecureTcpIpServer.cs
@@ -9,14 +9,15 @@ and in all parts thereof, regardless of the use to which it is being put. Any u
of this material by another party without the express written permission of PepperDash Technology Corporation is prohibited.
PepperDash Technology Corporation reserves all rights under applicable laws.
------------------------------------ */
+extern alias Full;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronSockets;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
namespace PepperDash.Core
{
diff --git a/Pepperdash Core/Pepperdash Core/Comm/GenericSshClient.cs b/Pepperdash Core/Pepperdash Core/Comm/GenericSshClient.cs
index 88f9682..b5d9ba2 100644
--- a/Pepperdash Core/Pepperdash Core/Comm/GenericSshClient.cs
+++ b/Pepperdash Core/Pepperdash Core/Comm/GenericSshClient.cs
@@ -66,7 +66,7 @@ namespace PepperDash.Core
{
// returns false if no client or not connected
get { return Client != null && ClientStatus == SocketStatus.SOCKET_STATUS_CONNECTED; }
- }
+ }
///
/// S+ helper for IsConnected
@@ -312,17 +312,15 @@ namespace PepperDash.Core
///
public void Disconnect()
{
- try
- {
- connectLock.Enter();
- // Stop trying reconnects, if we are
- ReconnectTimer.Stop();
- KillClient(SocketStatus.SOCKET_STATUS_BROKEN_LOCALLY);
- }
- finally
- {
- connectLock.Leave();
- }
+ ConnectEnabled = false;
+ // Stop trying reconnects, if we are
+ if (ReconnectTimer != null)
+ {
+ ReconnectTimer.Stop();
+ ReconnectTimer = null;
+ }
+
+ KillClient(SocketStatus.SOCKET_STATUS_BROKEN_LOCALLY);
}
///
@@ -331,24 +329,44 @@ namespace PepperDash.Core
private void KillClient(SocketStatus status)
{
KillStream();
-
+
if (Client != null)
- {
- try
- {
- Client.Disconnect();
- Client.Dispose();
- Client = null;
- ClientStatus = status;
- Debug.Console(1, this, "Disconnected client");
- }
- catch (Exception ex)
- {
- Debug.Console(1, this, "Exception killing client: {0}", ex.Message);
- }
+ {
+ Client.Disconnect();
+ Client = null;
+ ClientStatus = status;
+ Debug.Console(1, this, "Disconnected");
}
}
+ ///
+ /// Anything to do with reestablishing connection on failures
+ ///
+ void HandleConnectionFailure()
+ {
+ KillClient(SocketStatus.SOCKET_STATUS_CONNECT_FAILED);
+
+ Debug.Console(1, this, "Client nulled due to connection failure. AutoReconnect: {0}, ConnectEnabled: {1}", AutoReconnect, ConnectEnabled);
+ if (AutoReconnect && ConnectEnabled)
+ {
+ Debug.Console(1, this, "Checking autoreconnect: {0}, {1}ms", AutoReconnect, AutoReconnectIntervalMs);
+ if (ReconnectTimer == null)
+ {
+ ReconnectTimer = new CTimer(o =>
+ {
+ Connect();
+ }, AutoReconnectIntervalMs);
+ Debug.Console(1, this, "Attempting connection in {0} seconds",
+ (float) (AutoReconnectIntervalMs/1000));
+ }
+ else
+ {
+ Debug.Console(1, this, "{0} second reconnect cycle running",
+ (float) (AutoReconnectIntervalMs/1000));
+ }
+ }
+ }
+
///
/// Kills the stream
///
diff --git a/Pepperdash Core/Pepperdash Core/Comm/GenericTcpIpClient.cs b/Pepperdash Core/Pepperdash Core/Comm/GenericTcpIpClient.cs
index 8cfaad2..458a44c 100644
--- a/Pepperdash Core/Pepperdash Core/Comm/GenericTcpIpClient.cs
+++ b/Pepperdash Core/Pepperdash Core/Comm/GenericTcpIpClient.cs
@@ -1,11 +1,12 @@
-using System;
+extern alias Full;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronSockets;
-using Newtonsoft.Json;
+using Full.Newtonsoft.Json;
namespace PepperDash.Core
{
diff --git a/Pepperdash Core/Pepperdash Core/Comm/GenericTcpIpServer.cs b/Pepperdash Core/Pepperdash Core/Comm/GenericTcpIpServer.cs
index e3a00f2..e14bfd0 100644
--- a/Pepperdash Core/Pepperdash Core/Comm/GenericTcpIpServer.cs
+++ b/Pepperdash Core/Pepperdash Core/Comm/GenericTcpIpServer.cs
@@ -9,14 +9,15 @@ and in all parts thereof, regardless of the use to which it is being put. Any u
of this material by another party without the express written permission of PepperDash Technology Corporation is prohibited.
PepperDash Technology Corporation reserves all rights under applicable laws.
------------------------------------ */
+extern alias Full;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronSockets;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
namespace PepperDash.Core
{
diff --git a/Pepperdash Core/Pepperdash Core/Comm/GenericUdpServer.cs b/Pepperdash Core/Pepperdash Core/Comm/GenericUdpServer.cs
index 5bd85b0..e1daeb2 100644
--- a/Pepperdash Core/Pepperdash Core/Comm/GenericUdpServer.cs
+++ b/Pepperdash Core/Pepperdash Core/Comm/GenericUdpServer.cs
@@ -1,4 +1,5 @@
-using System;
+extern alias Full;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
@@ -7,8 +8,9 @@ using System.Text.RegularExpressions;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronSockets;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
diff --git a/Pepperdash Core/Pepperdash Core/Comm/TcpClientConfigObject.cs b/Pepperdash Core/Pepperdash Core/Comm/TcpClientConfigObject.cs
index c3b3bce..5c71a50 100644
--- a/Pepperdash Core/Pepperdash Core/Comm/TcpClientConfigObject.cs
+++ b/Pepperdash Core/Pepperdash Core/Comm/TcpClientConfigObject.cs
@@ -1,4 +1,6 @@
-using Newtonsoft.Json;
+extern alias Full;
+
+using Full.Newtonsoft.Json;
namespace PepperDash.Core
{
diff --git a/Pepperdash Core/Pepperdash Core/CommunicationExtras.cs b/Pepperdash Core/Pepperdash Core/CommunicationExtras.cs
index 353b14f..1548ece 100644
--- a/Pepperdash Core/Pepperdash Core/CommunicationExtras.cs
+++ b/Pepperdash Core/Pepperdash Core/CommunicationExtras.cs
@@ -1,12 +1,13 @@
-using System;
+extern alias Full;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronSockets;
using System.Text.RegularExpressions;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
namespace PepperDash.Core
{
diff --git a/Pepperdash Core/Pepperdash Core/Config/PortalConfigReader.cs b/Pepperdash Core/Pepperdash Core/Config/PortalConfigReader.cs
index f2ad746..803875f 100644
--- a/Pepperdash Core/Pepperdash Core/Config/PortalConfigReader.cs
+++ b/Pepperdash Core/Pepperdash Core/Config/PortalConfigReader.cs
@@ -1,10 +1,12 @@
-using System;
+extern alias Full;
+
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronIO;
diff --git a/Pepperdash Core/Pepperdash Core/EthernetHelper.cs b/Pepperdash Core/Pepperdash Core/EthernetHelper.cs
index 220d386..5e02540 100644
--- a/Pepperdash Core/Pepperdash Core/EthernetHelper.cs
+++ b/Pepperdash Core/Pepperdash Core/EthernetHelper.cs
@@ -1,10 +1,11 @@
-using System;
+extern alias Full;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
-using Newtonsoft.Json;
+using Full.Newtonsoft.Json;
namespace PepperDash.Core
{
diff --git a/Pepperdash Core/Pepperdash Core/JsonStandardObjects/JsonToSimplDevice.cs b/Pepperdash Core/Pepperdash Core/JsonStandardObjects/JsonToSimplDevice.cs
index eef68f2..97a0297 100644
--- a/Pepperdash Core/Pepperdash Core/JsonStandardObjects/JsonToSimplDevice.cs
+++ b/Pepperdash Core/Pepperdash Core/JsonStandardObjects/JsonToSimplDevice.cs
@@ -1,10 +1,11 @@
-using System;
+extern alias Full;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
using PepperDash.Core.JsonToSimpl;
namespace PepperDash.Core.JsonStandardObjects
diff --git a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplArrayLookupChild.cs b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplArrayLookupChild.cs
index 6535308..d1dd07c 100644
--- a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplArrayLookupChild.cs
+++ b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplArrayLookupChild.cs
@@ -1,10 +1,11 @@
-using System;
+extern alias Full;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
namespace PepperDash.Core.JsonToSimpl
{
diff --git a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplChildObjectBase.cs b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplChildObjectBase.cs
index e507105..1984293 100644
--- a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplChildObjectBase.cs
+++ b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplChildObjectBase.cs
@@ -1,10 +1,11 @@
-using System;
+extern alias Full;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
namespace PepperDash.Core.JsonToSimpl
{
diff --git a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplFileMaster.cs b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplFileMaster.cs
index c5f50d5..5fbd034 100644
--- a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplFileMaster.cs
+++ b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplFileMaster.cs
@@ -1,4 +1,5 @@
-using System;
+extern alias Full;
+using System;
//using System.IO;
using System.Collections.Generic;
using System.Linq;
@@ -6,8 +7,8 @@ using System.Text;
using System.Text.RegularExpressions;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronIO;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
namespace PepperDash.Core.JsonToSimpl
{
diff --git a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplFixedPathObject.cs b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplFixedPathObject.cs
index 4d56772..1ad0cd3 100644
--- a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplFixedPathObject.cs
+++ b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplFixedPathObject.cs
@@ -1,12 +1,14 @@
-using System;
+extern alias Full;
+
+using System;
//using System.IO;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronIO;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
namespace PepperDash.Core.JsonToSimpl
{
diff --git a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplGenericMaster.cs b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplGenericMaster.cs
index e0f42f8..d9b201d 100644
--- a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplGenericMaster.cs
+++ b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplGenericMaster.cs
@@ -1,7 +1,9 @@
-using System;
+extern alias Full;
+
+using System;
using System.Collections.Generic;
using Crestron.SimplSharp;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json.Linq;
namespace PepperDash.Core.JsonToSimpl
{
diff --git a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplMaster.cs b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplMaster.cs
index 2443c0a..ab13429 100644
--- a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplMaster.cs
+++ b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplMaster.cs
@@ -1,12 +1,14 @@
-using System;
+extern alias Full;
+
+using System;
//using System.IO;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronIO;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
namespace PepperDash.Core.JsonToSimpl
{
@@ -162,7 +164,7 @@ namespace PepperDash.Core.JsonToSimpl
///
public static JObject ParseObject(string json)
{
- using (var reader = new JsonTextReader(new Crestron.SimplSharp.CrestronIO.StringReader(json)))
+ using (var reader = new JsonTextReader(new System.IO.StringReader(json)))
{
var startDepth = reader.Depth;
var obj = JObject.Load(reader);
@@ -179,7 +181,7 @@ namespace PepperDash.Core.JsonToSimpl
///
public static JArray ParseArray(string json)
{
- using (var reader = new JsonTextReader(new Crestron.SimplSharp.CrestronIO.StringReader(json)))
+ using (var reader = new JsonTextReader(new System.IO.StringReader(json)))
{
var startDepth = reader.Depth;
var obj = JArray.Load(reader);
diff --git a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplPortalFileMaster.cs b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplPortalFileMaster.cs
index ca307e5..30b14ac 100644
--- a/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplPortalFileMaster.cs
+++ b/Pepperdash Core/Pepperdash Core/JsonToSimpl/JsonToSimplPortalFileMaster.cs
@@ -1,12 +1,14 @@
-using System;
+extern alias Full;
+
+using System;
//using System.IO;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronIO;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
using PepperDash.Core.Config;
diff --git a/Pepperdash Core/Pepperdash Core/JsonToSimpl/REMOVE JsonToSimplFixedPathObject.cs b/Pepperdash Core/Pepperdash Core/JsonToSimpl/REMOVE JsonToSimplFixedPathObject.cs
deleted file mode 100644
index ef41a77..0000000
--- a/Pepperdash Core/Pepperdash Core/JsonToSimpl/REMOVE JsonToSimplFixedPathObject.cs
+++ /dev/null
@@ -1,20 +0,0 @@
-//using System;
-////using System.IO;
-//using System.Collections.Generic;
-//using System.Linq;
-//using System.Text;
-//using Crestron.SimplSharp;
-//using Crestron.SimplSharp.CrestronIO;
-//using Newtonsoft.Json;
-//using Newtonsoft.Json.Linq;
-
-//namespace PepperDash.Core.JsonToSimpl
-//{
-
-// public class JsonToSimplFixedPathObject : JsonToSimplChildObjectBase
-// {
-// public JsonToSimplFixedPathObject()
-// {
-// }
-// }
-//}
\ No newline at end of file
diff --git a/Pepperdash Core/Pepperdash Core/Logging/Debug.cs b/Pepperdash Core/Pepperdash Core/Logging/Debug.cs
index 1a84968..b4d212d 100644
--- a/Pepperdash Core/Pepperdash Core/Logging/Debug.cs
+++ b/Pepperdash Core/Pepperdash Core/Logging/Debug.cs
@@ -1,11 +1,12 @@
-using System;
+extern alias Full;
+using System;
using System.Collections.Generic;
using System.Text.RegularExpressions;
using Crestron.SimplSharp;
using Crestron.SimplSharp.Reflection;
using Crestron.SimplSharp.CrestronLogger;
using Crestron.SimplSharp.CrestronIO;
-using Newtonsoft.Json;
+using Full.Newtonsoft.Json;
using PepperDash.Core.DebugThings;
@@ -186,7 +187,7 @@ namespace PepperDash.Core
{
if (string.IsNullOrEmpty(levelString.Trim()))
{
- CrestronConsole.PrintLine("AppDebug level = {0}", Level);
+ CrestronConsole.ConsoleCommandResponse("AppDebug level = {0}", Level);
return;
}
@@ -194,7 +195,7 @@ namespace PepperDash.Core
}
catch
{
- CrestronConsole.PrintLine("Usage: appdebug:P [0-2]");
+ CrestronConsole.ConsoleCommandResponse("Usage: appdebug:P [0-2]");
}
}
@@ -208,7 +209,7 @@ namespace PepperDash.Core
{
if (string.IsNullOrEmpty(stateString.Trim()))
{
- CrestronConsole.PrintLine("DoNotLoadOnNextBoot = {0}", DoNotLoadOnNextBoot);
+ CrestronConsole.ConsoleCommandResponse("DoNotLoadOnNextBoot = {0}", DoNotLoadOnNextBoot);
return;
}
@@ -216,7 +217,7 @@ namespace PepperDash.Core
}
catch
{
- CrestronConsole.PrintLine("Usage: donotloadonnextboot:P [true/false]");
+ CrestronConsole.ConsoleCommandResponse("Usage: donotloadonnextboot:P [true/false]");
}
}
@@ -312,7 +313,7 @@ namespace PepperDash.Core
_contexts.GetOrCreateItem("DEFAULT").Level = level;
SaveMemoryOnTimeout();
- CrestronConsole.PrintLine("[Application {0}], Debug level set to {1}",
+ CrestronConsole.ConsoleCommandResponse("[Application {0}], Debug level set to {1}",
InitialParametersClass.ApplicationNumber, Level);
//var err = CrestronDataStoreStatic.SetLocalUintValue("DebugLevel", level);
@@ -353,7 +354,7 @@ namespace PepperDash.Core
_contexts.GetOrCreateItem("DEFAULT").DoNotLoadOnNextBoot = state;
SaveMemoryOnTimeout();
- CrestronConsole.PrintLine("[Application {0}], Do Not Start on Next Boot set to {1}",
+ CrestronConsole.ConsoleCommandResponse("[Application {0}], Do Not Start on Next Boot set to {1}",
InitialParametersClass.ApplicationNumber, DoNotLoadOnNextBoot);
}
diff --git a/Pepperdash Core/Pepperdash Core/Logging/DebugContext.cs b/Pepperdash Core/Pepperdash Core/Logging/DebugContext.cs
index 39c47c3..3d7e7bb 100644
--- a/Pepperdash Core/Pepperdash Core/Logging/DebugContext.cs
+++ b/Pepperdash Core/Pepperdash Core/Logging/DebugContext.cs
@@ -1,11 +1,13 @@
-using System;
+extern alias Full;
+
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
using Crestron.SimplSharp.CrestronDataStore;
using Crestron.SimplSharp.CrestronIO;
-using Newtonsoft.Json;
+using Full.Newtonsoft.Json;
using PepperDash.Core.DebugThings;
@@ -101,7 +103,7 @@ namespace PepperDash.Core
{
if (string.IsNullOrEmpty(levelString.Trim()))
{
- CrestronConsole.PrintLine("AppDebug level = {0}", SaveData.Level);
+ CrestronConsole.ConsoleCommandResponse("AppDebug level = {0}", SaveData.Level);
return;
}
diff --git a/Pepperdash Core/Pepperdash Core/Logging/DebugMemory.cs b/Pepperdash Core/Pepperdash Core/Logging/DebugMemory.cs
index ab48afe..6bb3dbb 100644
--- a/Pepperdash Core/Pepperdash Core/Logging/DebugMemory.cs
+++ b/Pepperdash Core/Pepperdash Core/Logging/DebugMemory.cs
@@ -1,7 +1,9 @@
-using System.Collections.Generic;
+extern alias Full;
+
+using System.Collections.Generic;
using Crestron.SimplSharp;
-using Newtonsoft.Json;
+using Full.Newtonsoft.Json;
namespace PepperDash.Core.DebugThings
{
diff --git a/Pepperdash Core/Pepperdash Core/PasswordManagement/PasswordManager.cs b/Pepperdash Core/Pepperdash Core/PasswordManagement/PasswordManager.cs
index c9bc06b..3c3ec53 100644
--- a/Pepperdash Core/Pepperdash Core/PasswordManagement/PasswordManager.cs
+++ b/Pepperdash Core/Pepperdash Core/PasswordManagement/PasswordManager.cs
@@ -1,9 +1,11 @@
-using System;
+extern alias Full;
+
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
using Crestron.SimplSharp;
using PepperDash.Core.JsonToSimpl;
using PepperDash.Core.JsonStandardObjects;
diff --git a/Pepperdash Core/Pepperdash Core/PepperDash_Core.csproj b/Pepperdash Core/Pepperdash Core/PepperDash_Core.csproj
deleted file mode 100644
index 86ae71d..0000000
--- a/Pepperdash Core/Pepperdash Core/PepperDash_Core.csproj
+++ /dev/null
@@ -1,149 +0,0 @@
-
-
- Release
- AnyCPU
- 9.0.30729
- 2.0
- {87E29B4C-569B-4368-A4ED-984AC1440C96}
- Library
- Properties
- PepperDash_Core
- PepperDash_Core
- {0B4745B0-194B-4BB6-8E21-E9057CA92500};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
- WindowsCE
- E2BECB1F-8C8C-41ba-B736-9BE7D946A398
- 5.0
- SmartDeviceProject1
- v3.5
- Windows CE
-
-
-
-
- .allowedReferenceRelatedFileExtensions
- true
- full
- false
- bin\
- DEBUG;TRACE;
- prompt
- 4
- 512
- true
- true
- bin\PepperDash_Core.xml
-
-
- .allowedReferenceRelatedFileExtensions
- none
- true
- bin\
- prompt
- 4
- 512
- true
- true
- bin\PepperDash_Core.xml
-
-
-
-
- False
- ..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpCustomAttributesInterface.dll
-
-
- False
- ..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpHelperInterface.dll
-
-
- False
- ..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpNewtonsoft.dll
-
-
- False
- ..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpReflectionInterface.dll
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Code
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- rem S# preparation will execute after these operations
- del "$(TargetDir)PepperDash_Core.*" /q
-
-
-
\ No newline at end of file
diff --git a/Pepperdash Core/Pepperdash Core/PepperDash_Core.projectinfo b/Pepperdash Core/Pepperdash Core/PepperDash_Core.projectinfo
new file mode 100644
index 0000000..ded18d3
Binary files /dev/null and b/Pepperdash Core/Pepperdash Core/PepperDash_Core.projectinfo differ
diff --git a/Pepperdash Core/Pepperdash Core/PepperDash_Core_4-Series.csproj b/Pepperdash Core/Pepperdash Core/PepperDash_Core_4-Series.csproj
new file mode 100644
index 0000000..2349350
--- /dev/null
+++ b/Pepperdash Core/Pepperdash Core/PepperDash_Core_4-Series.csproj
@@ -0,0 +1,46 @@
+
+
+ PepperDash.Core
+ PepperDashCore
+ net472
+ false
+ en
+ bin\4Series\$(Configuration)\
+ False
+ True
+ PepperDash Core
+ PepperDash Technologies
+ git
+ https://github.com/PepperDash/PepperDashCore
+ crestron;4series;
+ $(Version)
+ ../../package
+
+
+ full
+ TRACE;DEBUG;SERIES4
+
+
+ pdbonly
+ bin\4Series\$(Configuration)\PepperDashCore.xml
+
+
+
+
+
+
+
+
+
+ Full
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Pepperdash Core/Pepperdash Core/PepperDash_Core_4-Series.csproj.nuspec b/Pepperdash Core/Pepperdash Core/PepperDash_Core_4-Series.csproj.nuspec
new file mode 100644
index 0000000..a41ee50
--- /dev/null
+++ b/Pepperdash Core/Pepperdash Core/PepperDash_Core_4-Series.csproj.nuspec
@@ -0,0 +1,20 @@
+
+
+
+ PepperDashCore4Series
+ 1.0.0
+ PepperDash Technologies
+ false
+ MIT
+ https://github.com/PepperDash/PepperDashCore
+ PepperDash Core is an open source Crestron SIMPL# library that can be used in SIMPL# Pro applications such as Essentials or as a standalone library with SIMPL+ wrappers to expose functionality in SIMPL Windows programs.
+
+ $copyright$
+ Crestron 4series
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Pepperdash Core/Pepperdash Core/Properties/AssemblyInfo.cs b/Pepperdash Core/Pepperdash Core/Properties/AssemblyInfo.cs
deleted file mode 100644
index 91db8cb..0000000
--- a/Pepperdash Core/Pepperdash Core/Properties/AssemblyInfo.cs
+++ /dev/null
@@ -1,7 +0,0 @@
-[assembly: System.Reflection.AssemblyTitle("Pepperdash_Core")]
-[assembly: System.Reflection.AssemblyCompany("PepperDash Technology Corp")]
-[assembly: System.Reflection.AssemblyProduct("Pepperdash_Core")]
-[assembly: System.Reflection.AssemblyCopyright("Copyright © PepperDash 2019")]
-[assembly: System.Reflection.AssemblyVersion("1.0.0.*")]
-[assembly: System.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
-[assembly: Crestron.SimplSharp.Reflection.AssemblyInformationalVersion("0.0.0-buildType-buildNumber")]
diff --git a/Pepperdash Core/Pepperdash Core/Properties/AssemblyInfo.cs.orig b/Pepperdash Core/Pepperdash Core/Properties/AssemblyInfo.cs.orig
deleted file mode 100644
index 4d15192..0000000
--- a/Pepperdash Core/Pepperdash Core/Properties/AssemblyInfo.cs.orig
+++ /dev/null
@@ -1,11 +0,0 @@
-using System.Reflection;
-
-[assembly: AssemblyTitle("Pepperdash_Core")]
-[assembly: AssemblyCompany("")]
-[assembly: AssemblyProduct("Pepperdash_Core")]
-[assembly: AssemblyCopyright("Copyright © PepperDash 2016")]
-<<<<<<< HEAD
-[assembly: AssemblyVersion("1.0.2.*")]
-=======
-[assembly: AssemblyVersion("1.0.3.*")]
->>>>>>> e16c2cbee87c631bf84ad9634bfbc25bbec78a31
diff --git a/Pepperdash Core/Pepperdash Core/Properties/UpdateAssemblyVersion.ps1 b/Pepperdash Core/Pepperdash Core/Properties/UpdateAssemblyVersion.ps1
deleted file mode 100644
index f1c6c38..0000000
--- a/Pepperdash Core/Pepperdash Core/Properties/UpdateAssemblyVersion.ps1
+++ /dev/null
@@ -1,36 +0,0 @@
-function Update-SourceVersion
-{
- Param ([string]$Version)
- $NewVersion = ‘AssemblyVersion("‘ + $Version + ‘.*")’;
- foreach ($o in $input)
- {
- Write-output $o.FullName
- $TmpFile = $o.FullName + “.tmp”
- get-content $o.FullName |
- %{$_ -replace ‘AssemblyVersion\("(\d+\.\d+\.\d+)\.\*"\)’, $NewVersion } > $TmpFile
- move-item $TmpFile $o.FullName -force
- }
-}
-
-function Update-AllAssemblyInfoFiles ( $version )
-{
- foreach ($file in “AssemblyInfo.cs”, “AssemblyInfo.vb” )
- {
- get-childitem -recurse |? {$_.Name -eq $file} | Update-SourceVersion $version ;
- }
-}
-
-# validate arguments
-$r= [System.Text.RegularExpressions.Regex]::Match($args[0], "^\d+\.\d+\.\d+$");
-if ($r.Success)
-{
- echo "Updating Assembly Version...";
- Update-AllAssemblyInfoFiles $args[0];
-}
-else
-{
- echo ” “;
- echo “Error: Input version does not match x.y.z format!”
- echo ” “;
- echo "Unable to apply version to AssemblyInfo.cs files";
-}
diff --git a/Pepperdash Core/Pepperdash Core/WebApi/Presets/Preset.cs b/Pepperdash Core/Pepperdash Core/WebApi/Presets/Preset.cs
index 804156f..49e6427 100644
--- a/Pepperdash Core/Pepperdash Core/WebApi/Presets/Preset.cs
+++ b/Pepperdash Core/Pepperdash Core/WebApi/Presets/Preset.cs
@@ -1,10 +1,12 @@
-using System;
+extern alias Full;
+
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Crestron.SimplSharp;
-using Newtonsoft.Json;
+using Full.Newtonsoft.Json;
namespace PepperDash.Core.WebApi.Presets
diff --git a/Pepperdash Core/Pepperdash Core/WebApi/Presets/WebApiPasscodeClient.cs b/Pepperdash Core/Pepperdash Core/WebApi/Presets/WebApiPasscodeClient.cs
index e7e0efb..3f178f8 100644
--- a/Pepperdash Core/Pepperdash Core/WebApi/Presets/WebApiPasscodeClient.cs
+++ b/Pepperdash Core/Pepperdash Core/WebApi/Presets/WebApiPasscodeClient.cs
@@ -1,12 +1,14 @@
-using System;
+extern alias Full;
+
+using System;
using System.Text;
using Crestron.SimplSharp; // For Basic SIMPL# Classes
using Crestron.SimplSharp.CrestronIO;
using Crestron.SimplSharp.Net;
using Crestron.SimplSharp.Net.Http;
using Crestron.SimplSharp.Net.Https;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
+using Full.Newtonsoft.Json;
+using Full.Newtonsoft.Json.Linq;
using PepperDash.Core;
using PepperDash.Core.JsonToSimpl;
diff --git a/Pepperdash Core/Pepperdash Core/lib/net35/PepperDash_Core.clz b/Pepperdash Core/Pepperdash Core/lib/net35/PepperDash_Core.clz
new file mode 100644
index 0000000..93e2b02
Binary files /dev/null and b/Pepperdash Core/Pepperdash Core/lib/net35/PepperDash_Core.clz differ
diff --git a/Pepperdash Core/Pepperdash Core/lib/net35/PepperDash_Core.dll b/Pepperdash Core/Pepperdash Core/lib/net35/PepperDash_Core.dll
new file mode 100644
index 0000000..1b3d097
Binary files /dev/null and b/Pepperdash Core/Pepperdash Core/lib/net35/PepperDash_Core.dll differ