From 6adfd44e93c0f94f50b74c461987e114fdbdc915 Mon Sep 17 00:00:00 2001 From: BenjaminZehowlt Date: Tue, 14 Nov 2023 15:04:34 -0500 Subject: [PATCH] Initial GitHub Actions Cleanup --- .github/workflows/github_actions.yml | 88 ++++++++++++++++------------ VRCX.csproj | 2 - html/src/app.js | 4 +- 3 files changed, 52 insertions(+), 42 deletions(-) diff --git a/.github/workflows/github_actions.yml b/.github/workflows/github_actions.yml index c2cbab80e..344760a9c 100644 --- a/.github/workflows/github_actions.yml +++ b/.github/workflows/github_actions.yml @@ -1,51 +1,61 @@ name: VRCX on: - - workflow_dispatch + - push + - pull_request jobs: - build_dotnet: - runs-on: windows-latest + build_vrcx_win: + runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Setup Nuget.exe - uses: nuget/setup-nuget@v1 - - name: Restore packages - run: nuget restore VRCX.sln - - name: Setup MSBuild.exe - uses: microsoft/setup-msbuild@v1.1 - - name: Build with MSBuild - run: msbuild VRCX.sln -p:Configuration=Release -p:Platform=x64 - - uses: actions/upload-artifact@v3 + + - name: Setup .NET 8 + uses: actions/setup-dotnet@v3 with: - name: vrcx - path: bin/x64/Release - - build_node: - runs-on: ubuntu-latest - defaults: - run: - working-directory: html + dotnet-version: '8.0.x' - steps: - - uses: actions/checkout@v3 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 + - name: Setup NodeJS 18 + uses: actions/setup-node@v4 with: - node-version: ${{ matrix.node-version }} - - name: Restore dependencies - run: npm ci - - name: Lint - run: npm run lint - - name: Build - run: npm run production - - name: Fix folder structure - id: fix-folders - run: | - mkdir upload - mv dist upload/html - - uses: actions/upload-artifact@v3 + node-version: 18 + + - name: Setup NSIS + run: sudo apt update && sudo apt install -y nsis nsis-pluginapi + + - name: Restore Node Dependencies + run: cd ${{ github.workspace }}/html && npm ci && cd ${{ github.workspace }} + + #- name: JS Lint + # run: cd html && npm run lint && cd .. + + - name: Build Web UI + run: cd ${{ github.workspace }}/html && npm run production && cd ${{ github.workspace }} + + - name: Build .NET Application + run: dotnet build -p:Configuration=Release -p:Platform=x64 -p:TargetFramework=net8-windows -p:EnableWindowsTargeting=true + + - name: Copy Web UI + run: cp -r ${{ github.workspace }}/html/dist ${{ github.workspace }}/bin/x64/Release/html + + - name: Fix NSIS Permissions + run: sudo chown -R $(whoami) /usr/share/nsis/Plugins/ + + - name: Build Installer + uses: joncloud/makensis-action@v4 + with: + script-file: ${{ github.workspace }}/Installer/installer.nsi + additional-plugin-paths: ${{ github.workspace }}/Installer/Plugins + + - name: Upload Zip + uses: actions/upload-artifact@v3 + with: + name: "VRCX" + path: ${{ github.workspace }}/bin/x64/Release/* + + - name: Upload Installer + uses: actions/upload-artifact@v3 with: - name: vrcx - path: html/upload + name: "VRCX_Setup" + path: ${{ github.workspace }}/Installer/VRCX_Setup.exe \ No newline at end of file diff --git a/VRCX.csproj b/VRCX.csproj index 07821a0bf..c35ac4424 100644 --- a/VRCX.csproj +++ b/VRCX.csproj @@ -138,6 +138,4 @@ - - \ No newline at end of file diff --git a/html/src/app.js b/html/src/app.js index 9c7c96456..64e78a2b6 100644 --- a/html/src/app.js +++ b/html/src/app.js @@ -28,6 +28,7 @@ import * as localizedStrings from './localization/localizedStrings.js'; // #endregion + speechSynthesis.getVoices(); // #region | Hey look it's most of VRCX! @@ -7452,7 +7453,7 @@ speechSynthesis.getVoices(); inputPattern: /[\s\S]{1,32}/ } ) - .then(async ({ value }) => { + .then(({ value }) => { for (let userId in this.loginForm.savedCredentials) { security .decrypt( @@ -14062,6 +14063,7 @@ speechSynthesis.getVoices(); JSON.stringify(this.notificationTable.filters[0].value) ); }; + $app.data.feedTable.filter = JSON.parse( await configRepository.getString('VRCX_feedTableFilters', '[]') );