From 8b2085f997d505142dfab9b9b7ba4deb956db9d8 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Tue, 23 Aug 2022 01:53:55 -0300 Subject: [PATCH 01/28] docs: New blog entry for .NET 7 migration --- docs/blog/2021-08-26-welcome/index.md | 10 ----- docs/blog/2022-08-21-dotnet7/index.md | 63 +++++++++++++++++++++++++++ docs/blog/authors.yml | 2 +- 3 files changed, 64 insertions(+), 11 deletions(-) delete mode 100644 docs/blog/2021-08-26-welcome/index.md create mode 100644 docs/blog/2022-08-21-dotnet7/index.md diff --git a/docs/blog/2021-08-26-welcome/index.md b/docs/blog/2021-08-26-welcome/index.md deleted file mode 100644 index 604cec6b..00000000 --- a/docs/blog/2021-08-26-welcome/index.md +++ /dev/null @@ -1,10 +0,0 @@ ---- -slug: welcome -title: Welcome -authors: [gerardog] -tags: [] ---- - -Welcome. - -This site is still a work in progress. \ No newline at end of file diff --git a/docs/blog/2022-08-21-dotnet7/index.md b/docs/blog/2022-08-21-dotnet7/index.md new file mode 100644 index 00000000..6635dedf --- /dev/null +++ b/docs/blog/2022-08-21-dotnet7/index.md @@ -0,0 +1,63 @@ +--- +slug: gsudo-dotnet-7 +title: Migrating gsudo to .NET 7 +authors: [gerardog] +tags: [] +--- + + +The first gsudo versions were made in 2019, around the release of .NET Core 3. I tried to figure out how .NET Core's redistribution model worked, but it didn't worked for me. One should either redistribute the full runtime, or ask the user to manually download and install it. There was another option: to build a self-cointained app (with runtime embedded) but that increased the output size by more than 80mb! + +The alternative was to target .NET Framework v4.6. This version is bundled with every Windows 10/11. When targeting it, gsudo build output size was around 100kb. The app on v4.6 loaded faster, so targeting v4.6 seemed logical. It was small, fast, and the installation didn't required any big runtime redistribution or additional steps. + +Recently, things have changed a little with [.NET 7 Preview 3 announcement](https://devblogs.microsoft.com/dotnet/announcing-dotnet-7-preview-3/#faster-lighter-apps-with-native-aot) and NativeAOT: "Publishing your app as native AOT produces an app that is self-contained and that has been ahead-of-time (AOT) compiled to native code. Native AOT apps start up very quickly and use less memory. Users of the application can run it on a machine that doesn't have the .NET runtime installed." + +I'm almost sold! Let's try it out... *(sounds of frenetic typing)*... Ok, that was [18 files changed](https://github.com/gerardog/gsudo/compare/971ea97c...7c0c1b71). Now I have a multi-target project that can compile for v4.6 or v7. Not bad. + +But not everyone's cup of tea: NativeAOT builds for each specific platform, so instead of having one AnyCPU build, now I have two (x64 and x86). But also, NativeAOT is only supported on x64. The closest for x86 is a self-contained build with Ready2Run. + +Let's do some test the performance. So first let´s build for each platform: + +``` powershell +# Build .NET Framework v4.6 +msbuild /t:Restore /p:RestorePackagesConfig=true src\gsudo.sln /v:Minimal /p:TargetFrameworkVersion=v4.6 +msbuild /t:Rebuild /p:Configuration=Release src\gsudo\gsudo.csproj /v:Minimal /p:WarningLevel=0 /p:TargetFrameworkVersion=v4.6 +# Build .NET 7.0 x64 build with NativeAOT +dotnet clean .\src\gsudo\gsudo.csproj -f net7.0 | Out-null +dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x64 --sc -p:PublishAot=true -p:IlcOptimizationPreference=Size -v minimal -p:WarningLevel=0 +# Build .NET 7.0 x86 build with Ready2Run +dotnet clean .\src\gsudo\gsudo.csproj -f net7.0 -r win-x86 | Out-null +dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x86 --sc -p:PublishReadyToRun=true -p:PublishSingleFile=true -v minimal -p:WarningLevel=0 +``` + +Now let´s meassure 100 elevations using a preexisting credentials cache. I am using `gsudo -d` to force an elevation using `cmd.exe`, which loads much faster and predictable than `Powershell`. Then I repeated the tests with each different build. + +``` powershell +$gsudo="C:\git\gsudo\src\gsudo\bin\net46\gsudo.exe" +& $gsudo cache on | out-null # start a cache session. +& $gsudo -d dir | out-null # test the cache session. +Measure-Command { 1..100 | % { & $gsudo -d dir} } | select -Property TotalSeconds | Format-List +& $gsudo -k | out-null # close cache. +``` + +The first results were absurd. I found out Windows Defender takes extra time to verify unsigned apps in the cloud. So I disabled Defender and started over. + +| | v1.3.0 (Net 4.6 + ilmerge + CodeSigned) | Latest (Net 4.6 unsigned) | Net 7.0 x64 NativeAOT (unsigned) | Net 7.0 x86 Ready2Run (unsigned) | +| ------------------------------- | --------------------------------------- | ------------------------- | -------------------------------- | -------------------------------- | +| Size | 180.5 KB | 208.5 KB | 6.17 MB | 16.89 MB | +| Time to elevate 100 times (sum) | 12.75 s | 12.62 s | 7.83 s | 10.94 s | +| Performance improvement | (baseline) | 1.04% | 38.62% | 14.18% | + +Wow! An improvement of 38.62% is significant enough to ignore the fact that the file size has increased 6 MB, or almost 30 times. + +## Should gsudo target .NET 7.0? + +The problem is that the installer should provide for all platforms, and so far I´ve only focused on x64. What options do I have? + +- I could fall back to Net 4.6 (targeting AnyCPU) for the remaining platforms. The down-side would be different prerequisites for each scenario. But the installer would only grow 6mb. +- Or include x86 Net 7.0 Read2Run version. It´s faster, but takes 16mb. The setup including both would take 23 MB (actually 10mb when compressed)! + +## Current situation + +Right now my code-signing certificate is expired. Once I´ve got a new certificate, I will be making a test release. I will update this post then. + diff --git a/docs/blog/authors.yml b/docs/blog/authors.yml index 2277c7ed..09e32244 100644 --- a/docs/blog/authors.yml +++ b/docs/blog/authors.yml @@ -1,5 +1,5 @@ gerardog: name: Gerardo Grignoli - title: Maintainer of gsudo +# title: gsudo Creator url: https://github.com/gerardog image_url: https://avatars.githubusercontent.com/u/3901474?s=96&v=4 From 2be1901dad9e2b5e3ce8a45f371ddb6ae0e558a0 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 02:05:52 -0300 Subject: [PATCH 02/28] Feature.NetCore: Migration to dotnet 7.0 (#157) * feat(net-core): Migration to Net 7.0 + NativeAOT - Convert project file to SDK style - Replaced BinaryFormatter with System.Text.Json source generator - feat(net-core): Multitarget net7.0 and net4.6 - feat(build): GitHub Actions build - feat(net-core): Updated .msi installer to install x86 or x64 version upon processor platform. - docs: New blog entry for .NET 7 migration - chore: Fixed Link to Security Considerations in the help - chore(net-core): Use newer NamedPipeServerStreamAcl from NET 6.0 - fix(cache): Fix `cache on` finishing before the cache is available. Fixes #144 - feat(build): Automated Chocolatey releases - feat(net core): +semver: feature --- .github/CODEOWNERS | 2 + .github/workflows/build.yml | 173 +++ .github/workflows/{deploy.yml => docs.yml} | 4 +- .gitignore | 2 + appveyor.yml | 61 +- build/00-prerequisites.ps1 | 6 + build/01-build.ps1 | 19 + build/02-test.ps1 | 46 + build/03-sign.ps1 | 55 + build/04-release-GitHub.ps1 | 33 + build/05-release-Chocolatey.ps1 | 63 + build/06-release-Scoop.ps1 | 1 + build/Build.bat | 53 +- .../{gsudo => }/gsudo.nuspec.template | 6 +- .../gsudo/tools/chocolateyinstall.ps1 | 21 +- build/InstallTools.cmd | 3 +- docs/blog/2021-08-26-welcome/index.md | 10 - docs/blog/2022-08-21-dotnet7/index.md | 63 + docs/blog/authors.yml | 2 +- package.json | 8 +- src/.gitattributes | 2 + src/KeyPressTester/KeyPressTester.csproj | 53 +- src/gsudo.Installer/Product.wxs | 44 +- src/gsudo.Installer/gsudomsi.wixproj | 2 +- src/gsudo.Tests/CmdTests.cs | 2 +- src/gsudo.Tests/gsudo.Tests.csproj | 79 +- src/gsudo.Tests/packages.config | 5 - .../Invoke-gsudo.Tests.ps1 | 4 + .../gsudo.Tests.ps1 | 3 +- .../Invoke-gsudo.ps1 | 0 src/{gsudo.extras => gsudo.Wrappers}/gsudo | 0 .../gsudoModule.psd1 | 0 .../gsudoModule.psm1 | 0 src/gsudo.extras/.gitattributes | 2 - src/gsudo.sln | 8 +- src/gsudo/Commands/CacheCommand.cs | 7 +- src/gsudo/Commands/HelpCommand.cs | 9 +- src/gsudo/Commands/RunCommand.cs | 12 +- src/gsudo/Commands/ServiceCommand.cs | 11 +- src/gsudo/CredentialsCacheLifetimeManager.cs | 17 +- src/gsudo/ElevationRequest.cs | 7 + src/gsudo/Helpers/ProcessHelper.cs | 5 +- src/gsudo/Helpers/SymbolicLinkSupport.cs | 5 +- src/gsudo/Native/ProcessApi.cs | 2 +- src/gsudo/Rpc/Connection.cs | 11 + src/gsudo/Rpc/NamedPipeClient.cs | 13 +- src/gsudo/Rpc/NamedPipeServer.cs | 16 +- src/gsudo/Tokens/TokenProvider.cs | 21 +- src/gsudo/gsudo.csproj | 31 +- yarn.lock | 1110 ++++++++++++----- 50 files changed, 1521 insertions(+), 591 deletions(-) create mode 100644 .github/CODEOWNERS create mode 100644 .github/workflows/build.yml rename .github/workflows/{deploy.yml => docs.yml} (95%) create mode 100644 build/00-prerequisites.ps1 create mode 100644 build/01-build.ps1 create mode 100644 build/02-test.ps1 create mode 100644 build/03-sign.ps1 create mode 100644 build/04-release-GitHub.ps1 create mode 100644 build/05-release-Chocolatey.ps1 create mode 100644 build/06-release-Scoop.ps1 rename build/Chocolatey/{gsudo => }/gsudo.nuspec.template (96%) delete mode 100644 docs/blog/2021-08-26-welcome/index.md create mode 100644 docs/blog/2022-08-21-dotnet7/index.md create mode 100644 src/.gitattributes delete mode 100644 src/gsudo.Tests/packages.config rename src/{gsudo.extras => gsudo.Wrappers.Tests}/Invoke-gsudo.Tests.ps1 (96%) rename src/{gsudo.extras => gsudo.Wrappers.Tests}/gsudo.Tests.ps1 (81%) rename src/{gsudo.extras => gsudo.Wrappers}/Invoke-gsudo.ps1 (100%) rename src/{gsudo.extras => gsudo.Wrappers}/gsudo (100%) rename src/{gsudo.extras => gsudo.Wrappers}/gsudoModule.psd1 (100%) rename src/{gsudo.extras => gsudo.Wrappers}/gsudoModule.psm1 (100%) delete mode 100644 src/gsudo.extras/.gitattributes diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 00000000..661db6cd --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1,2 @@ +/.github/ @gerardog +/build/ @gerardog \ No newline at end of file diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 00000000..9609b4c5 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,173 @@ +name: Build, Test & Release + +on: + push: + branches: + - Feature.NetCore + - master + +jobs: + test: + name: Test + runs-on: windows-latest + permissions: + id-token: write + contents: read + checks: write + steps: + - uses: actions/setup-dotnet@v2 + with: + dotnet-version: '7.0.x' + include-prerelease: true + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Run Tests + run: ./build/02-test.ps1 + - name: Test Report DotNet + uses: dorny/test-reporter@v1 + if: success() || failure() # run this step even if previous step failed + with: + name: TestsResults (dotnet) + path: "**/TestResults*.trx" + reporter: dotnet-trx + fail-on-error: false + - name: Test Report PowerShell v5 + uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs + if: success() || failure() # run this step even if previous step failed + with: + test_results_path: ./testResults_PS5.xml + report_name: TestResults PowerShell v5.x + report_title: PowerShell v5 Tests + github_token: ${{ secrets.GITHUB_TOKEN }} + + - name: Test Report PowerShell v7 + uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs + if: success() || failure() # run this step even if previous step failed + with: + test_results_path: ./testResults_PS7.xml + report_name: TestResults PowerShell Core (v7.x) + report_title: PowerShell v7 Tests + github_token: ${{ secrets.GITHUB_TOKEN }} +# - uses: OrbitalOwen/desktop-screenshot-action@0.1 +# if: always() +# with: +# file-name: 'desktop.jpg' + + build: + name: Build + runs-on: windows-latest + steps: + - uses: actions/setup-dotnet@v2 + with: + dotnet-version: '7.0.x' + include-prerelease: true + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Install dependencies + run: choco install GitVersion.Portable ilmerge --confirm --no-progress + - name: Update project version + run: gitversion /l console /output buildserver /updateAssemblyInfo /verbosity minimal + - name: Get project version + id: getversion + run: | + echo "::set-output name=version::$(gitversion /showvariable LegacySemVer)" + echo "::set-output name=version_MajorMinorPatch::$(gitversion /showvariable MajorMinorPatch)" + - name: Build + run: ./build/01-build.ps1 + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: Binaries + path: ./artifacts + outputs: + version: ${{ steps.getversion.outputs.version }} + version_MajorMinorPatch: ${{ steps.getversion.outputs.version_MajorMinorPatch }} + + release: + name: Sign & Release to GitHub + #if: github.ref == 'refs/heads/master' && github.repository == 'gerardog/gsudo' + if: github.repository == 'gerardog/gsudo' + runs-on: windows-latest + needs: [build, test] + #needs: build + environment: + name: release-github + env: + cert_path: "C:\\secret\\cert.pfx" + cert_key: ${{ secrets.P_F_X_Key }} + version: ${{ needs.build.outputs.version }} + version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} + permissions: + contents: write + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: actions/download-artifact@v3 + with: + name: Binaries + path: ./artifacts + - name: Decode certificate + # First encode and upload as environment secret using: [convert]::ToBase64String((Get-Content .\code_signing.pfx -AsByteStream)) + run: | + $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.p_f_x }}") + $_ = mkdir (split-path -parent $env:cert_path) -ErrorAction Ignore + [IO.File]::WriteAllBytes("$env:cert_path", $pfx_cert_byte) + - name: Code Sign + run: ./build/03-sign.ps1 + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: Binaries + path: ./artifacts + - name: Package for GitHub Release + run: ./build/04-release-GitHub.ps1 + - name: Remove the pfx + run: Remove-Item -path $env:cert_path + - name: Upload installer artifacts + uses: actions/upload-artifact@v3 + with: + name: Installer + path: ./artifacts/gsudoSetup.msi + - name: Create Release + uses: ncipollo/release-action@v1.10.0 + with: + artifacts: "artifacts/*.*" + token: ${{ secrets.GITHUB_TOKEN }} + draft: true + generateReleaseNotes: true + name: gsudo v${{env.version}} + tag: v${{env.version}} + commit: ${{env.GITHUB_SHA}} + + chocolatey: + name: Pack & Release to Chocolatey + #if: github.ref == 'refs/heads/master' && github.repository == 'gerardog/gsudo' + if: github.repository == 'gerardog/gsudo' + runs-on: windows-latest + #needs: [build, test] + needs: [build, release] + environment: + name: release-chocolatey + env: + version: ${{ needs.build.outputs.version }} + version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: actions/download-artifact@v3 + with: + name: Binaries + path: ./artifacts + - name: Import Chocolatey Api Key + run: choco apikey --key ${{ secrets.CHOCOLATEY_APIKEY }} --source https://push.chocolatey.org/ + - name: Build Package for Chocolatey & Upload + run: ./build/05-release-Chocolatey.ps1 + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: Binaries + path: ./artifacts diff --git a/.github/workflows/deploy.yml b/.github/workflows/docs.yml similarity index 95% rename from .github/workflows/deploy.yml rename to .github/workflows/docs.yml index 9528400c..c9853608 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/docs.yml @@ -1,4 +1,4 @@ -name: Deploy to GitHub Pages +name: Build Documentation Website on: push: @@ -10,7 +10,7 @@ on: jobs: deploy: - name: Deploy to GitHub Pages + name: Deploy Docs to GitHub Pages runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 diff --git a/.gitignore b/.gitignore index 82fbbccb..3225a113 100644 --- a/.gitignore +++ b/.gitignore @@ -23,6 +23,8 @@ bld/ [Bb]in/ [Oo]bj/ [Ll]og/ +artifacts/ +TestResult* # Visual Studio 2015/2017 cache/options directory .vs/ diff --git a/appveyor.yml b/appveyor.yml index a4421610..0bfc4dc6 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -1,23 +1,48 @@ -image: Visual Studio 2019 +image: Visual Studio 2022 +clone_folder: c:\git\gsudo +platform: Any CPU +configuration: Release -install: - - choco install gitversion.portable -pre -y - - ps: Install-Module Pester -Force -SkipPublisherCheck -Scope CurrentUser +cache: + - src\gsudo\packages -> **\packages.config # preserve "packages" directory in the root of build folder but will reset it if packages.config is modified + - '%LocalAppData%\NuGet\Cache' # NuGet < v3 + - '%LocalAppData%\NuGet\v3-cache' # NuGet v3 + init: - git config --global core.autocrlf true - powershell -noprofile -command "Install-Module PSReadLine -Force -SkipPublisherCheck -AllowPrerelease" +install: + - choco install dotnet-7.0-sdk --pre + - choco install gitversion.portable -y + - ps: Install-Module Pester -Force -SkipPublisherCheck -Scope CurrentUser + before_build: - - nuget restore src\gsudo.sln - - ps: gitversion /l console /output buildserver /updateAssemblyInfo + - ps: gitversion /l console /output buildserver /updateAssemblyInfo /verbosity minimal + +build_script: + - dotnet restore src\gsudo.sln + - dotnet build src\gsudo.sln -c Release + # net 7.0 x64 build with NativeAOT + - dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x64 --sc -p:PublishAot=true -p:TrimmerDefaultAction=link -p:IlcOptimizationPreference=Size + # net 7.0 x86 does not support NativeAOT + - dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x86 --sc -p:PublishReadyToRun=true -p:PublishSingleFile=true + # net framework 4.6 AnyCpu + - dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net46 -p:Platform=x64 after_build: - - 7z a gsudo.%CONFIGURATION%.%APPVEYOR_BUILD_VERSION%.Unsigned.zip %APPVEYOR_BUILD_FOLDER%\src\gsudo\bin\*.* %APPVEYOR_BUILD_FOLDER%\src\gsudo.extras\gsudoModule.* %APPVEYOR_BUILD_FOLDER%\src\gsudo.extras\Invoke-gsudo.ps1 - - appveyor PushArtifact gsudo.%CONFIGURATION%.%APPVEYOR_BUILD_VERSION%.Unsigned.zip + - 7z a gsudo.net70.x64.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip .\src\gsudo\bin\net7.0\win-x64\publish\*.* .\src\gsudo.Wrappers\gsudoModule.* .\src\gsudo.Wrappers\Invoke-gsudo.ps1 + - appveyor PushArtifact gsudo.net70.x64.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip + + - 7z a gsudo.net70.x86.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip .\src\gsudo\bin\net7.0\win-x86\publish\*.* .\src\gsudo.Wrappers\gsudoModule.* .\src\gsudo.Wrappers\Invoke-gsudo.ps1 + - appveyor PushArtifact gsudo.net70.x86.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip + - 7z a gsudo.net46.AnyCpu.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip .\src\gsudo\bin\net46\publish\*.* .\src\gsudo.Wrappers\gsudoModule.* .\src\gsudo.Wrappers\Invoke-gsudo.ps1 + - appveyor PushArtifact gsudo.net46.AnyCpu.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip + test_script: - - ps: $Env:Path+=";$($Env:APPVEYOR_BUILD_FOLDER)/src/gsudo/bin;"; - - vstest.console /logger:Appveyor %APPVEYOR_BUILD_FOLDER%\src\gsudo.Tests\bin\%CONFIGURATION%\gsudo.Tests.dll + - ps: $Env:Path+=";$($Env:APPVEYOR_BUILD_FOLDER)/src/gsudo/bin/net7.0/win-x64/publish;"; + - vstest.console /logger:Appveyor %APPVEYOR_BUILD_FOLDER%\src\gsudo.Tests\bin\%CONFIGURATION%\net7.0\gsudo.Tests.dll - powershell -c Invoke-Pester -EnableExit -OutputFile Powershell5Tests.xml -OutputFormat NUnitXml - pwsh -c Invoke-Pester -EnableExit -OutputFile PowershellCoreTests.xml -OutputFormat NUnitXml - ps: | @@ -25,18 +50,4 @@ test_script: (New-Object 'System.Net.WebClient').UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path "PowershellCoreTests.xml")) on_finish: - - ps: if($env:APPVEYOR_RDP_ENABLED -eq 'TRUE') { $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1')) } - -clone_folder: c:\git\gsudo -platform: Any CPU -configuration: Release - -build: - parallel: true - project: src\gsudo.sln - verbosity: minimal - -cache: - - src\packages -> **\packages.config # preserve "packages" directory in the root of build folder but will reset it if packages.config is modified - - '%LocalAppData%\NuGet\Cache' # NuGet < v3 - - '%LocalAppData%\NuGet\v3-cache' # NuGet v3 + - ps: if($env:APPVEYOR_RDP_ENABLED -eq 'TRUE') { $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1')) } \ No newline at end of file diff --git a/build/00-prerequisites.ps1 b/build/00-prerequisites.ps1 new file mode 100644 index 00000000..bd4bffef --- /dev/null +++ b/build/00-prerequisites.ps1 @@ -0,0 +1,6 @@ +choco install ilmerge +choco install GitVersion.Portable +choco install wixtoolset +choco install hub +choco install dotnet-7.0-sdk --pre + diff --git a/build/01-build.ps1 b/build/01-build.ps1 new file mode 100644 index 00000000..9a148162 --- /dev/null +++ b/build/01-build.ps1 @@ -0,0 +1,19 @@ +pushd $PSScriptRoot\.. +dotnet publish .\src\gsudo\gsudo.csproj -c Release -o .\artifacts\net46-AnyCpu\unmerged -f net46 -p:Platform=AnyCpu -v minimal -p:WarningLevel=0 || $(exit $LASTEXITCODE) +#dotnet publish .\src\gsudo\gsudo.csproj -c Release -o .\artifacts\net70-arm64 -f net7.0 -r win-arm64 --sc -p:PublishReadyToRun=true -p:PublishSingleFile=true -v minimal -p:WarningLevel=0 || $(exit $LASTEXITCODE) +dotnet publish .\src\gsudo\gsudo.csproj -c Release -o .\artifacts\x86 -f net7.0 -r win-x86 --sc -p:PublishReadyToRun=true -p:PublishSingleFile=true -v minimal -p:WarningLevel=0 || $(exit $LASTEXITCODE) +dotnet publish .\src\gsudo\gsudo.csproj -c Release -o .\artifacts\x64 -f net7.0 -r win-x64 --sc -p:PublishAot=true -p:IlcOptimizationPreference=Size || $(exit $LASTEXITCODE) + +ilmerge .\artifacts\net46-AnyCpu\unmerged\gsudo.exe .\artifacts\net46-AnyCpu\unmerged\*.dll /out:.\artifacts\net46-AnyCpu\gsudo.exe /target:exe /targetplatform:v4,"C:\Windows\Microsoft.NET\Framework\v4.0.30319" /ndebug /wildcards || $(exit $LASTEXITCODE) + +if ($?) { + rm artifacts\net46-AnyCpu\unmerged -Recurse + echo "ilmerge -> artifacts\net46-AnyCpu\" +} + +cp .\src\gsudo.Wrappers\* .\artifacts\net46-AnyCpu +#cp .\src\gsudo.Wrappers\* .\artifacts\net70-arm64 +cp .\src\gsudo.Wrappers\* .\artifacts\x86 +cp .\src\gsudo.Wrappers\* .\artifacts\x64 + +popd \ No newline at end of file diff --git a/build/02-test.ps1 b/build/02-test.ps1 new file mode 100644 index 00000000..e31775ed --- /dev/null +++ b/build/02-test.ps1 @@ -0,0 +1,46 @@ +function Test-IsAdmin { + return (New-Object Security.Principal.WindowsPrincipal([Security.Principal.WindowsIdentity]::GetCurrent())).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator) +} + +if (! (Test-IsAdmin)) { + throw "Must be admin to run tests" +} + +$failure=$false + +pushd $PSScriptRoot\.. + +dotnet test .\src\gsudo.sln --logger "trx;LogFileName=$((gi .).FullName)\TestResults.trx" --logger:"console;verbosity=normal" -v quiet -p:WarningLevel=0 +if (! $?) { $failure = $true } + +$env:path=(Get-Item .\src\gsudo\bin\net7.0\).FullName+";"+$env:path + +gsudo -k > $null + +$script = { + Install-Module Pester -Force -SkipPublisherCheck + Import-Module Pester + + $configuration = New-PesterConfiguration; + $configuration.Run.Path = "src" + $configuration.TestResult.Enabled = $true + $configuration.TestResult.OutputPath = "TestResults_PS$($PSVersionTable.PSVersion.Major).xml" + $configuration.TestResult.OutputFormat = "NUnitXml" +# $configuration.Should.ErrorAction = 'Continue' +# $configuration.CodeCoverage.Enabled = $true + + Invoke-Pester -Configuration $configuration +} + + +Write-Verbose -verbose "Running PowerShell Tests on Windows PowerShell (v5.x)" +powershell $script +if (! $?) { $failure = $true } + +Write-Verbose -verbose "Running PowerShell Tests on Pwsh Core (v7.x)" +pwsh $script +if (! $?) { $failure = $true } + +.\src\gsudo\bin\net7.0\gsudo.exe -k + +if ($failure) { exit 1 } diff --git a/build/03-sign.ps1 b/build/03-sign.ps1 new file mode 100644 index 00000000..971f7511 --- /dev/null +++ b/build/03-sign.ps1 @@ -0,0 +1,55 @@ +pushd $PSScriptRoot\.. + +# Find SignTool.exe +if ($env:SignToolExe) { + # From env var. +} elseif (get-command signtool.exe -ErrorAction Ignore) { + # From path. + $env:SignToolExe = (gcm signtool.exe).Path +} elseif ($i = get-item "C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x64\signtool.exe" -ErrorAction Ignore) { + $env:SignToolExe = $i.Fullname +} elseif ($i = get-item "C:\Program Files (x86)\Microsoft SDKs\ClickOnce\SignTool\signtool.exe" -ErrorAction Ignore) { + $env:SignToolExe = $i.Fullname +} else { + Write-Output "SignTool Locations:" + (Get-ChildItem -Path ${env:ProgramFiles(x86)} -Filter signtool.exe -Recurse -ErrorAction SilentlyContinue -Force).FullName + popd + throw "Unable to find SignTool.exe. Set env:SignToolExe to it's location." +} + +if (!$env:cert_path) { throw 'Missing $env:cert_path variable'} +if (!$env:cert_key) { throw 'Missing $env:cert_key variable'} + +if (!(gi "$env:cert_path")) { throw 'Missing $env:cert_path file'} + +"Using Signtool.exe from: $env:SignToolExe" +"Using Certificate from: $env:cert_path" + +$files = @( +"artifacts\x64\*.exe", +"artifacts\x64\*.p*1" +"artifacts\x86\*.exe", +"artifacts\x86\*.p*1", +#"artifacts\arm64\*.exe", +#"artifacts\arm64\*.p*1", +"artifacts\net46-AnyCpu\*.exe", +"artifacts\net46-AnyCpu\*.p*1" +) -join " " + +# Accept $args override. +if ($args) +{ + $files = $args -join " " +} + +$cmd = "& ""$env:SignToolExe"" sign /f ""$env:cert_path"" /p $env:cert_key /fd SHA256 /t http://timestamp.digicert.com $files" + +echo "`nInvoking SignTool.exe:`n" +iex $cmd + +if (! $?) { +popd +exit 1 +} + +popd \ No newline at end of file diff --git a/build/04-release-GitHub.ps1 b/build/04-release-GitHub.ps1 new file mode 100644 index 00000000..2d881f9f --- /dev/null +++ b/build/04-release-GitHub.ps1 @@ -0,0 +1,33 @@ +pushd $PSScriptRoot\.. + +if ($env:version) { + "- Getting version from env:version" + $version = $env:version + $version_MajorMinorPatch=$env:version_MajorMinorPatch +} else { + "- Getting version using GitVersion" + $version = $(gitversion /showvariable LegacySemVer) + $version_MajorMinorPatch=$(gitversion /showvariable MajorMinorPatch) +} +"- Using version number v$version / v$version_MajorMinorPatch" + +Get-ChildItem .\artifacts\ -File | Remove-Item + +"- Packaging v$version" +Compress-Archive -Path ./artifacts/x86,./artifacts/x64,./artifacts/net46-AnyCpu -DestinationPath "artifacts/gsudo.v$($version).zip" -force -CompressionLevel Optimal +(Get-FileHash artifacts\gsudo.v$($version).zip).hash > artifacts\gsudo.v$($version).zip.sha256 + +$msbuild = &"${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -latest -prerelease -products * -requires Microsoft.Component.MSBuild -find MSBuild\**\Bin\MSBuild.exe + +$outdir = "$PSScriptRoot\..\artifacts" + +"- Building Installer" +(gc src\gsudo.Installer\Constants.Template.wxi) -replace '#VERSION#', "$version" | Out-File -encoding UTF8 src\gsudo.Installer\Constants.wxi +& $msbuild /t:Rebuild /p:Configuration=Release src\gsudo.Installer.sln /v:Minimal /p:OutputPath=$outdir || (popd && exit 1) +rm .\artifacts\gsudoSetup.wixpdb + +"- Code Signing Installer" +& $PSScriptRoot\03-sign.ps1 artifacts\gsudoSetup.msi || (popd && exit 1) +(Get-FileHash artifacts\gsudoSetup.msi).hash > artifacts\gsudoSetup.msi.sha256 + +popd \ No newline at end of file diff --git a/build/05-release-Chocolatey.ps1 b/build/05-release-Chocolatey.ps1 new file mode 100644 index 00000000..09793bdf --- /dev/null +++ b/build/05-release-Chocolatey.ps1 @@ -0,0 +1,63 @@ +function Test-IsAdmin { + return (New-Object Security.Principal.WindowsPrincipal([Security.Principal.WindowsIdentity]::GetCurrent())).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator) +} + +if (! (Test-IsAdmin)) { + throw "Must be admin to properly test generated package" +} + +Get-Item .\artifacts\x64\gsudo.exe > $null || $(throw "Missing binaries/artifacts") + +pushd $PSScriptRoot\.. + +if ($env:version) { + "- Getting version from env:version" + $version = $env:version + $version_MajorMinorPatch=$env:version_MajorMinorPatch +} else { + "- Getting version using GitVersion" + $version = $(gitversion /showvariable LegacySemVer) + $version_MajorMinorPatch=$(gitversion /showvariable MajorMinorPatch) +} +"- Using version number v$version / v$version_MajorMinorPatch" + +"- Cleaning Choco template folder" +git clean .\Build\Chocolatey\gsudo -xf + +"- Adding Artifacts" +cp artifacts\x?? .\Build\Chocolatey\gsudo\tools -Recurse -Force -Exclude *.pdb +Get-ChildItem .\build\Chocolatey\gsudo\tools\ -Recurse -Filter *.exe | % { ni "$($_.FullName).ignore" } > $null + +# Generate gsudo.nuspec +(Get-Content Build\Chocolatey\gsudo.nuspec.template) -replace '#VERSION#', "$version" | Out-File -encoding UTF8 .\Build\Chocolatey\gsudo\gsudo.nuspec +# Generate Tools\VERIFICATION.txt +Get-Content .\Build\Chocolatey\verification.txt.template | Out-File -encoding UTF8 .\Build\Chocolatey\gsudo\Tools\VERIFICATION.txt + +"- Calculating Hashes " + +@" +--- +Version Hashes for v$version + +"@ >> .\Build\Chocolatey\gsudo\Tools\VERIFICATION.txt +Get-FileHash .\Build\Chocolatey\gsudo\Tools\*\*.* | Out-String -Width 200 | %{$_.Replace("$((gi Build\Chocolatey\gsudo).FullName)\", "",'OrdinalIgnoreCase')} >> .\Build\Chocolatey\gsudo\Tools\VERIFICATION.txt +Get-childitem *.bak -Recurse | Remove-Item + +"- Packing v$version to chocolatey" +mkdir Artifacts\Chocolatey -Force > $null +& choco pack .\Build\Chocolatey\gsudo\gsudo.nuspec -outdir="$((get-item Artifacts\Chocolatey).FullName)" || $(throw "Choco pack failed.") + +"- Testing package" +if (choco list -lo | Where-object { $_.StartsWith("gsudo") }) { + choco upgrade gsudo --failonstderr -s Artifacts\Chocolatey -f -pre --confirm || $(throw "Choco upgrade failed.") +} else { + choco install gsudo --failonstderr -s Artifacts\Chocolatey -f -pre --confirm || $(throw "Choco install failed.") +} + +if($(choco apikey).Count -lt 2) { throw "Missing Chocolatey ApiKey. Use: choco apikey -k -s https://push.chocolatey.org/" } + +"`n- Uploading v$version to chocolatey" +choco push artifacts\Chocolatey\gsudo.$($version).nupkg || $(throw "Choco push failed.") + +"- Success" +popd \ No newline at end of file diff --git a/build/06-release-Scoop.ps1 b/build/06-release-Scoop.ps1 new file mode 100644 index 00000000..8d1c8b69 --- /dev/null +++ b/build/06-release-Scoop.ps1 @@ -0,0 +1 @@ + diff --git a/build/Build.bat b/build/Build.bat index d54c41ea..24b3aa17 100644 --- a/build/Build.bat +++ b/build/Build.bat @@ -11,7 +11,7 @@ gitversion /showvariable MajorMinorPatch > "%temp%\version.tmp" SET /P MajorMinorPatch= < "%temp%\version.tmp" set REPO_ROOT_FOLDER=%cd% -set BIN_FOLDER=%cd%\src\gsudo\bin +set BIN_FOLDER=%cd%\src\gsudo\bin\ set OUTPUT_FOLDER=%REPO_ROOT_FOLDER%\Build\Releases\%version% popd @@ -27,29 +27,45 @@ echo Building with version number v%version% :: Cleanup del %BIN_FOLDER%\*.* /q rd %BIN_FOLDER%\package /q /s 2>nul + mkdir %BIN_FOLDER%\package 2> nul +mkdir %BIN_FOLDER%\package\x64 2> nul +mkdir %BIN_FOLDER%\package\x86 2> nul +mkdir %BIN_FOLDER%\package\net46-AnyCpu 2> nul + IF EXIST %OUTPUT_FOLDER% RD %OUTPUT_FOLDER% /q /s mkdir %OUTPUT_FOLDER% 2> nul -mkdir %OUTPUT_FOLDER%\bin 2> nul :: Build -%msbuild% /t:restore /p:RestorePackagesConfig=true %REPO_ROOT_FOLDER%\src\gsudo.sln /v:Minimal -%msbuild% /t:Rebuild /p:Configuration=Release %REPO_ROOT_FOLDER%\src\gsudo.sln /p:Version=%version% /v:Minimal /p:WarningLevel=0 +echo Build net7.0 win-x64 +cmd /c rd .\src\gsudo\obj /s /q +dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x64 --sc -p:PublishAot=true -p:IlcOptimizationPreference=Size -v minimal -p:WarningLevel=0 + +echo Build net7.0 win-x86 +cmd /c rd .\src\gsudo\obj /s /q +dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x86 --sc -p:PublishReadyToRun=true -p:PublishSingleFile=true + +echo Build net46 AnyCpu +cmd /c rd .\src\gsudo\obj /s /q +dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net46 -p:Platform=AnyCpu if errorlevel 1 goto badend echo Build Succeded. -echo Running ILMerge -pushd %BIN_FOLDER% - -ilmerge gsudo.exe System.Security.Claims.dll System.Security.Principal.Windows.dll /out:%BIN_FOLDER%\package\gsudo.exe /target:exe /targetplatform:v4,"C:\Windows\Microsoft.NET\Framework\v4.0.30319" /ndebug +echo Running ILMerge for net46 +pushd %BIN_FOLDER%\net46\publish +ilmerge gsudo.exe System.Security.Claims.dll System.Security.Principal.Windows.dll /out:%BIN_FOLDER%\package\net46-AnyCpu\gsudo.exe /target:exe /targetplatform:v4,"C:\Windows\Microsoft.NET\Framework\v4.0.30319" /ndebug if errorlevel 1 echo ILMerge Failed - Try: choco install ilmerge & pause & popd & goto badend popd -copy %REPO_ROOT_FOLDER%\src\gsudo.extras\gsudo %BIN_FOLDER%\package\ -copy %REPO_ROOT_FOLDER%\src\gsudo.extras\gsudoModule.ps?1 %BIN_FOLDER%\package\ -copy %REPO_ROOT_FOLDER%\src\gsudo.extras\invoke-gsudo.ps1 %BIN_FOLDER%\package\ + +copy %REPO_ROOT_FOLDER%\src\gsudo.Wrappers\*.* %BIN_FOLDER%\package\x64 +copy %REPO_ROOT_FOLDER%\src\gsudo.Wrappers\*.* %BIN_FOLDER%\package\x86 +copy %REPO_ROOT_FOLDER%\src\gsudo.Wrappers\*.* %BIN_FOLDER%\package\net46-AnyCpu + +copy %BIN_FOLDER%\net7.0\win-x64\publish\gsudo.exe %BIN_FOLDER%\package\x64 +copy %BIN_FOLDER%\net7.0\win-x86\publish\gsudo.exe %BIN_FOLDER%\package\x86 :: Code Sign if 'skipsign'=='%1' goto skipsign @@ -57,7 +73,9 @@ if 'skipsign'=='%1' goto skipsign echo Signing exe. pushd %BIN_FOLDER% -%SignToolPath%signtool.exe sign /n "Open Source Developer, Gerardo Grignoli" /fd SHA256 /tr "http://time.certum.pl" %BIN_FOLDER%\package\gsudo.exe %BIN_FOLDER%\package\gsudoModule.psm1 %BIN_FOLDER%\package\gsudoModule.psd1 %BIN_FOLDER%\package\invoke-gsudo.ps1 +::%SignToolPath%signtool.exe sign /n "Open Source Developer, Gerardo Grignoli" /fd SHA256 /tr "http://time.certum.pl" package\x64\*.* package\x86\*.* package\net46-AnyCpu\*.* +%SignToolPath%signtool.exe sign /f C:\git\code_signing.pfx /p 1234 /fd SHA256 /t http://timestamp.digicert.com package\x64\*.exe package\x64\*.p* package\x86\*.exe package\x86\*.p* package\net46-AnyCpu\*.exe package\net46-AnyCpu\*.p* + if errorlevel 1 echo Sign Failed & pause & popd & goto badend echo Sign successfull @@ -68,10 +86,12 @@ echo Building Installer %msbuild% /t:Restore,Rebuild /p:Configuration=Release %REPO_ROOT_FOLDER%\src\gsudo.Installer.sln /v:Minimal if errorlevel 1 echo Buid Failed & pause & popd & goto badend + echo Signing Installer if 'skipsign'=='%1' goto skipbuild -%SignToolPath%signtool.exe sign /n "Open Source Developer, Gerardo Grignoli" /fd SHA256 /tr "http://time.certum.pl" %REPO_ROOT_FOLDER%\src\gsudo.Installer\bin\Release\gsudomsi.msi +::%SignToolPath%signtool.exe sign /n "Open Source Developer, Gerardo Grignoli" /fd SHA256 /t http://timestamp.digicert.com %REPO_ROOT_FOLDER%\src\gsudo.Installer\bin\Release\gsudomsi.msi +%SignToolPath%signtool.exe sign /f C:\git\code_signing.pfx /p 1234 /fd SHA256 /t http://timestamp.digicert.com %REPO_ROOT_FOLDER%\src\gsudo.Installer\bin\Release\gsudomsi.msi :skipbuild @@ -87,14 +107,17 @@ pushd %REPO_ROOT_FOLDER%\Build :: Create GitHub release ZIP + ZIP hash Set PSModulePath= -7z a "%OUTPUT_FOLDER%\gsudo.v%version%.zip" %OUTPUT_FOLDER%\bin\* +7z a "%OUTPUT_FOLDER%\gsudo.v%version%.zip" %BIN_FOLDER%\package\x86 +7z a "%OUTPUT_FOLDER%\gsudo.v%version%.zip" %BIN_FOLDER%\package\x64 +7z a "%OUTPUT_FOLDER%\gsudo.v%version%.zip" %BIN_FOLDER%\package\net46-AnyCpu + powershell -NoProfile -Command ECHO (Get-FileHash %OUTPUT_FOLDER%\gsudo.v%version%.zip).hash > %OUTPUT_FOLDER%\gsudo.v%version%.zip.sha256 powershell -NoProfile -Command ECHO (Get-FileHash %OUTPUT_FOLDER%\gsudoSetup.msi).hash > %OUTPUT_FOLDER%\gsudoSetup.msi.sha256 :: Chocolatey git clean %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo\Bin -xf md %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo\Bin 2> nul -copy %OUTPUT_FOLDER%\bin\*.* %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo\Bin\ +copy %BIN_FOLDER%\package\net46-AnyCpu\*.* %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo\Bin\ copy %REPO_ROOT_FOLDER%\Build\Chocolatey\verification.txt.template %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo\Tools\VERIFICATION.txt popd & pushd %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo diff --git a/build/Chocolatey/gsudo/gsudo.nuspec.template b/build/Chocolatey/gsudo.nuspec.template similarity index 96% rename from build/Chocolatey/gsudo/gsudo.nuspec.template rename to build/Chocolatey/gsudo.nuspec.template index 16e22a13..09e6c0f0 100644 --- a/build/Chocolatey/gsudo/gsudo.nuspec.template +++ b/build/Chocolatey/gsudo.nuspec.template @@ -22,16 +22,16 @@ gsudo - a sudo for windows - Gerardo Grignoli + Gerardo Grignoli & GitHub contributors http://github.com/gerardog/gsudo - 2019 Gerardo Grignoli + 2022 Gerardo Grignoli https://opensource.org/licenses/MIT false http://github.com/gerardog/gsudo - https://github.com/gerardog/gsudo/blob/master/README.md + https://gerardog.github.io/gsudo/ https://github.com/gerardog/gsudo/issues sudo for windows run elevated user command runas powershell wsl diff --git a/build/Chocolatey/gsudo/tools/chocolateyinstall.ps1 b/build/Chocolatey/gsudo/tools/chocolateyinstall.ps1 index 60e61dab..38313a79 100644 --- a/build/Chocolatey/gsudo/tools/chocolateyinstall.ps1 +++ b/build/Chocolatey/gsudo/tools/chocolateyinstall.ps1 @@ -8,31 +8,22 @@ Import-Module (Join-Path (Split-Path -parent $MyInvocation.MyCommand.Definition) $ErrorActionPreference = 'Continue' $ToolsLocation = Get-ToolsLocation -$bin = "$env:ChocolateyInstall\lib\gsudo\bin\" - -############ Clean-up previous versions -if (Test-Path "$bin\sudo.exe") -{ - Remove-Item "$bin\sudo.exe" +if ([Environment]::Is64BitOperatingSystem -eq $true) { + $bin = "$env:ChocolateyInstall\lib\gsudo\tools\x64" +} else { + $bin = "$env:ChocolateyInstall\lib\gsudo\tools\x86" } -# Remove from User Path on previous versions ( <= 0.7.1 ) -Uninstall-ChocolateyPath $bin 'User' - -# Remove from Path on previous versions ( <= 1.0.2 ) -Uninstall-ChocolateyPath $bin 'Machine' - if ([System.Environment]::CurrentDirectory -like "$ToolsLocation*") { Write-Output -Verbose "Changing directory to $ToolsLocation to ensure successfull install/upgrade." Set-Location $ToolsLocation } -############ $TargetDir = ("$ToolsLocation\gsudo\v" + ((Get-Item "$bin\gsudo.exe").VersionInfo.ProductVersion -split "\+" )[0]) $SymLinkDir = "$ToolsLocation\gsudo\Current" # Add to System Path -mkdir $TargetDir -ErrorAction Ignore +mkdir $TargetDir -ErrorAction Ignore > $null copy "$bin\*" $TargetDir -Exclude *.ignore -Force Install-ChocolateyPath -PathToInstall $SymLinkDir -PathType 'Machine' @@ -49,7 +40,7 @@ cmd /c mklink /d "$SymLinkDir" "$TargetDir\" # gsudo powershell module banner. ""; -Write-Output "gsudo successfully installed. Please restart your consoles to use gsudo." +Write-Output "gsudo successfully installed. Please restart your consoles to use gsudo.`n" if (Get-Module gsudoModule) { "Please restart PowerShell to update PowerShell gsudo Module." diff --git a/build/InstallTools.cmd b/build/InstallTools.cmd index 42ba6700..3660594b 100644 --- a/build/InstallTools.cmd +++ b/build/InstallTools.cmd @@ -1,4 +1,5 @@ choco install ilmerge choco install GitVersion.Portable choco install wixtoolset -choco install hub \ No newline at end of file +choco install hub +choco install dotnet-7.0-sdk --pre \ No newline at end of file diff --git a/docs/blog/2021-08-26-welcome/index.md b/docs/blog/2021-08-26-welcome/index.md deleted file mode 100644 index 604cec6b..00000000 --- a/docs/blog/2021-08-26-welcome/index.md +++ /dev/null @@ -1,10 +0,0 @@ ---- -slug: welcome -title: Welcome -authors: [gerardog] -tags: [] ---- - -Welcome. - -This site is still a work in progress. \ No newline at end of file diff --git a/docs/blog/2022-08-21-dotnet7/index.md b/docs/blog/2022-08-21-dotnet7/index.md new file mode 100644 index 00000000..6635dedf --- /dev/null +++ b/docs/blog/2022-08-21-dotnet7/index.md @@ -0,0 +1,63 @@ +--- +slug: gsudo-dotnet-7 +title: Migrating gsudo to .NET 7 +authors: [gerardog] +tags: [] +--- + + +The first gsudo versions were made in 2019, around the release of .NET Core 3. I tried to figure out how .NET Core's redistribution model worked, but it didn't worked for me. One should either redistribute the full runtime, or ask the user to manually download and install it. There was another option: to build a self-cointained app (with runtime embedded) but that increased the output size by more than 80mb! + +The alternative was to target .NET Framework v4.6. This version is bundled with every Windows 10/11. When targeting it, gsudo build output size was around 100kb. The app on v4.6 loaded faster, so targeting v4.6 seemed logical. It was small, fast, and the installation didn't required any big runtime redistribution or additional steps. + +Recently, things have changed a little with [.NET 7 Preview 3 announcement](https://devblogs.microsoft.com/dotnet/announcing-dotnet-7-preview-3/#faster-lighter-apps-with-native-aot) and NativeAOT: "Publishing your app as native AOT produces an app that is self-contained and that has been ahead-of-time (AOT) compiled to native code. Native AOT apps start up very quickly and use less memory. Users of the application can run it on a machine that doesn't have the .NET runtime installed." + +I'm almost sold! Let's try it out... *(sounds of frenetic typing)*... Ok, that was [18 files changed](https://github.com/gerardog/gsudo/compare/971ea97c...7c0c1b71). Now I have a multi-target project that can compile for v4.6 or v7. Not bad. + +But not everyone's cup of tea: NativeAOT builds for each specific platform, so instead of having one AnyCPU build, now I have two (x64 and x86). But also, NativeAOT is only supported on x64. The closest for x86 is a self-contained build with Ready2Run. + +Let's do some test the performance. So first let´s build for each platform: + +``` powershell +# Build .NET Framework v4.6 +msbuild /t:Restore /p:RestorePackagesConfig=true src\gsudo.sln /v:Minimal /p:TargetFrameworkVersion=v4.6 +msbuild /t:Rebuild /p:Configuration=Release src\gsudo\gsudo.csproj /v:Minimal /p:WarningLevel=0 /p:TargetFrameworkVersion=v4.6 +# Build .NET 7.0 x64 build with NativeAOT +dotnet clean .\src\gsudo\gsudo.csproj -f net7.0 | Out-null +dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x64 --sc -p:PublishAot=true -p:IlcOptimizationPreference=Size -v minimal -p:WarningLevel=0 +# Build .NET 7.0 x86 build with Ready2Run +dotnet clean .\src\gsudo\gsudo.csproj -f net7.0 -r win-x86 | Out-null +dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x86 --sc -p:PublishReadyToRun=true -p:PublishSingleFile=true -v minimal -p:WarningLevel=0 +``` + +Now let´s meassure 100 elevations using a preexisting credentials cache. I am using `gsudo -d` to force an elevation using `cmd.exe`, which loads much faster and predictable than `Powershell`. Then I repeated the tests with each different build. + +``` powershell +$gsudo="C:\git\gsudo\src\gsudo\bin\net46\gsudo.exe" +& $gsudo cache on | out-null # start a cache session. +& $gsudo -d dir | out-null # test the cache session. +Measure-Command { 1..100 | % { & $gsudo -d dir} } | select -Property TotalSeconds | Format-List +& $gsudo -k | out-null # close cache. +``` + +The first results were absurd. I found out Windows Defender takes extra time to verify unsigned apps in the cloud. So I disabled Defender and started over. + +| | v1.3.0 (Net 4.6 + ilmerge + CodeSigned) | Latest (Net 4.6 unsigned) | Net 7.0 x64 NativeAOT (unsigned) | Net 7.0 x86 Ready2Run (unsigned) | +| ------------------------------- | --------------------------------------- | ------------------------- | -------------------------------- | -------------------------------- | +| Size | 180.5 KB | 208.5 KB | 6.17 MB | 16.89 MB | +| Time to elevate 100 times (sum) | 12.75 s | 12.62 s | 7.83 s | 10.94 s | +| Performance improvement | (baseline) | 1.04% | 38.62% | 14.18% | + +Wow! An improvement of 38.62% is significant enough to ignore the fact that the file size has increased 6 MB, or almost 30 times. + +## Should gsudo target .NET 7.0? + +The problem is that the installer should provide for all platforms, and so far I´ve only focused on x64. What options do I have? + +- I could fall back to Net 4.6 (targeting AnyCPU) for the remaining platforms. The down-side would be different prerequisites for each scenario. But the installer would only grow 6mb. +- Or include x86 Net 7.0 Read2Run version. It´s faster, but takes 16mb. The setup including both would take 23 MB (actually 10mb when compressed)! + +## Current situation + +Right now my code-signing certificate is expired. Once I´ve got a new certificate, I will be making a test release. I will update this post then. + diff --git a/docs/blog/authors.yml b/docs/blog/authors.yml index 2277c7ed..09e32244 100644 --- a/docs/blog/authors.yml +++ b/docs/blog/authors.yml @@ -1,5 +1,5 @@ gerardog: name: Gerardo Grignoli - title: Maintainer of gsudo +# title: gsudo Creator url: https://github.com/gerardog image_url: https://avatars.githubusercontent.com/u/3901474?s=96&v=4 diff --git a/package.json b/package.json index f22fc720..b2536fd6 100644 --- a/package.json +++ b/package.json @@ -14,10 +14,10 @@ "write-heading-ids": "docusaurus write-heading-ids docs" }, "dependencies": { - "@docusaurus/core": "^2.0.0-beta.21", - "@docusaurus/plugin-google-gtag": "^2.0.0-beta.21", - "@docusaurus/plugin-sitemap": "^2.0.0-beta.21", - "@docusaurus/preset-classic": "^2.0.0-beta.21", + "@docusaurus/core": "^2.0.1", + "@docusaurus/plugin-google-gtag": "^2.0.1", + "@docusaurus/plugin-sitemap": "^2.0.1", + "@docusaurus/preset-classic": "^2.0.1", "@mdx-js/react": "^1.6.22", "clsx": "^1.1.1", "prism-react-renderer": "^1.3.1", diff --git a/src/.gitattributes b/src/.gitattributes new file mode 100644 index 00000000..c08f7879 --- /dev/null +++ b/src/.gitattributes @@ -0,0 +1,2 @@ +gsudo.extras\*.ps1 text eol=crlf +gsudo.extras\* text eol=lf \ No newline at end of file diff --git a/src/KeyPressTester/KeyPressTester.csproj b/src/KeyPressTester/KeyPressTester.csproj index 5ffa5d66..a4c20285 100644 --- a/src/KeyPressTester/KeyPressTester.csproj +++ b/src/KeyPressTester/KeyPressTester.csproj @@ -1,53 +1,12 @@ - - - + - Debug - AnyCPU - {FD3B76FD-E682-4C65-A936-84B9B2C6FB19} + net46 Exe - KeyPressTester - KeyPressTester - v4.6 - 512 - true - true + false + Debug;Release;Debug-Net46 - - AnyCPU - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - AnyCPU - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - - - - - - - - - - - - - + + - \ No newline at end of file diff --git a/src/gsudo.Installer/Product.wxs b/src/gsudo.Installer/Product.wxs index 53c1f670..5d019666 100644 --- a/src/gsudo.Installer/Product.wxs +++ b/src/gsudo.Installer/Product.wxs @@ -2,14 +2,14 @@ - + Manufacturer="Gerardo Grignoli" + Description="gsudo is a sudo-equivalent for windows" /> @@ -19,6 +19,21 @@ + + + + 1 + 1 + + @@ -33,6 +48,7 @@ + @@ -49,18 +65,28 @@ Value="[INSTALLFOLDER]" /> - - + + + + + + + + + + + + - + - - - + + + diff --git a/src/gsudo.Installer/gsudomsi.wixproj b/src/gsudo.Installer/gsudomsi.wixproj index 0b6f2fa1..3ea165fc 100644 --- a/src/gsudo.Installer/gsudomsi.wixproj +++ b/src/gsudo.Installer/gsudomsi.wixproj @@ -7,7 +7,7 @@ 3.10 34aaa3cf-95e5-41ea-8a00-c5f713bf664e 2.0 - gsudomsi + gsudoSetup Package diff --git a/src/gsudo.Tests/CmdTests.cs b/src/gsudo.Tests/CmdTests.cs index 48bcb07b..cc7d62e5 100644 --- a/src/gsudo.Tests/CmdTests.cs +++ b/src/gsudo.Tests/CmdTests.cs @@ -185,7 +185,7 @@ public static void AssemblyInitialize(TestContext context) Verb = "RunAs" } )?.WaitForExit(); - Thread.Sleep(500); + Thread.Sleep(2000); } } } diff --git a/src/gsudo.Tests/gsudo.Tests.csproj b/src/gsudo.Tests/gsudo.Tests.csproj index 9673a72d..f1eed44b 100644 --- a/src/gsudo.Tests/gsudo.Tests.csproj +++ b/src/gsudo.Tests/gsudo.Tests.csproj @@ -1,78 +1,15 @@ - - - - + - Debug - AnyCPU - {B91748FC-950F-46AB-A037-7118BEA81FF7} - Library - Properties - gsudo.Tests - gsudo.Tests - v4.6 - 512 - {3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - 15.0 - $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion) - $(ProgramFiles)\Common Files\microsoft shared\VSTT\$(VisualStudioVersion)\UITestExtensionPackages - False - UnitTest - - + net7.0 + false + Debug;Release - - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - ..\packages\MSTest.TestFramework.1.3.2\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.dll - - - ..\packages\MSTest.TestFramework.1.3.2\lib\net45\Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll - - - - - - - - - - - - - + - - {9eebda90-12de-4780-b8b1-8bf86dfe71b3} - gsudo - + + + - - - - - This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}. - - - - - \ No newline at end of file diff --git a/src/gsudo.Tests/packages.config b/src/gsudo.Tests/packages.config deleted file mode 100644 index fc09f95b..00000000 --- a/src/gsudo.Tests/packages.config +++ /dev/null @@ -1,5 +0,0 @@ - - - - - \ No newline at end of file diff --git a/src/gsudo.extras/Invoke-gsudo.Tests.ps1 b/src/gsudo.Wrappers.Tests/Invoke-gsudo.Tests.ps1 similarity index 96% rename from src/gsudo.extras/Invoke-gsudo.Tests.ps1 rename to src/gsudo.Wrappers.Tests/Invoke-gsudo.Tests.ps1 index 6c259968..e8d7a770 100644 --- a/src/gsudo.extras/Invoke-gsudo.Tests.ps1 +++ b/src/gsudo.Wrappers.Tests/Invoke-gsudo.Tests.ps1 @@ -1,4 +1,8 @@ Describe "PS Invoke-Gsudo (v$($PSVersionTable.PSVersion.ToString()))" { + BeforeAll { + $env:Path += ";" + (Get-Item (Join-Path $PSScriptRoot "..\gsudo.Wrappers")).FullName + } + BeforeEach { $global:ErrorActionPreference=$ErrorActionPreference='Continue'; } diff --git a/src/gsudo.extras/gsudo.Tests.ps1 b/src/gsudo.Wrappers.Tests/gsudo.Tests.ps1 similarity index 81% rename from src/gsudo.extras/gsudo.Tests.ps1 rename to src/gsudo.Wrappers.Tests/gsudo.Tests.ps1 index aa5b3903..c1992d8e 100644 --- a/src/gsudo.extras/gsudo.Tests.ps1 +++ b/src/gsudo.Wrappers.Tests/gsudo.Tests.ps1 @@ -1,6 +1,7 @@ Describe "PS Gsudo (v$($PSVersionTable.PSVersion.ToString()))" { BeforeAll { - $Path = (Get-Item (Join-Path $PSScriptRoot "gsudoModule.psm1")).FullName + $env:Path += ";" + (Get-Item (Join-Path $PSScriptRoot "..\gsudo.Wrappers")).FullName + $Path = (Get-Item (Join-Path $PSScriptRoot "..\gsudo.Wrappers\gsudoModule.psm1")).FullName $Path | Should -not -BeNullOrEmpty Import-Module $Path } diff --git a/src/gsudo.extras/Invoke-gsudo.ps1 b/src/gsudo.Wrappers/Invoke-gsudo.ps1 similarity index 100% rename from src/gsudo.extras/Invoke-gsudo.ps1 rename to src/gsudo.Wrappers/Invoke-gsudo.ps1 diff --git a/src/gsudo.extras/gsudo b/src/gsudo.Wrappers/gsudo similarity index 100% rename from src/gsudo.extras/gsudo rename to src/gsudo.Wrappers/gsudo diff --git a/src/gsudo.extras/gsudoModule.psd1 b/src/gsudo.Wrappers/gsudoModule.psd1 similarity index 100% rename from src/gsudo.extras/gsudoModule.psd1 rename to src/gsudo.Wrappers/gsudoModule.psd1 diff --git a/src/gsudo.extras/gsudoModule.psm1 b/src/gsudo.Wrappers/gsudoModule.psm1 similarity index 100% rename from src/gsudo.extras/gsudoModule.psm1 rename to src/gsudo.Wrappers/gsudoModule.psm1 diff --git a/src/gsudo.extras/.gitattributes b/src/gsudo.extras/.gitattributes deleted file mode 100644 index 120ed630..00000000 --- a/src/gsudo.extras/.gitattributes +++ /dev/null @@ -1,2 +0,0 @@ -*.ps1 text eol=crlf -* text eol=lf \ No newline at end of file diff --git a/src/gsudo.sln b/src/gsudo.sln index 3786e1b5..a1d6d00a 100644 --- a/src/gsudo.sln +++ b/src/gsudo.sln @@ -1,13 +1,13 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 16 -VisualStudioVersion = 16.0.29215.179 +# Visual Studio Version 17 +VisualStudioVersion = 17.1.32421.90 MinimumVisualStudioVersion = 10.0.40219.1 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "gsudo", "gsudo\gsudo.csproj", "{9EEBDA90-12DE-4780-B8B1-8BF86DFE71B3}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "gsudo.Tests", "gsudo.Tests\gsudo.Tests.csproj", "{B91748FC-950F-46AB-A037-7118BEA81FF7}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "gsudo.Tests", "gsudo.Tests\gsudo.Tests.csproj", "{B91748FC-950F-46AB-A037-7118BEA81FF7}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KeyPressTester", "KeyPressTester\KeyPressTester.csproj", "{FD3B76FD-E682-4C65-A936-84B9B2C6FB19}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "KeyPressTester", "KeyPressTester\KeyPressTester.csproj", "{FD3B76FD-E682-4C65-A936-84B9B2C6FB19}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution diff --git a/src/gsudo/Commands/CacheCommand.cs b/src/gsudo/Commands/CacheCommand.cs index c364d6cb..8fc3defa 100644 --- a/src/gsudo/Commands/CacheCommand.cs +++ b/src/gsudo/Commands/CacheCommand.cs @@ -66,8 +66,9 @@ public async Task Execute() commandToRun.AddRange(new[] {"cache", "on", "--pid", AllowedPid.ToString()}); + InputArguments.Wait = true; InputArguments.Direct = true; - return await new RunCommand() {CommandToRun = commandToRun} + return await new RunCommand() {CommandToRun = commandToRun, } .Execute().ConfigureAwait(false); } else @@ -84,6 +85,10 @@ public async Task Execute() Logger.Instance.Log("Cache is a security risk. Use `gsudo cache off` (or `-k`) to go back to safety.", LogLevel.Warning); + + // wait until the cache service becomes available (2 seconds max) + for (int i=0; i<40 && !NamedPipeClient.IsServiceAvailable(AllowedPid); i++) + await Task.Delay(50).ConfigureAwait(false); } return 0; diff --git a/src/gsudo/Commands/HelpCommand.cs b/src/gsudo/Commands/HelpCommand.cs index 30e59e5e..ad96a18d 100644 --- a/src/gsudo/Commands/HelpCommand.cs +++ b/src/gsudo/Commands/HelpCommand.cs @@ -35,9 +35,7 @@ internal static void ShowHelp() Console.WriteLine("gsudo config\t\t\t\tShow current config settings & values."); Console.WriteLine("gsudo config {key} [--global] [value] \tRead or write a user setting"); Console.WriteLine("gsudo config {key} [--global] --reset \tReset config to default value"); - Console.WriteLine("gsudo status\t\t\t\tShow status about current user, security, integrity level or other gsudo relevant data."); - // Console.WriteLine("gsudo confighelp \tGet additional help about config settings."); Console.WriteLine(); Console.WriteLine("General options:"); Console.WriteLine(" -n | --new Starts the command in a new console (and returns immediately)."); @@ -49,11 +47,6 @@ internal static void ShowHelp() Console.WriteLine(" --loadProfile When elevating PowerShell commands, do load profiles."); Console.WriteLine(" --copyns Connect network drives to the elevated user. Warning: Verbose, interactive asks for credentials"); Console.WriteLine(); - /* - Console.WriteLine("Credentials Cache options:"); - Console.WriteLine($" If no cache option is specified, your credentials will be cached for {Settings.CacheDuration.Value.TotalSeconds} seconds."); - Console.WriteLine(); - */ Console.WriteLine("Other options:"); Console.WriteLine(" --loglevel {val} Set minimum log level to display: All, Debug, Info, Warning, Error, None"); Console.WriteLine(" --debug Enable debug mode."); @@ -61,7 +54,7 @@ internal static void ShowHelp() Console.WriteLine(" --vt (deprecated) Set console mode to piped VT100 ConPty/PseudoConsole (experimental)."); Console.WriteLine(" --attached (deprecated) Set console mode to attached."); Console.WriteLine(" --copyev (deprecated) Copy environment variables to the elevated process. (not needed on default console mode)"); - Console.Write("\nLearn more about security considerations of using gsudo at: https://bit.ly/gsudoSecurity\n"); + Console.Write("\nLearn more about security considerations of using gsudo at: https://gerardog.github.io/gsudo/docs/security\n"); return; } diff --git a/src/gsudo/Commands/RunCommand.cs b/src/gsudo/Commands/RunCommand.cs index 9ad73be3..e1ca8f68 100644 --- a/src/gsudo/Commands/RunCommand.cs +++ b/src/gsudo/Commands/RunCommand.cs @@ -349,8 +349,12 @@ internal IEnumerable AddCopyEnvironment(IEnumerable args, Elevat nameof(gsudo)); var dirSec = new DirectorySecurity(); - dirSec.AddAccessRule(new FileSystemAccessRule(new SecurityIdentifier(WellKnownSidType.WorldSid, null), FileSystemRights.FullControl, AccessControlType.Allow)); - Directory.CreateDirectory(tempFolder, dirSec); + dirSec.AddAccessRule(new FileSystemAccessRule(new SecurityIdentifier(WellKnownSidType.WorldSid, null), FileSystemRights.FullControl, AccessControlType.Allow)); +#if NETFRAMEWORK + Directory.CreateDirectory(tempFolder, dirSec); +#else + dirSec.CreateDirectory(tempFolder); +#endif string tempBatName = Path.Combine( tempFolder, @@ -360,7 +364,9 @@ internal IEnumerable AddCopyEnvironment(IEnumerable args, Elevat System.Security.AccessControl.FileSecurity fSecurity = new System.Security.AccessControl.FileSecurity(); fSecurity.AddAccessRule(new System.Security.AccessControl.FileSystemAccessRule(new SecurityIdentifier(WellKnownSidType.WorldSid, null), System.Security.AccessControl.FileSystemRights.FullControl, System.Security.AccessControl.AccessControlType.Allow)); - File.SetAccessControl(tempBatName, fSecurity); + + new FileInfo(tempBatName).SetAccessControl(fSecurity); + return new string[] { Environment.GetEnvironmentVariable("COMSPEC"), diff --git a/src/gsudo/Commands/ServiceCommand.cs b/src/gsudo/Commands/ServiceCommand.cs index 4c45679c..94df98cc 100644 --- a/src/gsudo/Commands/ServiceCommand.cs +++ b/src/gsudo/Commands/ServiceCommand.cs @@ -5,6 +5,9 @@ using gsudo.Rpc; using gsudo.ProcessHosts; using System.Runtime.Serialization.Formatters.Binary; +#if NETCOREAPP +using System.Text.Json; +#endif namespace gsudo.Commands { @@ -123,9 +126,11 @@ private static async Task ReadElevationRequest(Stream dataPipe Logger.Instance.Log($"ElevationRequest length {dataSizeInt}", LogLevel.Debug); - return (ElevationRequest) new BinaryFormatter() - .Deserialize(new MemoryStream(inBuffer)); - +#if NETFRAMEWORK + return (ElevationRequest)new BinaryFormatter().Deserialize(new MemoryStream(inBuffer)); +#else + return JsonSerializer.Deserialize(inBuffer, ElevationRequestJsonContext.Default.ElevationRequest); +#endif } public void Dispose() diff --git a/src/gsudo/CredentialsCacheLifetimeManager.cs b/src/gsudo/CredentialsCacheLifetimeManager.cs index 5be999f1..0941538c 100644 --- a/src/gsudo/CredentialsCacheLifetimeManager.cs +++ b/src/gsudo/CredentialsCacheLifetimeManager.cs @@ -3,6 +3,9 @@ using System.Security.AccessControl; using System.Security.Principal; using System.Threading; +#if NETFRAMEWORK +using EventWaitHandleAcl = System.Threading.EventWaitHandle; +#endif namespace gsudo { @@ -46,20 +49,28 @@ public CredentialsCacheLifetimeManager(int pid) EventWaitHandleRights.Synchronize | EventWaitHandleRights.Modify, AccessControlType.Allow)); - if (!EventWaitHandle.TryOpenExisting( + if (!EventWaitHandleAcl.TryOpenExisting( GLOBAL_WAIT_HANDLE_NAME, EventWaitHandleRights.Synchronize | EventWaitHandleRights.Modify, out var eventWaitHandle)) { +#if NETFRAMEWORK eventWaitHandle = new EventWaitHandle(false, EventResetMode.ManualReset, GLOBAL_WAIT_HANDLE_NAME, out var created, security); +#else + eventWaitHandle = EventWaitHandleAcl.Create(false, EventResetMode.ManualReset, GLOBAL_WAIT_HANDLE_NAME, out var created, security); +#endif } - if (!EventWaitHandle.TryOpenExisting( + if (!EventWaitHandleAcl.TryOpenExisting( GLOBAL_WAIT_HANDLE_NAME + pid.ToString(CultureInfo.InvariantCulture), EventWaitHandleRights.Synchronize | EventWaitHandleRights.Modify, out var eventWaitHandleSpecific)) { +#if NETFRAMEWORK eventWaitHandleSpecific = new EventWaitHandle(false, EventResetMode.ManualReset, GLOBAL_WAIT_HANDLE_NAME + pid.ToString(CultureInfo.InvariantCulture), out var created, security); +#else + eventWaitHandleSpecific = EventWaitHandleAcl.Create(false, EventResetMode.ManualReset, GLOBAL_WAIT_HANDLE_NAME + pid.ToString(CultureInfo.InvariantCulture), out var created, security); +#endif } var credentialsResetThread = new Thread(() => @@ -83,7 +94,7 @@ public static bool ClearCredentialsCache(int? pid = null) { try { - using (var eventWaitHandle = EventWaitHandle.OpenExisting( + using (var eventWaitHandle = EventWaitHandleAcl.OpenExisting( GLOBAL_WAIT_HANDLE_NAME + (pid?.ToString(CultureInfo.InvariantCulture) ?? ""), EventWaitHandleRights.Synchronize | EventWaitHandleRights.Modify)) { diff --git a/src/gsudo/ElevationRequest.cs b/src/gsudo/ElevationRequest.cs index 224b49e2..1e545eef 100644 --- a/src/gsudo/ElevationRequest.cs +++ b/src/gsudo/ElevationRequest.cs @@ -43,6 +43,7 @@ internal enum ConsoleMode { } } +#if NETFRAMEWORK class MySerializationBinder : SerializationBinder { /// @@ -68,4 +69,10 @@ public override void BindToName(Type serializedType, out string assemblyName, ou typeName = serializedType.FullName; } } +#else + [System.Text.Json.Serialization.JsonSerializable(typeof(ElevationRequest))] + internal partial class ElevationRequestJsonContext : System.Text.Json.Serialization.JsonSerializerContext + { + } +#endif } diff --git a/src/gsudo/Helpers/ProcessHelper.cs b/src/gsudo/Helpers/ProcessHelper.cs index 97b67971..78dbeade 100644 --- a/src/gsudo/Helpers/ProcessHelper.cs +++ b/src/gsudo/Helpers/ProcessHelper.cs @@ -15,10 +15,13 @@ public static class ProcessHelper { private static int? _cacheGetCurrentIntegrityLevelCache; private static bool? _cacheIsAdmin; + private static string _cacheOwnExeName; public static string GetOwnExeName() { - return SymbolicLinkSupport.ResolveSymbolicLink(System.Reflection.Assembly.GetEntryAssembly().Location); + if (_cacheOwnExeName != null) + return _cacheOwnExeName; + return _cacheOwnExeName = SymbolicLinkSupport.ResolveSymbolicLink(System.Diagnostics.Process.GetCurrentProcess().MainModule.FileName); } public static string GetExeName(this Process process) diff --git a/src/gsudo/Helpers/SymbolicLinkSupport.cs b/src/gsudo/Helpers/SymbolicLinkSupport.cs index 9dd8948a..907854fe 100644 --- a/src/gsudo/Helpers/SymbolicLinkSupport.cs +++ b/src/gsudo/Helpers/SymbolicLinkSupport.cs @@ -17,6 +17,7 @@ static class SymbolicLinkSupport /// public static void EnableAssemblyLoadFix() { +#if NETFRAMEWORK string exeName = ProcessHelper.GetOwnExeName(); string exeNamePath = Path.GetDirectoryName(exeName); @@ -35,6 +36,7 @@ private static Assembly CurrentDomain_AssemblyResolve(object sender, ResolveEven if (File.Exists(target)) return Assembly.LoadFrom(target); return null; +#endif } public static string ResolveSymbolicLink(string symLinkFullPath) @@ -44,7 +46,7 @@ public static string ResolveSymbolicLink(string symLinkFullPath) .Replace("\\\\?\\", "") ; } - public static string GetFinalPathName(string path) + private static string GetFinalPathName(string path) { var h = Native.FileApi.CreateFile(path, Native.FileApi.FILE_READ_EA, @@ -77,3 +79,4 @@ public static string GetFinalPathName(string path) } } } + diff --git a/src/gsudo/Native/ProcessApi.cs b/src/gsudo/Native/ProcessApi.cs index 4766d9ea..d4e1b83b 100644 --- a/src/gsudo/Native/ProcessApi.cs +++ b/src/gsudo/Native/ProcessApi.cs @@ -164,7 +164,7 @@ internal struct PROCESSENTRY32 [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 260)] public string szExeFile; }; - [SuppressUnmanagedCodeSecurity, HostProtection(SecurityAction.LinkDemand, MayLeakOnAbort = true)] + [SuppressUnmanagedCodeSecurity] internal sealed class SafeSnapshotHandle : SafeHandleMinusOneIsInvalid { internal SafeSnapshotHandle() : base(true) diff --git a/src/gsudo/Rpc/Connection.cs b/src/gsudo/Rpc/Connection.cs index 212e6b8c..0344dfbf 100644 --- a/src/gsudo/Rpc/Connection.cs +++ b/src/gsudo/Rpc/Connection.cs @@ -2,6 +2,9 @@ using System.IO; using System.IO.Pipes; using System.Runtime.Serialization.Formatters.Binary; +#if NETCOREAPP +using System.Text.Json; +#endif using System.Threading; using System.Threading.Tasks; @@ -58,6 +61,7 @@ private async Task Flush(PipeStream npStream) public async Task WriteElevationRequest(ElevationRequest elevationRequest) { +#if NETFRAMEWORK // Using Binary instead of Newtonsoft.JSON to reduce load times. var ms = new System.IO.MemoryStream(); new BinaryFormatter() @@ -71,6 +75,13 @@ public async Task WriteElevationRequest(ElevationRequest elevationRequest) await ControlStream.WriteAsync(lengthArray, 0, sizeof(int)).ConfigureAwait(false); await ControlStream.WriteAsync(ms.ToArray(), 0, (int)ms.Length).ConfigureAwait(false); await ControlStream.FlushAsync().ConfigureAwait(false); +#else + byte[] utf8Json = JsonSerializer.SerializeToUtf8Bytes(elevationRequest, ElevationRequestJsonContext.Default.ElevationRequest); + + await ControlStream.WriteAsync(BitConverter.GetBytes(utf8Json.Length), 0, sizeof(int)).ConfigureAwait(false); + await ControlStream.WriteAsync(utf8Json, 0, utf8Json.Length).ConfigureAwait(false); + await ControlStream.FlushAsync().ConfigureAwait(false); +#endif } public void Dispose() diff --git a/src/gsudo/Rpc/NamedPipeClient.cs b/src/gsudo/Rpc/NamedPipeClient.cs index da785dd6..e9bb2c42 100644 --- a/src/gsudo/Rpc/NamedPipeClient.cs +++ b/src/gsudo/Rpc/NamedPipeClient.cs @@ -72,20 +72,21 @@ public async Task Connect(int? clientPid, bool failFast) } } - public static bool IsServiceAvailable() + public static bool IsServiceAvailable(int? pid = null, string sid = null) { string pipeName = null; - var callerProcessId = Process.GetCurrentProcess().Id; - string user = System.Security.Principal.WindowsIdentity.GetCurrent().User.Value; - while (callerProcessId > 0) + pid = pid ?? ProcessHelper.GetParentProcessId(Process.GetCurrentProcess().Id); + sid = sid ?? System.Security.Principal.WindowsIdentity.GetCurrent().User.Value; + + while (pid.Value > 0) { - callerProcessId = ProcessHelper.GetParentProcessId(callerProcessId); - pipeName = NamedPipeNameFactory.GetPipeName(user, callerProcessId); + pipeName = NamedPipeNameFactory.GetPipeName(sid, pid.Value); // Does the pipe exists? if (NamedPipeUtils.ExistsNamedPipe(pipeName)) break; + pid = ProcessHelper.GetParentProcessId(pid.Value); pipeName = null; // try grandfather. } diff --git a/src/gsudo/Rpc/NamedPipeServer.cs b/src/gsudo/Rpc/NamedPipeServer.cs index 6e5cb82d..22e617ff 100644 --- a/src/gsudo/Rpc/NamedPipeServer.cs +++ b/src/gsudo/Rpc/NamedPipeServer.cs @@ -80,11 +80,19 @@ public async Task Listen() do { - using (NamedPipeServerStream dataPipe = new NamedPipeServerStream(pipeName, PipeDirection.InOut, MAX_SERVER_INSTANCES, - PipeTransmissionMode.Message, PipeOptions.Asynchronous, Settings.BufferSize, Settings.BufferSize, ps)) +#if NETFRAMEWORK + using (NamedPipeServerStream dataPipe = new NamedPipeServerStream( +#else + using (var dataPipe = System.IO.Pipes.NamedPipeServerStreamAcl.Create( +#endif + pipeName, PipeDirection.InOut, MAX_SERVER_INSTANCES, PipeTransmissionMode.Message, PipeOptions.Asynchronous, Settings.BufferSize, Settings.BufferSize, ps)) { - using (NamedPipeServerStream controlPipe = new NamedPipeServerStream(pipeName + "_control", PipeDirection.InOut, MAX_SERVER_INSTANCES, - PipeTransmissionMode.Message, PipeOptions.Asynchronous, Settings.BufferSize, Settings.BufferSize, ps)) +#if NETFRAMEWORK + using (var controlPipe = new NamedPipeServerStream( +#else + using (var controlPipe = System.IO.Pipes.NamedPipeServerStreamAcl.Create( +#endif + pipeName + "_control", PipeDirection.InOut, MAX_SERVER_INSTANCES, PipeTransmissionMode.Message, PipeOptions.Asynchronous, Settings.BufferSize, Settings.BufferSize, ps)) { Logger.Instance.Log("NamedPipeServer listening.", LogLevel.Debug); Task.WaitAll( diff --git a/src/gsudo/Tokens/TokenProvider.cs b/src/gsudo/Tokens/TokenProvider.cs index 169ab77f..174205f0 100644 --- a/src/gsudo/Tokens/TokenProvider.cs +++ b/src/gsudo/Tokens/TokenProvider.cs @@ -296,7 +296,9 @@ public TokenProvider RestrictTokenMaxPrivilege(bool ignoreErrors = false) public TokenProvider Impersonate(Action ActionImpersonated) { - using (var ctx = System.Security.Principal.WindowsIdentity.Impersonate(GetToken().DangerousGetHandle())) + System.Security.Principal.WindowsIdentity.RunImpersonated(new Microsoft.Win32.SafeHandles.SafeAccessTokenHandle(GetToken().DangerousGetHandle()), ActionImpersonated); + +/* using (var ctx = System.Security.Principal.WindowsIdentity.Impersonate(GetToken().DangerousGetHandle())) { try { @@ -308,24 +310,17 @@ public TokenProvider Impersonate(Action ActionImpersonated) } } +*/ return this; } public T Impersonate(Func ActionImpersonated) { - using (var ctx = System.Security.Principal.WindowsIdentity.Impersonate(GetToken().DangerousGetHandle())) - { - try - { - return ActionImpersonated(); - } - finally - { - ctx.Undo(); - } - } - } + T res = default; + System.Security.Principal.WindowsIdentity.RunImpersonated(new Microsoft.Win32.SafeHandles.SafeAccessTokenHandle(GetToken().DangerousGetHandle()), () => { res = ActionImpersonated(); }); + return res; + } public TokenProvider EnablePrivileges(bool throwOnFailure, params Privilege[] priviledgesList) { diff --git a/src/gsudo/gsudo.csproj b/src/gsudo/gsudo.csproj index 8da6c5be..b0ad67c5 100644 --- a/src/gsudo/gsudo.csproj +++ b/src/gsudo/gsudo.csproj @@ -1,15 +1,14 @@  - Exe - net46 + net7.0;net46 false StrongName.snk Gerardo Grignoli gsudo is a sudo for Windows, allows to run commands with elevated permissions in the current console. false bin\ - false + true false OnBuildSuccess 1.0.0-prerelease @@ -24,21 +23,24 @@ $(MSBuildProjectDirectory)=C:\ 1.0.0.0 1.0.0.0 - - + 1701;1702;CA1303;CA1707;CA1028;CA1001;CA1031;CA1416 + + + False + true + true + Size + DEBUG pdbonly - true - 1701;1702;CA1303;CA1707;CA1028;CA1001;CA1031 + true - - all @@ -48,13 +50,17 @@ all runtime; build; native; contentfiles; analyzers; buildtransitive - - + + + + + + + - @@ -63,5 +69,4 @@ - diff --git a/yarn.lock b/yarn.lock index fbcd3237..f1dc99b3 100644 --- a/yarn.lock +++ b/yarn.lock @@ -150,6 +150,11 @@ resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.18.6.tgz#8b37d24e88e8e21c499d4328db80577d8882fa53" integrity sha512-tzulrgDT0QD6U7BJ4TKVk2SDDg7wlP39P9yAx1RfLy7vP/7rsDRlWVfbWxElslu56+r7QOhB2NSDsabYYruoZQ== +"@babel/compat-data@^7.17.7", "@babel/compat-data@^7.18.8": + version "7.18.8" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.18.8.tgz#2483f565faca607b8535590e84e7de323f27764d" + integrity sha512-HSmX4WZPPK3FUxYp7g2T6EyO8j96HlZJlxmKPSh6KAcqwyDrfx7hKjXpAW/0FhFfTJsR0Yt4lAjLI2coMptIHQ== + "@babel/core@7.12.9": version "7.12.9" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.12.9.tgz#fd450c4ec10cdbb980e2928b7aa7a28484593fc8" @@ -172,7 +177,7 @@ semver "^5.4.1" source-map "^0.5.0" -"@babel/core@^7.15.5", "@babel/core@^7.18.2": +"@babel/core@^7.15.5": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.18.6.tgz#54a107a3c298aee3fe5e1947a6464b9b6faca03d" integrity sha512-cQbWBpxcbbs/IUredIPkHiAGULLV8iwgNRMFzvbhEXISp4f3rUUXE5+TIw6KwUWUR3DwyI6gmBRnmAtYaWehwQ== @@ -193,7 +198,28 @@ json5 "^2.2.1" semver "^6.3.0" -"@babel/generator@^7.12.5", "@babel/generator@^7.18.2", "@babel/generator@^7.18.6": +"@babel/core@^7.18.6": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.18.10.tgz#39ad504991d77f1f3da91be0b8b949a5bc466fb8" + integrity sha512-JQM6k6ENcBFKVtWvLavlvi/mPcpYZ3+R+2EySDEMSMbp7Mn4FexlbbJVrx2R7Ijhr01T8gyqrOaABWIOgxeUyw== + dependencies: + "@ampproject/remapping" "^2.1.0" + "@babel/code-frame" "^7.18.6" + "@babel/generator" "^7.18.10" + "@babel/helper-compilation-targets" "^7.18.9" + "@babel/helper-module-transforms" "^7.18.9" + "@babel/helpers" "^7.18.9" + "@babel/parser" "^7.18.10" + "@babel/template" "^7.18.10" + "@babel/traverse" "^7.18.10" + "@babel/types" "^7.18.10" + convert-source-map "^1.7.0" + debug "^4.1.0" + gensync "^1.0.0-beta.2" + json5 "^2.2.1" + semver "^6.3.0" + +"@babel/generator@^7.12.5", "@babel/generator@^7.18.6": version "7.18.7" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.18.7.tgz#2aa78da3c05aadfc82dbac16c99552fc802284bd" integrity sha512-shck+7VLlY72a2w9c3zYWuE1pwOKEiQHV7GTUbSnhyl5eu3i04t30tBY82ZRWrDfo3gkakCFtevExnxbkf2a3A== @@ -202,6 +228,15 @@ "@jridgewell/gen-mapping" "^0.3.2" jsesc "^2.5.1" +"@babel/generator@^7.18.10", "@babel/generator@^7.18.7": + version "7.18.12" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.18.12.tgz#fa58daa303757bd6f5e4bbca91b342040463d9f4" + integrity sha512-dfQ8ebCN98SvyL7IxNMCUtZQSq5R7kxgN+r8qYTGDmmSion1hX2C0zq2yo1bsCDhXixokv1SAWTZUMYbO/V5zg== + dependencies: + "@babel/types" "^7.18.10" + "@jridgewell/gen-mapping" "^0.3.2" + jsesc "^2.5.1" + "@babel/helper-annotate-as-pure@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.18.6.tgz#eaa49f6f80d5a33f9a5dd2276e6d6e451be0a6bb" @@ -227,6 +262,16 @@ browserslist "^4.20.2" semver "^6.3.0" +"@babel/helper-compilation-targets@^7.17.7", "@babel/helper-compilation-targets@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.18.9.tgz#69e64f57b524cde3e5ff6cc5a9f4a387ee5563bf" + integrity sha512-tzLCyVmqUiFlcFoAPLA/gL9TeYrF61VLNtb+hvkuVaB5SUjW7jcfrglBIX1vUIoT7CLP3bBlIMeyEsIl2eFQNg== + dependencies: + "@babel/compat-data" "^7.18.8" + "@babel/helper-validator-option" "^7.18.6" + browserslist "^4.20.2" + semver "^6.3.0" + "@babel/helper-create-class-features-plugin@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.18.6.tgz#6f15f8459f3b523b39e00a99982e2c040871ed72" @@ -262,11 +307,28 @@ resolve "^1.14.2" semver "^6.1.2" +"@babel/helper-define-polyfill-provider@^0.3.2": + version "0.3.2" + resolved "https://registry.yarnpkg.com/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.3.2.tgz#bd10d0aca18e8ce012755395b05a79f45eca5073" + integrity sha512-r9QJJ+uDWrd+94BSPcP6/de67ygLtvVy6cK4luE6MOuDsZIdoaPBnfSpbO/+LTifjPckbKXRuI9BB/Z2/y3iTg== + dependencies: + "@babel/helper-compilation-targets" "^7.17.7" + "@babel/helper-plugin-utils" "^7.16.7" + debug "^4.1.1" + lodash.debounce "^4.0.8" + resolve "^1.14.2" + semver "^6.1.2" + "@babel/helper-environment-visitor@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.18.6.tgz#b7eee2b5b9d70602e59d1a6cad7dd24de7ca6cd7" integrity sha512-8n6gSfn2baOY+qlp+VSzsosjCVGFqWKmDF0cCWOybh52Dw3SEyoWR1KrhMJASjLwIEkkAufZ0xvr+SxLHSpy2Q== +"@babel/helper-environment-visitor@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.18.9.tgz#0c0cee9b35d2ca190478756865bb3528422f51be" + integrity sha512-3r/aACDJ3fhQ/EVgFy0hpj8oHyHpQc+LPtJoY9SzTThAsStm4Ptegq92vqKoE3vD706ZVFWITnMnxucw+S9Ipg== + "@babel/helper-explode-assignable-expression@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.18.6.tgz#41f8228ef0a6f1a036b8dfdfec7ce94f9a6bc096" @@ -282,6 +344,14 @@ "@babel/template" "^7.18.6" "@babel/types" "^7.18.6" +"@babel/helper-function-name@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.18.9.tgz#940e6084a55dee867d33b4e487da2676365e86b0" + integrity sha512-fJgWlZt7nxGksJS9a0XdSaI4XvpExnNIgRP+rVefWh5U7BL8pPuir6SJUmFKRfjWQ51OtWSzwOxhaH/EBWWc0A== + dependencies: + "@babel/template" "^7.18.6" + "@babel/types" "^7.18.9" + "@babel/helper-hoist-variables@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.18.6.tgz#d4d2c8fb4baeaa5c68b99cc8245c56554f926678" @@ -296,6 +366,13 @@ dependencies: "@babel/types" "^7.18.6" +"@babel/helper-member-expression-to-functions@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.18.9.tgz#1531661e8375af843ad37ac692c132841e2fd815" + integrity sha512-RxifAh2ZoVU67PyKIO4AMi1wTenGfMR/O/ae0CCRqwgBAt5v7xjdtRw7UoSbsreKrQn5t7r89eruK/9JjYHuDg== + dependencies: + "@babel/types" "^7.18.9" + "@babel/helper-module-imports@^7.12.13", "@babel/helper-module-imports@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.18.6.tgz#1e3ebdbbd08aad1437b428c50204db13c5a3ca6e" @@ -317,6 +394,20 @@ "@babel/traverse" "^7.18.6" "@babel/types" "^7.18.6" +"@babel/helper-module-transforms@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.18.9.tgz#5a1079c005135ed627442df31a42887e80fcb712" + integrity sha512-KYNqY0ICwfv19b31XzvmI/mfcylOzbLtowkw+mfvGPAQ3kfCnMLYbED3YecL5tPd8nAYFQFAd6JHp2LxZk/J1g== + dependencies: + "@babel/helper-environment-visitor" "^7.18.9" + "@babel/helper-module-imports" "^7.18.6" + "@babel/helper-simple-access" "^7.18.6" + "@babel/helper-split-export-declaration" "^7.18.6" + "@babel/helper-validator-identifier" "^7.18.6" + "@babel/template" "^7.18.6" + "@babel/traverse" "^7.18.9" + "@babel/types" "^7.18.9" + "@babel/helper-optimise-call-expression@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.18.6.tgz#9369aa943ee7da47edab2cb4e838acf09d290ffe" @@ -334,6 +425,11 @@ resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.18.6.tgz#9448974dd4fb1d80fefe72e8a0af37809cd30d6d" integrity sha512-gvZnm1YAAxh13eJdkb9EWHBnF3eAub3XTLCZEehHT2kWxiKVRL64+ae5Y6Ivne0mVHmMYKT+xWgZO+gQhuLUBg== +"@babel/helper-plugin-utils@^7.16.7", "@babel/helper-plugin-utils@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.18.9.tgz#4b8aea3b069d8cb8a72cdfe28ddf5ceca695ef2f" + integrity sha512-aBXPT3bmtLryXaoJLyYPXPlSD4p1ld9aYeR+sJNOZjJJGiOpb+fKfh3NkcCu7J54nUJwCERPBExCCpyCOHnu/w== + "@babel/helper-remap-async-to-generator@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.18.6.tgz#fa1f81acd19daee9d73de297c0308783cd3cfc23" @@ -344,6 +440,16 @@ "@babel/helper-wrap-function" "^7.18.6" "@babel/types" "^7.18.6" +"@babel/helper-remap-async-to-generator@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.18.9.tgz#997458a0e3357080e54e1d79ec347f8a8cd28519" + integrity sha512-dI7q50YKd8BAv3VEfgg7PS7yD3Rtbi2J1XMXaalXO0W0164hYLnh8zpjRS0mte9MfVp/tltvr/cfdXPvJr1opA== + dependencies: + "@babel/helper-annotate-as-pure" "^7.18.6" + "@babel/helper-environment-visitor" "^7.18.9" + "@babel/helper-wrap-function" "^7.18.9" + "@babel/types" "^7.18.9" + "@babel/helper-replace-supers@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.18.6.tgz#efedf51cfccea7b7b8c0f00002ab317e7abfe420" @@ -355,6 +461,17 @@ "@babel/traverse" "^7.18.6" "@babel/types" "^7.18.6" +"@babel/helper-replace-supers@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.18.9.tgz#1092e002feca980fbbb0bd4d51b74a65c6a500e6" + integrity sha512-dNsWibVI4lNT6HiuOIBr1oyxo40HvIVmbwPUm3XZ7wMh4k2WxrxTqZwSqw/eEmXDS9np0ey5M2bz9tBmO9c+YQ== + dependencies: + "@babel/helper-environment-visitor" "^7.18.9" + "@babel/helper-member-expression-to-functions" "^7.18.9" + "@babel/helper-optimise-call-expression" "^7.18.6" + "@babel/traverse" "^7.18.9" + "@babel/types" "^7.18.9" + "@babel/helper-simple-access@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.18.6.tgz#d6d8f51f4ac2978068df934b569f08f29788c7ea" @@ -369,6 +486,13 @@ dependencies: "@babel/types" "^7.18.6" +"@babel/helper-skip-transparent-expression-wrappers@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.18.9.tgz#778d87b3a758d90b471e7b9918f34a9a02eb5818" + integrity sha512-imytd2gHi3cJPsybLRbmFrF7u5BIEuI2cNheyKi3/iOBC63kNn3q8Crn2xVuESli0aM4KYsyEqKyS7lFL8YVtw== + dependencies: + "@babel/types" "^7.18.9" + "@babel/helper-split-export-declaration@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.18.6.tgz#7367949bc75b20c6d5a5d4a97bba2824ae8ef075" @@ -376,6 +500,11 @@ dependencies: "@babel/types" "^7.18.6" +"@babel/helper-string-parser@^7.18.10": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.18.10.tgz#181f22d28ebe1b3857fa575f5c290b1aaf659b56" + integrity sha512-XtIfWmeNY3i4t7t4D2t02q50HvqHybPqW2ki1kosnvWCwuCMeo81Jf0gwr85jy/neUdg5XDdeFE/80DXiO+njw== + "@babel/helper-validator-identifier@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.18.6.tgz#9c97e30d31b2b8c72a1d08984f2ca9b574d7a076" @@ -396,6 +525,16 @@ "@babel/traverse" "^7.18.6" "@babel/types" "^7.18.6" +"@babel/helper-wrap-function@^7.18.9": + version "7.18.11" + resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.18.11.tgz#bff23ace436e3f6aefb61f85ffae2291c80ed1fb" + integrity sha512-oBUlbv+rjZLh2Ks9SKi4aL7eKaAXBWleHzU89mP0G6BMUlRxSckk9tSIkgDGydhgFxHuGSlBQZfnaD47oBEB7w== + dependencies: + "@babel/helper-function-name" "^7.18.9" + "@babel/template" "^7.18.10" + "@babel/traverse" "^7.18.11" + "@babel/types" "^7.18.10" + "@babel/helpers@^7.12.5", "@babel/helpers@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.18.6.tgz#4c966140eaa1fcaa3d5a8c09d7db61077d4debfd" @@ -405,6 +544,15 @@ "@babel/traverse" "^7.18.6" "@babel/types" "^7.18.6" +"@babel/helpers@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.18.9.tgz#4bef3b893f253a1eced04516824ede94dcfe7ff9" + integrity sha512-Jf5a+rbrLoR4eNdUmnFu8cN5eNJT6qdTdOg5IHIzq87WwyRw9PwguLFOWYgktN/60IP4fgDUawJvs7PjQIzELQ== + dependencies: + "@babel/template" "^7.18.6" + "@babel/traverse" "^7.18.9" + "@babel/types" "^7.18.9" + "@babel/highlight@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.18.6.tgz#81158601e93e2563795adcbfbdf5d64be3f2ecdf" @@ -414,11 +562,16 @@ chalk "^2.0.0" js-tokens "^4.0.0" -"@babel/parser@^7.12.7", "@babel/parser@^7.18.3", "@babel/parser@^7.18.6": +"@babel/parser@^7.12.7", "@babel/parser@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.6.tgz#845338edecad65ebffef058d3be851f1d28a63bc" integrity sha512-uQVSa9jJUe/G/304lXspfWVpKpK4euFLgGiMQFOCpM/bgcAdeoHwi/OQz23O9GK2osz26ZiXRRV9aV+Yl1O8tw== +"@babel/parser@^7.18.10", "@babel/parser@^7.18.11", "@babel/parser@^7.18.8": + version "7.18.11" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.11.tgz#68bb07ab3d380affa9a3f96728df07969645d2d9" + integrity sha512-9JKn5vN+hDt0Hdqn1PiJ2guflwP+B6Ga8qbDuoF0PzzVhrzsKIJo8yGqVk6CmMHiMei9w1C1Bp9IMJSIK+HPIQ== + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.18.6.tgz#da5b8f9a580acdfbe53494dba45ea389fb09a4d2" @@ -435,6 +588,25 @@ "@babel/helper-skip-transparent-expression-wrappers" "^7.18.6" "@babel/plugin-proposal-optional-chaining" "^7.18.6" +"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.18.9.tgz#a11af19aa373d68d561f08e0a57242350ed0ec50" + integrity sha512-AHrP9jadvH7qlOj6PINbgSuphjQUAK7AOT7DPjBo9EHoLhQTnnK5u45e1Hd4DbSQEO9nqPWtQ89r+XEOWFScKg== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/helper-skip-transparent-expression-wrappers" "^7.18.9" + "@babel/plugin-proposal-optional-chaining" "^7.18.9" + +"@babel/plugin-proposal-async-generator-functions@^7.18.10": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.18.10.tgz#85ea478c98b0095c3e4102bff3b67d306ed24952" + integrity sha512-1mFuY2TOsR1hxbjCo4QL+qlIjV07p4H4EUYw2J/WCqsvFV6V9X9z9YhXbWndc/4fw+hYGlDT7egYxliMp5O6Ew== + dependencies: + "@babel/helper-environment-visitor" "^7.18.9" + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/helper-remap-async-to-generator" "^7.18.9" + "@babel/plugin-syntax-async-generators" "^7.8.4" + "@babel/plugin-proposal-async-generator-functions@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.18.6.tgz#aedac81e6fc12bb643374656dd5f2605bf743d17" @@ -478,6 +650,14 @@ "@babel/helper-plugin-utils" "^7.18.6" "@babel/plugin-syntax-export-namespace-from" "^7.8.3" +"@babel/plugin-proposal-export-namespace-from@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.18.9.tgz#5f7313ab348cdb19d590145f9247540e94761203" + integrity sha512-k1NtHyOMvlDDFeb9G5PhUXuGj8m/wiwojgQVEhJ/fsVsMCpLyOP4h0uGEjYJKrRI+EVPlb5Jk+Gt9P97lOGwtA== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + "@babel/plugin-proposal-json-strings@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.18.6.tgz#7e8788c1811c393aff762817e7dbf1ebd0c05f0b" @@ -494,6 +674,14 @@ "@babel/helper-plugin-utils" "^7.18.6" "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" +"@babel/plugin-proposal-logical-assignment-operators@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.18.9.tgz#8148cbb350483bf6220af06fa6db3690e14b2e23" + integrity sha512-128YbMpjCrP35IOExw2Fq+x55LMP42DzhOhX2aNNIdI9avSWl2PI0yuBWarr3RYpZBSPtabfadkH2yeRiMD61Q== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + "@babel/plugin-proposal-nullish-coalescing-operator@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.18.6.tgz#fdd940a99a740e577d6c753ab6fbb43fdb9467e1" @@ -530,6 +718,17 @@ "@babel/plugin-syntax-object-rest-spread" "^7.8.3" "@babel/plugin-transform-parameters" "^7.18.6" +"@babel/plugin-proposal-object-rest-spread@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.18.9.tgz#f9434f6beb2c8cae9dfcf97d2a5941bbbf9ad4e7" + integrity sha512-kDDHQ5rflIeY5xl69CEqGEZ0KY369ehsCIEbTGb4siHG5BE9sga/T0r0OUwyZNLMmZE79E1kbsqAjwFCW4ds6Q== + dependencies: + "@babel/compat-data" "^7.18.8" + "@babel/helper-compilation-targets" "^7.18.9" + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-transform-parameters" "^7.18.8" + "@babel/plugin-proposal-optional-catch-binding@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.18.6.tgz#f9400d0e6a3ea93ba9ef70b09e72dd6da638a2cb" @@ -547,6 +746,15 @@ "@babel/helper-skip-transparent-expression-wrappers" "^7.18.6" "@babel/plugin-syntax-optional-chaining" "^7.8.3" +"@babel/plugin-proposal-optional-chaining@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.18.9.tgz#e8e8fe0723f2563960e4bf5e9690933691915993" + integrity sha512-v5nwt4IqBXihxGsW2QmCWMDS3B3bzGIk/EQVZz2ei7f3NJl8NzAJVvUmpDW5q1CRNY+Beb/k58UAH1Km1N411w== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/helper-skip-transparent-expression-wrappers" "^7.18.9" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + "@babel/plugin-proposal-private-methods@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.18.6.tgz#5209de7d213457548a98436fa2882f52f4be6bea" @@ -729,6 +937,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-block-scoping@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.18.9.tgz#f9b7e018ac3f373c81452d6ada8bd5a18928926d" + integrity sha512-5sDIJRV1KtQVEbt/EIBwGy4T01uYIo4KRB3VUqzkhrAIOGx7AoctL9+Ux88btY0zXdDyPJ9mW+bg+v+XEkGmtw== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-transform-classes@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.18.6.tgz#3501a8f3f4c7d5697c27a3eedbee71d68312669f" @@ -743,6 +958,20 @@ "@babel/helper-split-export-declaration" "^7.18.6" globals "^11.1.0" +"@babel/plugin-transform-classes@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.18.9.tgz#90818efc5b9746879b869d5ce83eb2aa48bbc3da" + integrity sha512-EkRQxsxoytpTlKJmSPYrsOMjCILacAjtSVkd4gChEe2kXjFCun3yohhW5I7plXJhCemM0gKsaGMcO8tinvCA5g== + dependencies: + "@babel/helper-annotate-as-pure" "^7.18.6" + "@babel/helper-environment-visitor" "^7.18.9" + "@babel/helper-function-name" "^7.18.9" + "@babel/helper-optimise-call-expression" "^7.18.6" + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/helper-replace-supers" "^7.18.9" + "@babel/helper-split-export-declaration" "^7.18.6" + globals "^11.1.0" + "@babel/plugin-transform-computed-properties@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.18.6.tgz#5d15eb90e22e69604f3348344c91165c5395d032" @@ -750,6 +979,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-computed-properties@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.18.9.tgz#2357a8224d402dad623caf6259b611e56aec746e" + integrity sha512-+i0ZU1bCDymKakLxn5srGHrsAPRELC2WIbzwjLhHW9SIE1cPYkLCL0NlnXMZaM1vhfgA2+M7hySk42VBvrkBRw== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-transform-destructuring@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.18.6.tgz#a98b0e42c7ffbf5eefcbcf33280430f230895c6f" @@ -757,6 +993,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-destructuring@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.18.9.tgz#68906549c021cb231bee1db21d3b5b095f8ee292" + integrity sha512-p5VCYNddPLkZTq4XymQIaIfZNJwT9YsjkPOhkVEqt6QIpQFZVM9IltqqYpOEkJoN1DPznmxUDyZ5CTZs/ZCuHA== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-transform-dotall-regex@^7.18.6", "@babel/plugin-transform-dotall-regex@^7.4.4": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.18.6.tgz#b286b3e7aae6c7b861e45bed0a2fafd6b1a4fef8" @@ -772,6 +1015,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-duplicate-keys@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.18.9.tgz#687f15ee3cdad6d85191eb2a372c4528eaa0ae0e" + integrity sha512-d2bmXCtZXYc59/0SanQKbiWINadaJXqtvIQIzd4+hNwkWBgyCd5F/2t1kXoUdvPMrxzPvhK6EMQRROxsue+mfw== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-transform-exponentiation-operator@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.18.6.tgz#421c705f4521888c65e91fdd1af951bfefd4dacd" @@ -787,6 +1037,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-for-of@^7.18.8": + version "7.18.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.18.8.tgz#6ef8a50b244eb6a0bdbad0c7c61877e4e30097c1" + integrity sha512-yEfTRnjuskWYo0k1mHUqrVWaZwrdq8AYbfrpqULOJOaucGSp4mNMVps+YtA8byoevxS/urwU75vyhQIxcCgiBQ== + dependencies: + "@babel/helper-plugin-utils" "^7.18.6" + "@babel/plugin-transform-function-name@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.18.6.tgz#6a7e4ae2893d336fd1b8f64c9f92276391d0f1b4" @@ -796,6 +1053,15 @@ "@babel/helper-function-name" "^7.18.6" "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-function-name@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.18.9.tgz#cc354f8234e62968946c61a46d6365440fc764e0" + integrity sha512-WvIBoRPaJQ5yVHzcnJFor7oS5Ls0PYixlTYE63lCj2RtdQEl15M68FXQlxnG6wdraJIXRdR7KI+hQ7q/9QjrCQ== + dependencies: + "@babel/helper-compilation-targets" "^7.18.9" + "@babel/helper-function-name" "^7.18.9" + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-transform-literals@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.18.6.tgz#9d6af353b5209df72960baf4492722d56f39a205" @@ -803,6 +1069,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-literals@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.18.9.tgz#72796fdbef80e56fba3c6a699d54f0de557444bc" + integrity sha512-IFQDSRoTPnrAIrI5zoZv73IFeZu2dhu6irxQjY9rNjTT53VmKg9fenjvoiOWOkJ6mm4jKVPtdMzBY98Fp4Z4cg== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-transform-member-expression-literals@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.18.6.tgz#ac9fdc1a118620ac49b7e7a5d2dc177a1bfee88e" @@ -840,6 +1113,17 @@ "@babel/helper-validator-identifier" "^7.18.6" babel-plugin-dynamic-import-node "^2.3.3" +"@babel/plugin-transform-modules-systemjs@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.18.9.tgz#545df284a7ac6a05125e3e405e536c5853099a06" + integrity sha512-zY/VSIbbqtoRoJKo2cDTewL364jSlZGvn0LKOf9ntbfxOvjfmyrdtEEOAdswOswhZEb8UH3jDkCKHd1sPgsS0A== + dependencies: + "@babel/helper-hoist-variables" "^7.18.6" + "@babel/helper-module-transforms" "^7.18.9" + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/helper-validator-identifier" "^7.18.6" + babel-plugin-dynamic-import-node "^2.3.3" + "@babel/plugin-transform-modules-umd@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.18.6.tgz#81d3832d6034b75b54e62821ba58f28ed0aab4b9" @@ -878,6 +1162,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-parameters@^7.18.8": + version "7.18.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.18.8.tgz#ee9f1a0ce6d78af58d0956a9378ea3427cccb48a" + integrity sha512-ivfbE3X2Ss+Fj8nnXvKJS6sjRG4gzwPMsP+taZC+ZzEGjAYlvENixmt1sZ5Ca6tWls+BlKSGKPJ6OOXvXCbkFg== + dependencies: + "@babel/helper-plugin-utils" "^7.18.6" + "@babel/plugin-transform-property-literals@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.18.6.tgz#e22498903a483448e94e032e9bbb9c5ccbfc93a3" @@ -940,16 +1231,16 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" -"@babel/plugin-transform-runtime@^7.18.2": - version "7.18.6" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.18.6.tgz#77b14416015ea93367ca06979710f5000ff34ccb" - integrity sha512-8uRHk9ZmRSnWqUgyae249EJZ94b0yAGLBIqzZzl+0iEdbno55Pmlt/32JZsHwXD9k/uZj18Aqqk35wBX4CBTXA== +"@babel/plugin-transform-runtime@^7.18.6": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.18.10.tgz#37d14d1fa810a368fd635d4d1476c0154144a96f" + integrity sha512-q5mMeYAdfEbpBAgzl7tBre/la3LeCxmDO1+wMXRdPWbcoMjR3GiXlCLk7JBZVVye0bqTGNMbt0yYVXX1B1jEWQ== dependencies: "@babel/helper-module-imports" "^7.18.6" - "@babel/helper-plugin-utils" "^7.18.6" - babel-plugin-polyfill-corejs2 "^0.3.1" - babel-plugin-polyfill-corejs3 "^0.5.2" - babel-plugin-polyfill-regenerator "^0.3.1" + "@babel/helper-plugin-utils" "^7.18.9" + babel-plugin-polyfill-corejs2 "^0.3.2" + babel-plugin-polyfill-corejs3 "^0.5.3" + babel-plugin-polyfill-regenerator "^0.4.0" semver "^6.3.0" "@babel/plugin-transform-shorthand-properties@^7.18.6": @@ -967,6 +1258,14 @@ "@babel/helper-plugin-utils" "^7.18.6" "@babel/helper-skip-transparent-expression-wrappers" "^7.18.6" +"@babel/plugin-transform-spread@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.18.9.tgz#6ea7a6297740f381c540ac56caf75b05b74fb664" + integrity sha512-39Q814wyoOPtIB/qGopNIL9xDChOE1pNU0ZY5dO0owhiVt/5kFm4li+/bBtwc7QotG0u5EPzqhZdjMtmqBqyQA== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/helper-skip-transparent-expression-wrappers" "^7.18.9" + "@babel/plugin-transform-sticky-regex@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.18.6.tgz#c6706eb2b1524028e317720339583ad0f444adcc" @@ -981,6 +1280,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-template-literals@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.18.9.tgz#04ec6f10acdaa81846689d63fae117dd9c243a5e" + integrity sha512-S8cOWfT82gTezpYOiVaGHrCbhlHgKhQt8XH5ES46P2XWmX92yisoZywf5km75wv5sYcXDUCLMmMxOLCtthDgMA== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-transform-typeof-symbol@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.18.6.tgz#486bb39d5a18047358e0d04dc0d2f322f0b92e92" @@ -988,6 +1294,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.18.6" +"@babel/plugin-transform-typeof-symbol@^7.18.9": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.18.9.tgz#c8cea68263e45addcd6afc9091429f80925762c0" + integrity sha512-SRfwTtF11G2aemAZWivL7PD+C9z52v9EvMqH9BuYbabyPuKUvSWks3oCg6041pT925L4zVFqaVBeECwsmlguEw== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-transform-typescript@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.18.6.tgz#8f4ade1a9cf253e5cf7c7c20173082c2c08a50a7" @@ -997,6 +1310,13 @@ "@babel/helper-plugin-utils" "^7.18.6" "@babel/plugin-syntax-typescript" "^7.18.6" +"@babel/plugin-transform-unicode-escapes@^7.18.10": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.18.10.tgz#1ecfb0eda83d09bbcb77c09970c2dd55832aa246" + integrity sha512-kKAdAI+YzPgGY/ftStBFXTI1LZFju38rYThnfMykS+IXy8BVx+res7s2fxf1l8I35DV2T97ezo6+SGrXz6B3iQ== + dependencies: + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/plugin-transform-unicode-escapes@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.18.6.tgz#0d01fb7fb2243ae1c033f65f6e3b4be78db75f27" @@ -1012,7 +1332,7 @@ "@babel/helper-create-regexp-features-plugin" "^7.18.6" "@babel/helper-plugin-utils" "^7.18.6" -"@babel/preset-env@^7.15.6", "@babel/preset-env@^7.18.2": +"@babel/preset-env@^7.15.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.18.6.tgz#953422e98a5f66bc56cd0b9074eaea127ec86ace" integrity sha512-WrthhuIIYKrEFAwttYzgRNQ5hULGmwTj+D6l7Zdfsv5M7IWV/OZbUfbeL++Qrzx1nVJwWROIFhCHRYQV4xbPNw== @@ -1093,6 +1413,87 @@ core-js-compat "^3.22.1" semver "^6.3.0" +"@babel/preset-env@^7.18.6": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.18.10.tgz#83b8dfe70d7eea1aae5a10635ab0a5fe60dfc0f4" + integrity sha512-wVxs1yjFdW3Z/XkNfXKoblxoHgbtUF7/l3PvvP4m02Qz9TZ6uZGxRVYjSQeR87oQmHco9zWitW5J82DJ7sCjvA== + dependencies: + "@babel/compat-data" "^7.18.8" + "@babel/helper-compilation-targets" "^7.18.9" + "@babel/helper-plugin-utils" "^7.18.9" + "@babel/helper-validator-option" "^7.18.6" + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression" "^7.18.6" + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.18.9" + "@babel/plugin-proposal-async-generator-functions" "^7.18.10" + "@babel/plugin-proposal-class-properties" "^7.18.6" + "@babel/plugin-proposal-class-static-block" "^7.18.6" + "@babel/plugin-proposal-dynamic-import" "^7.18.6" + "@babel/plugin-proposal-export-namespace-from" "^7.18.9" + "@babel/plugin-proposal-json-strings" "^7.18.6" + "@babel/plugin-proposal-logical-assignment-operators" "^7.18.9" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.18.6" + "@babel/plugin-proposal-numeric-separator" "^7.18.6" + "@babel/plugin-proposal-object-rest-spread" "^7.18.9" + "@babel/plugin-proposal-optional-catch-binding" "^7.18.6" + "@babel/plugin-proposal-optional-chaining" "^7.18.9" + "@babel/plugin-proposal-private-methods" "^7.18.6" + "@babel/plugin-proposal-private-property-in-object" "^7.18.6" + "@babel/plugin-proposal-unicode-property-regex" "^7.18.6" + "@babel/plugin-syntax-async-generators" "^7.8.4" + "@babel/plugin-syntax-class-properties" "^7.12.13" + "@babel/plugin-syntax-class-static-block" "^7.14.5" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + "@babel/plugin-syntax-import-assertions" "^7.18.6" + "@babel/plugin-syntax-json-strings" "^7.8.3" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + "@babel/plugin-syntax-private-property-in-object" "^7.14.5" + "@babel/plugin-syntax-top-level-await" "^7.14.5" + "@babel/plugin-transform-arrow-functions" "^7.18.6" + "@babel/plugin-transform-async-to-generator" "^7.18.6" + "@babel/plugin-transform-block-scoped-functions" "^7.18.6" + "@babel/plugin-transform-block-scoping" "^7.18.9" + "@babel/plugin-transform-classes" "^7.18.9" + "@babel/plugin-transform-computed-properties" "^7.18.9" + "@babel/plugin-transform-destructuring" "^7.18.9" + "@babel/plugin-transform-dotall-regex" "^7.18.6" + "@babel/plugin-transform-duplicate-keys" "^7.18.9" + "@babel/plugin-transform-exponentiation-operator" "^7.18.6" + "@babel/plugin-transform-for-of" "^7.18.8" + "@babel/plugin-transform-function-name" "^7.18.9" + "@babel/plugin-transform-literals" "^7.18.9" + "@babel/plugin-transform-member-expression-literals" "^7.18.6" + "@babel/plugin-transform-modules-amd" "^7.18.6" + "@babel/plugin-transform-modules-commonjs" "^7.18.6" + "@babel/plugin-transform-modules-systemjs" "^7.18.9" + "@babel/plugin-transform-modules-umd" "^7.18.6" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.18.6" + "@babel/plugin-transform-new-target" "^7.18.6" + "@babel/plugin-transform-object-super" "^7.18.6" + "@babel/plugin-transform-parameters" "^7.18.8" + "@babel/plugin-transform-property-literals" "^7.18.6" + "@babel/plugin-transform-regenerator" "^7.18.6" + "@babel/plugin-transform-reserved-words" "^7.18.6" + "@babel/plugin-transform-shorthand-properties" "^7.18.6" + "@babel/plugin-transform-spread" "^7.18.9" + "@babel/plugin-transform-sticky-regex" "^7.18.6" + "@babel/plugin-transform-template-literals" "^7.18.9" + "@babel/plugin-transform-typeof-symbol" "^7.18.9" + "@babel/plugin-transform-unicode-escapes" "^7.18.10" + "@babel/plugin-transform-unicode-regex" "^7.18.6" + "@babel/preset-modules" "^0.1.5" + "@babel/types" "^7.18.10" + babel-plugin-polyfill-corejs2 "^0.3.2" + babel-plugin-polyfill-corejs3 "^0.5.3" + babel-plugin-polyfill-regenerator "^0.4.0" + core-js-compat "^3.22.1" + semver "^6.3.0" + "@babel/preset-modules@^0.1.5": version "0.1.5" resolved "https://registry.yarnpkg.com/@babel/preset-modules/-/preset-modules-0.1.5.tgz#ef939d6e7f268827e1841638dc6ff95515e115d9" @@ -1104,7 +1505,7 @@ "@babel/types" "^7.4.4" esutils "^2.0.2" -"@babel/preset-react@^7.14.5", "@babel/preset-react@^7.17.12": +"@babel/preset-react@^7.14.5", "@babel/preset-react@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/preset-react/-/preset-react-7.18.6.tgz#979f76d6277048dc19094c217b507f3ad517dd2d" integrity sha512-zXr6atUmyYdiWRVLOZahakYmOBHtWc2WGCkP8PYTgZi0iJXDY2CN180TdrIW4OGOAdLc7TifzDIvtx6izaRIzg== @@ -1116,7 +1517,7 @@ "@babel/plugin-transform-react-jsx-development" "^7.18.6" "@babel/plugin-transform-react-pure-annotations" "^7.18.6" -"@babel/preset-typescript@^7.15.0", "@babel/preset-typescript@^7.17.12": +"@babel/preset-typescript@^7.15.0", "@babel/preset-typescript@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/preset-typescript/-/preset-typescript-7.18.6.tgz#ce64be3e63eddc44240c6358daefac17b3186399" integrity sha512-s9ik86kXBAnD760aybBucdpnLsAt0jK1xqJn2juOn9lkOvSHV60os5hxoVJsPzMQxvnUJFAlkont2DvvaYEBtQ== @@ -1125,21 +1526,28 @@ "@babel/helper-validator-option" "^7.18.6" "@babel/plugin-transform-typescript" "^7.18.6" -"@babel/runtime-corejs3@^7.18.3": - version "7.18.6" - resolved "https://registry.yarnpkg.com/@babel/runtime-corejs3/-/runtime-corejs3-7.18.6.tgz#6f02c5536911f4b445946a2179554b95c8838635" - integrity sha512-cOu5wH2JFBgMjje+a+fz2JNIWU4GzYpl05oSob3UDvBEh6EuIn+TXFHMmBbhSb+k/4HMzgKCQfEEDArAWNF9Cw== +"@babel/runtime-corejs3@^7.18.6": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/runtime-corejs3/-/runtime-corejs3-7.18.9.tgz#7bacecd1cb2dd694eacd32a91fcf7021c20770ae" + integrity sha512-qZEWeccZCrHA2Au4/X05QW5CMdm4VjUDCrGq5gf1ZDcM4hRqreKrtwAn7yci9zfgAS9apvnsFXiGBHBAxZdK9A== dependencies: core-js-pure "^3.20.2" regenerator-runtime "^0.13.4" -"@babel/runtime@^7.1.2", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.3", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.13", "@babel/runtime@^7.12.5", "@babel/runtime@^7.18.3", "@babel/runtime@^7.8.4": +"@babel/runtime@^7.1.2", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.3", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.13", "@babel/runtime@^7.12.5", "@babel/runtime@^7.8.4": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.18.6.tgz#6a1ef59f838debd670421f8c7f2cbb8da9751580" integrity sha512-t9wi7/AW6XtKahAe20Yw0/mMljKq0B1r2fPdvaAdV/KPDZewFXdaaa6K7lxmZBZ8FBNpCiAT6iHPmd6QO9bKfQ== dependencies: regenerator-runtime "^0.13.4" +"@babel/runtime@^7.18.6": + version "7.18.9" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.18.9.tgz#b4fcfce55db3d2e5e080d2490f608a3b9f407f4a" + integrity sha512-lkqXDcvlFT5rvEjiu6+QYO+1GXrEHRo2LOtS7E4GtX5ESIZOgepqsZBVIj6Pv+a6zqsya9VCgiK1KAK4BvJDAw== + dependencies: + regenerator-runtime "^0.13.4" + "@babel/template@^7.12.7", "@babel/template@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.18.6.tgz#1283f4993e00b929d6e2d3c72fdc9168a2977a31" @@ -1149,7 +1557,16 @@ "@babel/parser" "^7.18.6" "@babel/types" "^7.18.6" -"@babel/traverse@^7.12.9", "@babel/traverse@^7.13.0", "@babel/traverse@^7.18.2", "@babel/traverse@^7.18.6": +"@babel/template@^7.18.10": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.18.10.tgz#6f9134835970d1dbf0835c0d100c9f38de0c5e71" + integrity sha512-TI+rCtooWHr3QJ27kJxfjutghu44DLnasDMwpDqCXVTal9RLp3RSYNh4NdBrRP2cQAoG9A8juOQl6P6oZG4JxA== + dependencies: + "@babel/code-frame" "^7.18.6" + "@babel/parser" "^7.18.10" + "@babel/types" "^7.18.10" + +"@babel/traverse@^7.12.9", "@babel/traverse@^7.13.0", "@babel/traverse@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.18.6.tgz#a228562d2f46e89258efa4ddd0416942e2fd671d" integrity sha512-zS/OKyqmD7lslOtFqbscH6gMLFYOfG1YPqCKfAW5KrTeolKqvB8UelR49Fpr6y93kYkW2Ik00mT1LOGiAGvizw== @@ -1165,6 +1582,22 @@ debug "^4.1.0" globals "^11.1.0" +"@babel/traverse@^7.18.10", "@babel/traverse@^7.18.11", "@babel/traverse@^7.18.8", "@babel/traverse@^7.18.9": + version "7.18.11" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.18.11.tgz#3d51f2afbd83ecf9912bcbb5c4d94e3d2ddaa16f" + integrity sha512-TG9PiM2R/cWCAy6BPJKeHzNbu4lPzOSZpeMfeNErskGpTJx6trEvFaVCbDvpcxwy49BKWmEPwiW8mrysNiDvIQ== + dependencies: + "@babel/code-frame" "^7.18.6" + "@babel/generator" "^7.18.10" + "@babel/helper-environment-visitor" "^7.18.9" + "@babel/helper-function-name" "^7.18.9" + "@babel/helper-hoist-variables" "^7.18.6" + "@babel/helper-split-export-declaration" "^7.18.6" + "@babel/parser" "^7.18.11" + "@babel/types" "^7.18.10" + debug "^4.1.0" + globals "^11.1.0" + "@babel/types@^7.12.7", "@babel/types@^7.15.6", "@babel/types@^7.18.6", "@babel/types@^7.18.7", "@babel/types@^7.4.4": version "7.18.7" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.18.7.tgz#a4a2c910c15040ea52cdd1ddb1614a65c8041726" @@ -1173,49 +1606,58 @@ "@babel/helper-validator-identifier" "^7.18.6" to-fast-properties "^2.0.0" +"@babel/types@^7.18.10", "@babel/types@^7.18.9": + version "7.18.10" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.18.10.tgz#4908e81b6b339ca7c6b7a555a5fc29446f26dde6" + integrity sha512-MJvnbEiiNkpjo+LknnmRrqbY1GPUUggjv+wQVjetM/AONoupqRALB7I6jGqNUAZsKcRIEu2J6FRFvsczljjsaQ== + dependencies: + "@babel/helper-string-parser" "^7.18.10" + "@babel/helper-validator-identifier" "^7.18.6" + to-fast-properties "^2.0.0" + "@colors/colors@1.5.0": version "1.5.0" resolved "https://registry.yarnpkg.com/@colors/colors/-/colors-1.5.0.tgz#bb504579c1cae923e6576a4f5da43d25f97bdbd9" integrity sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ== -"@docsearch/css@3.1.1": - version "3.1.1" - resolved "https://registry.yarnpkg.com/@docsearch/css/-/css-3.1.1.tgz#e0976bf995e383f8ee8657306311b9cb95016330" - integrity sha512-utLgg7E1agqQeqCJn05DWC7XXMk4tMUUnL7MZupcknRu2OzGN13qwey2qA/0NAKkVBGugiWtON0+rlU0QIPojg== +"@docsearch/css@3.2.1": + version "3.2.1" + resolved "https://registry.yarnpkg.com/@docsearch/css/-/css-3.2.1.tgz#c05d7818b0e43b42f9efa2d82a11c36606b37b27" + integrity sha512-gaP6TxxwQC+K8D6TRx5WULUWKrcbzECOPA2KCVMuI+6C7dNiGUk5yXXzVhc5sld79XKYLnO9DRTI4mjXDYkh+g== -"@docsearch/react@^3.1.0": - version "3.1.1" - resolved "https://registry.yarnpkg.com/@docsearch/react/-/react-3.1.1.tgz#3dffb5db8cf9eb95d6e732cf038264bfc10191ed" - integrity sha512-cfoql4qvtsVRqBMYxhlGNpvyy/KlCoPqjIsJSZYqYf9AplZncKjLBTcwBu6RXFMVCe30cIFljniI4OjqAU67pQ== +"@docsearch/react@^3.1.1": + version "3.2.1" + resolved "https://registry.yarnpkg.com/@docsearch/react/-/react-3.2.1.tgz#112ad88db07367fa6fd933d67d58421d8d8289aa" + integrity sha512-EzTQ/y82s14IQC5XVestiK/kFFMe2aagoYFuTAIfIb/e+4FU7kSMKonRtLwsCiLQHmjvNQq+HO+33giJ5YVtaQ== dependencies: "@algolia/autocomplete-core" "1.7.1" "@algolia/autocomplete-preset-algolia" "1.7.1" - "@docsearch/css" "3.1.1" + "@docsearch/css" "3.2.1" algoliasearch "^4.0.0" -"@docusaurus/core@2.0.0-beta.21", "@docusaurus/core@^2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/core/-/core-2.0.0-beta.21.tgz#50897317b22dbd94b1bf91bb30c2a0fddd15a806" - integrity sha512-qysDMVp1M5UozK3u/qOxsEZsHF7jeBvJDS+5ItMPYmNKvMbNKeYZGA0g6S7F9hRDwjIlEbvo7BaX0UMDcmTAWA== +"@docusaurus/core@2.0.1", "@docusaurus/core@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/core/-/core-2.0.1.tgz#a2b0d653e8f18eacddda4778a46b638dd1f0f45c" + integrity sha512-Prd46TtZdiixlTl8a+h9bI5HegkfREjSNkrX2rVEwJZeziSz4ya+l7QDnbnCB2XbxEG8cveFo/F9q5lixolDtQ== dependencies: - "@babel/core" "^7.18.2" - "@babel/generator" "^7.18.2" + "@babel/core" "^7.18.6" + "@babel/generator" "^7.18.7" "@babel/plugin-syntax-dynamic-import" "^7.8.3" - "@babel/plugin-transform-runtime" "^7.18.2" - "@babel/preset-env" "^7.18.2" - "@babel/preset-react" "^7.17.12" - "@babel/preset-typescript" "^7.17.12" - "@babel/runtime" "^7.18.3" - "@babel/runtime-corejs3" "^7.18.3" - "@babel/traverse" "^7.18.2" - "@docusaurus/cssnano-preset" "2.0.0-beta.21" - "@docusaurus/logger" "2.0.0-beta.21" - "@docusaurus/mdx-loader" "2.0.0-beta.21" + "@babel/plugin-transform-runtime" "^7.18.6" + "@babel/preset-env" "^7.18.6" + "@babel/preset-react" "^7.18.6" + "@babel/preset-typescript" "^7.18.6" + "@babel/runtime" "^7.18.6" + "@babel/runtime-corejs3" "^7.18.6" + "@babel/traverse" "^7.18.8" + "@docusaurus/cssnano-preset" "2.0.1" + "@docusaurus/logger" "2.0.1" + "@docusaurus/mdx-loader" "2.0.1" "@docusaurus/react-loadable" "5.5.2" - "@docusaurus/utils" "2.0.0-beta.21" - "@docusaurus/utils-common" "2.0.0-beta.21" - "@docusaurus/utils-validation" "2.0.0-beta.21" - "@slorber/static-site-generator-webpack-plugin" "^4.0.4" + "@docusaurus/utils" "2.0.1" + "@docusaurus/utils-common" "2.0.1" + "@docusaurus/utils-validation" "2.0.1" + "@slorber/static-site-generator-webpack-plugin" "^4.0.7" "@svgr/webpack" "^6.2.1" autoprefixer "^10.4.7" babel-loader "^8.2.5" @@ -1228,10 +1670,10 @@ combine-promises "^1.1.0" commander "^5.1.0" copy-webpack-plugin "^11.0.0" - core-js "^3.22.7" + core-js "^3.23.3" css-loader "^6.7.1" css-minimizer-webpack-plugin "^4.0.0" - cssnano "^5.1.9" + cssnano "^5.1.12" del "^6.1.1" detect-port "^1.3.0" escape-html "^1.0.3" @@ -1244,7 +1686,7 @@ import-fresh "^3.3.0" leven "^3.1.0" lodash "^4.17.21" - mini-css-extract-plugin "^2.6.0" + mini-css-extract-plugin "^2.6.1" postcss "^8.4.14" postcss-loader "^7.0.0" prompts "^2.4.2" @@ -1255,49 +1697,48 @@ react-router "^5.3.3" react-router-config "^5.1.1" react-router-dom "^5.3.3" - remark-admonitions "^1.2.1" rtl-detect "^1.0.4" semver "^7.3.7" serve-handler "^6.1.3" shelljs "^0.8.5" - terser-webpack-plugin "^5.3.1" + terser-webpack-plugin "^5.3.3" tslib "^2.4.0" update-notifier "^5.1.0" url-loader "^4.1.1" wait-on "^6.0.1" - webpack "^5.72.1" + webpack "^5.73.0" webpack-bundle-analyzer "^4.5.0" - webpack-dev-server "^4.9.0" + webpack-dev-server "^4.9.3" webpack-merge "^5.8.0" webpackbar "^5.0.2" -"@docusaurus/cssnano-preset@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/cssnano-preset/-/cssnano-preset-2.0.0-beta.21.tgz#38113877a5857c3f9d493522085d20909dcec474" - integrity sha512-fhTZrg1vc6zYYZIIMXpe1TnEVGEjqscBo0s1uomSwKjjtMgu7wkzc1KKJYY7BndsSA+fVVkZ+OmL/kAsmK7xxw== +"@docusaurus/cssnano-preset@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/cssnano-preset/-/cssnano-preset-2.0.1.tgz#4d0c49338cf3aa88c5bd7cffbf77654db8e1e3b2" + integrity sha512-MCJ6rRmlqLmlCsZIoIxOxDb0rYzIPEm9PYpsBW+CGNnbk+x8xK+11hnrxzvXHqDRNpxrq3Kq2jYUmg/DkqE6vg== dependencies: - cssnano-preset-advanced "^5.3.5" + cssnano-preset-advanced "^5.3.8" postcss "^8.4.14" postcss-sort-media-queries "^4.2.1" tslib "^2.4.0" -"@docusaurus/logger@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/logger/-/logger-2.0.0-beta.21.tgz#f6ab4133917965349ae03fd9111a940b24d4fd12" - integrity sha512-HTFp8FsSMrAj7Uxl5p72U+P7rjYU/LRRBazEoJbs9RaqoKEdtZuhv8MYPOCh46K9TekaoquRYqag2o23Qt4ggA== +"@docusaurus/logger@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/logger/-/logger-2.0.1.tgz#78a940a333d2f654fd9dea24db2c962034d4b1ff" + integrity sha512-wIWseCKko1w/WARcDjO3N/XoJ0q/VE42AthP0eNAfEazDjJ94NXbaI6wuUsuY/bMg6hTKGVIpphjj2LoX3g6dA== dependencies: chalk "^4.1.2" tslib "^2.4.0" -"@docusaurus/mdx-loader@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/mdx-loader/-/mdx-loader-2.0.0-beta.21.tgz#52af341e21f22be882d2155a7349bea10f5d77a3" - integrity sha512-AI+4obJnpOaBOAYV6df2ux5Y1YJCBS+MhXFf0yhED12sVLJi2vffZgdamYd/d/FwvWDw6QLs/VD2jebd7P50yQ== +"@docusaurus/mdx-loader@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/mdx-loader/-/mdx-loader-2.0.1.tgz#cc73690ca5d356687d9e75740560b4159cd5cdb5" + integrity sha512-tdNeljdilXCmhbaEND3SAgsqaw/oh7v9onT5yrIrL26OSk2AFwd+MIi4R8jt8vq33M0R4rz2wpknm0fQIkDdvQ== dependencies: - "@babel/parser" "^7.18.3" - "@babel/traverse" "^7.18.2" - "@docusaurus/logger" "2.0.0-beta.21" - "@docusaurus/utils" "2.0.0-beta.21" + "@babel/parser" "^7.18.8" + "@babel/traverse" "^7.18.8" + "@docusaurus/logger" "2.0.1" + "@docusaurus/utils" "2.0.1" "@mdx-js/mdx" "^1.6.22" escape-html "^1.0.3" file-loader "^6.2.0" @@ -1307,136 +1748,147 @@ remark-emoji "^2.2.0" stringify-object "^3.3.0" tslib "^2.4.0" + unified "^9.2.2" unist-util-visit "^2.0.3" url-loader "^4.1.1" - webpack "^5.72.1" + webpack "^5.73.0" -"@docusaurus/module-type-aliases@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/module-type-aliases/-/module-type-aliases-2.0.0-beta.21.tgz#345f1c1a99407775d1d3ffc1a90c2df93d50a9b8" - integrity sha512-gRkWICgQZiqSJgrwRKWjXm5gAB+9IcfYdUbCG0PRPP/G8sNs9zBIOY4uT4Z5ox2CWFEm44U3RTTxj7BiLVMBXw== +"@docusaurus/module-type-aliases@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/module-type-aliases/-/module-type-aliases-2.0.1.tgz#44d7132297bedae0890695b0e7ebbe14a73e26d1" + integrity sha512-f888ylnxHAM/3T8p1lx08+lTc6/g7AweSRfRuZvrVhHXj3Tz/nTTxaP6gPTGkJK7WLqTagpar/IGP6/74IBbkg== dependencies: - "@docusaurus/types" "2.0.0-beta.21" + "@docusaurus/react-loadable" "5.5.2" + "@docusaurus/types" "2.0.1" + "@types/history" "^4.7.11" "@types/react" "*" "@types/react-router-config" "*" "@types/react-router-dom" "*" react-helmet-async "*" + react-loadable "npm:@docusaurus/react-loadable@5.5.2" -"@docusaurus/plugin-content-blog@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/plugin-content-blog/-/plugin-content-blog-2.0.0-beta.21.tgz#86211deeea901ddcd77ca387778e121e93ee8d01" - integrity sha512-IP21yJViP3oBmgsWBU5LhrG1MZXV4mYCQSoCAboimESmy1Z11RCNP2tXaqizE3iTmXOwZZL+SNBk06ajKCEzWg== - dependencies: - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/logger" "2.0.0-beta.21" - "@docusaurus/mdx-loader" "2.0.0-beta.21" - "@docusaurus/utils" "2.0.0-beta.21" - "@docusaurus/utils-common" "2.0.0-beta.21" - "@docusaurus/utils-validation" "2.0.0-beta.21" - cheerio "^1.0.0-rc.11" +"@docusaurus/plugin-content-blog@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/plugin-content-blog/-/plugin-content-blog-2.0.1.tgz#a37065e18ffd26e022ffb16a21ff28199140729e" + integrity sha512-/4ua3iFYcpwgpeYgHnhVGROB/ybnauLH2+rICb4vz/+Gn1hjAmGXVYq1fk8g49zGs3uxx5nc0H5bL9P0g977IQ== + dependencies: + "@docusaurus/core" "2.0.1" + "@docusaurus/logger" "2.0.1" + "@docusaurus/mdx-loader" "2.0.1" + "@docusaurus/types" "2.0.1" + "@docusaurus/utils" "2.0.1" + "@docusaurus/utils-common" "2.0.1" + "@docusaurus/utils-validation" "2.0.1" + cheerio "^1.0.0-rc.12" feed "^4.2.2" fs-extra "^10.1.0" lodash "^4.17.21" reading-time "^1.5.0" - remark-admonitions "^1.2.1" tslib "^2.4.0" unist-util-visit "^2.0.3" utility-types "^3.10.0" - webpack "^5.72.1" - -"@docusaurus/plugin-content-docs@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/plugin-content-docs/-/plugin-content-docs-2.0.0-beta.21.tgz#b3171fa9aed99e367b6eb7111187bd0e3dcf2949" - integrity sha512-aa4vrzJy4xRy81wNskyhE3wzRf3AgcESZ1nfKh8xgHUkT7fDTZ1UWlg50Jb3LBCQFFyQG2XQB9N6llskI/KUnw== - dependencies: - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/logger" "2.0.0-beta.21" - "@docusaurus/mdx-loader" "2.0.0-beta.21" - "@docusaurus/utils" "2.0.0-beta.21" - "@docusaurus/utils-validation" "2.0.0-beta.21" + webpack "^5.73.0" + +"@docusaurus/plugin-content-docs@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/plugin-content-docs/-/plugin-content-docs-2.0.1.tgz#4059591b4bff617e744e856ca680674b27c0b98a" + integrity sha512-2qeBWRy1EjgnXdwAO6/csDIS1UVNmhmtk/bQ2s9jqjpwM8YVgZ8QVdkxFAMWXgZWDQdwWwdP1rnmoEelE4HknQ== + dependencies: + "@docusaurus/core" "2.0.1" + "@docusaurus/logger" "2.0.1" + "@docusaurus/mdx-loader" "2.0.1" + "@docusaurus/module-type-aliases" "2.0.1" + "@docusaurus/types" "2.0.1" + "@docusaurus/utils" "2.0.1" + "@docusaurus/utils-validation" "2.0.1" + "@types/react-router-config" "^5.0.6" combine-promises "^1.1.0" fs-extra "^10.1.0" import-fresh "^3.3.0" js-yaml "^4.1.0" lodash "^4.17.21" - remark-admonitions "^1.2.1" tslib "^2.4.0" utility-types "^3.10.0" - webpack "^5.72.1" + webpack "^5.73.0" -"@docusaurus/plugin-content-pages@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/plugin-content-pages/-/plugin-content-pages-2.0.0-beta.21.tgz#df6b4c5c4cde8a0ea491a30002e84941ca7bf0cf" - integrity sha512-DmXOXjqNI+7X5hISzCvt54QIK6XBugu2MOxjxzuqI7q92Lk/EVdraEj5mthlH8IaEH/VlpWYJ1O9TzLqX5vH2g== - dependencies: - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/mdx-loader" "2.0.0-beta.21" - "@docusaurus/utils" "2.0.0-beta.21" - "@docusaurus/utils-validation" "2.0.0-beta.21" +"@docusaurus/plugin-content-pages@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/plugin-content-pages/-/plugin-content-pages-2.0.1.tgz#013f2e66f80d19b5c95a2d941d67c7cdb67b7191" + integrity sha512-6apSVeJENnNecAH5cm5VnRqR103M6qSI6IuiP7tVfD5H4AWrfDNkvJQV2+R2PIq3bGrwmX4fcXl1x4g0oo7iwA== + dependencies: + "@docusaurus/core" "2.0.1" + "@docusaurus/mdx-loader" "2.0.1" + "@docusaurus/types" "2.0.1" + "@docusaurus/utils" "2.0.1" + "@docusaurus/utils-validation" "2.0.1" fs-extra "^10.1.0" - remark-admonitions "^1.2.1" tslib "^2.4.0" - webpack "^5.72.1" + webpack "^5.73.0" -"@docusaurus/plugin-debug@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/plugin-debug/-/plugin-debug-2.0.0-beta.21.tgz#dfa212fd90fe2f54439aacdc8c143e8ce96b0d27" - integrity sha512-P54J4q4ecsyWW0Jy4zbimSIHna999AfbxpXGmF1IjyHrjoA3PtuakV1Ai51XrGEAaIq9q6qMQkEhbUd3CffGAw== +"@docusaurus/plugin-debug@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/plugin-debug/-/plugin-debug-2.0.1.tgz#2b2a473f8e01fd356e32236f753665b48209bcd4" + integrity sha512-jpZBT5HK7SWx1LRQyv9d14i44vSsKXGZsSPA2ndth5HykHJsiAj9Fwl1AtzmtGYuBmI+iXQyOd4MAMHd4ZZ1tg== dependencies: - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/utils" "2.0.0-beta.21" + "@docusaurus/core" "2.0.1" + "@docusaurus/types" "2.0.1" + "@docusaurus/utils" "2.0.1" fs-extra "^10.1.0" react-json-view "^1.21.3" tslib "^2.4.0" -"@docusaurus/plugin-google-analytics@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/plugin-google-analytics/-/plugin-google-analytics-2.0.0-beta.21.tgz#5475c58fb23603badf41d84298569f6c46b4e6b2" - integrity sha512-+5MS0PeGaJRgPuNZlbd/WMdQSpOACaxEz7A81HAxm6kE+tIASTW3l8jgj1eWFy/PGPzaLnQrEjxI1McAfnYmQw== +"@docusaurus/plugin-google-analytics@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/plugin-google-analytics/-/plugin-google-analytics-2.0.1.tgz#e3b84237aad2e94dcd1cf1810c1c9bc3d94f186d" + integrity sha512-d5qb+ZeQcg1Czoxc+RacETjLdp2sN/TAd7PGN/GrvtijCdgNmvVAtZ9QgajBTG0YbJFVPTeZ39ad2bpoOexX0w== dependencies: - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/utils-validation" "2.0.0-beta.21" + "@docusaurus/core" "2.0.1" + "@docusaurus/types" "2.0.1" + "@docusaurus/utils-validation" "2.0.1" tslib "^2.4.0" -"@docusaurus/plugin-google-gtag@2.0.0-beta.21", "@docusaurus/plugin-google-gtag@^2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/plugin-google-gtag/-/plugin-google-gtag-2.0.0-beta.21.tgz#a4a101089994a7103c1cc7cddb15170427b185d6" - integrity sha512-4zxKZOnf0rfh6myXLG7a6YZfQcxYDMBsWqANEjCX77H5gPdK+GHZuDrxK6sjFvRBv4liYCrNjo7HJ4DpPoT0zA== +"@docusaurus/plugin-google-gtag@2.0.1", "@docusaurus/plugin-google-gtag@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/plugin-google-gtag/-/plugin-google-gtag-2.0.1.tgz#4cbcf9d520f7ec8124679fbe00867f2299a2f6bb" + integrity sha512-qiRufJe2FvIyzICbkjm4VbVCI1hyEju/CebfDKkKh2ZtV4q6DM1WZG7D6VoQSXL8MrMFB895gipOM4BwdM8VsQ== dependencies: - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/utils-validation" "2.0.0-beta.21" + "@docusaurus/core" "2.0.1" + "@docusaurus/types" "2.0.1" + "@docusaurus/utils-validation" "2.0.1" tslib "^2.4.0" -"@docusaurus/plugin-sitemap@2.0.0-beta.21", "@docusaurus/plugin-sitemap@^2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/plugin-sitemap/-/plugin-sitemap-2.0.0-beta.21.tgz#8bfa695eada2ec95c9376a884641237ffca5dd3d" - integrity sha512-/ynWbcXZXcYZ6sT2X6vAJbnfqcPxwdGEybd0rcRZi4gBHq6adMofYI25AqELmnbBDxt0If+vlAeUHFRG5ueP7Q== - dependencies: - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/logger" "2.0.0-beta.21" - "@docusaurus/utils" "2.0.0-beta.21" - "@docusaurus/utils-common" "2.0.0-beta.21" - "@docusaurus/utils-validation" "2.0.0-beta.21" +"@docusaurus/plugin-sitemap@2.0.1", "@docusaurus/plugin-sitemap@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/plugin-sitemap/-/plugin-sitemap-2.0.1.tgz#6f8edb82b745b040d6b1495e2798396f63e50289" + integrity sha512-KcYuIUIp2JPzUf+Xa7W2BSsjLgN1/0h+VAz7D/C3RYjAgC5ApPX8wO+TECmGfunl/m7WKGUmLabfOon/as64kQ== + dependencies: + "@docusaurus/core" "2.0.1" + "@docusaurus/logger" "2.0.1" + "@docusaurus/types" "2.0.1" + "@docusaurus/utils" "2.0.1" + "@docusaurus/utils-common" "2.0.1" + "@docusaurus/utils-validation" "2.0.1" fs-extra "^10.1.0" sitemap "^7.1.1" tslib "^2.4.0" -"@docusaurus/preset-classic@^2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/preset-classic/-/preset-classic-2.0.0-beta.21.tgz#1362d8650ebed22633db411caaba80075f7c86ce" - integrity sha512-KvBnIUu7y69pNTJ9UhX6SdNlK6prR//J3L4rhN897tb8xx04xHHILlPXko2Il+C3Xzgh3OCgyvkoz9K6YlFTDw== - dependencies: - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/plugin-content-blog" "2.0.0-beta.21" - "@docusaurus/plugin-content-docs" "2.0.0-beta.21" - "@docusaurus/plugin-content-pages" "2.0.0-beta.21" - "@docusaurus/plugin-debug" "2.0.0-beta.21" - "@docusaurus/plugin-google-analytics" "2.0.0-beta.21" - "@docusaurus/plugin-google-gtag" "2.0.0-beta.21" - "@docusaurus/plugin-sitemap" "2.0.0-beta.21" - "@docusaurus/theme-classic" "2.0.0-beta.21" - "@docusaurus/theme-common" "2.0.0-beta.21" - "@docusaurus/theme-search-algolia" "2.0.0-beta.21" +"@docusaurus/preset-classic@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/preset-classic/-/preset-classic-2.0.1.tgz#21a806e16b61026d2a0efa6ca97e17397065d894" + integrity sha512-nOoniTg46My1qdDlLWeFs55uEmxOJ+9WMF8KKG8KMCu5LAvpemMi7rQd4x8Tw+xiPHZ/sQzH9JmPTMPRE4QGPw== + dependencies: + "@docusaurus/core" "2.0.1" + "@docusaurus/plugin-content-blog" "2.0.1" + "@docusaurus/plugin-content-docs" "2.0.1" + "@docusaurus/plugin-content-pages" "2.0.1" + "@docusaurus/plugin-debug" "2.0.1" + "@docusaurus/plugin-google-analytics" "2.0.1" + "@docusaurus/plugin-google-gtag" "2.0.1" + "@docusaurus/plugin-sitemap" "2.0.1" + "@docusaurus/theme-classic" "2.0.1" + "@docusaurus/theme-common" "2.0.1" + "@docusaurus/theme-search-algolia" "2.0.1" + "@docusaurus/types" "2.0.1" "@docusaurus/react-loadable@5.5.2", "react-loadable@npm:@docusaurus/react-loadable@5.5.2": version "5.5.2" @@ -1446,115 +1898,125 @@ "@types/react" "*" prop-types "^15.6.2" -"@docusaurus/theme-classic@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/theme-classic/-/theme-classic-2.0.0-beta.21.tgz#6df5b9ea2d389dafb6f59badeabb3eda060b5017" - integrity sha512-Ge0WNdTefD0VDQfaIMRRWa8tWMG9+8/OlBRd5MK88/TZfqdBq7b/gnCSaalQlvZwwkj6notkKhHx72+MKwWUJA== - dependencies: - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/plugin-content-blog" "2.0.0-beta.21" - "@docusaurus/plugin-content-docs" "2.0.0-beta.21" - "@docusaurus/plugin-content-pages" "2.0.0-beta.21" - "@docusaurus/theme-common" "2.0.0-beta.21" - "@docusaurus/theme-translations" "2.0.0-beta.21" - "@docusaurus/utils" "2.0.0-beta.21" - "@docusaurus/utils-common" "2.0.0-beta.21" - "@docusaurus/utils-validation" "2.0.0-beta.21" +"@docusaurus/theme-classic@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/theme-classic/-/theme-classic-2.0.1.tgz#043b6fcd2ecb2aecd134419b198c9f519029d5e7" + integrity sha512-0jfigiqkUwIuKOw7Me5tqUM9BBvoQX7qqeevx7v4tkYQexPhk3VYSZo7aRuoJ9oyW5makCTPX551PMJzmq7+sw== + dependencies: + "@docusaurus/core" "2.0.1" + "@docusaurus/mdx-loader" "2.0.1" + "@docusaurus/module-type-aliases" "2.0.1" + "@docusaurus/plugin-content-blog" "2.0.1" + "@docusaurus/plugin-content-docs" "2.0.1" + "@docusaurus/plugin-content-pages" "2.0.1" + "@docusaurus/theme-common" "2.0.1" + "@docusaurus/theme-translations" "2.0.1" + "@docusaurus/types" "2.0.1" + "@docusaurus/utils" "2.0.1" + "@docusaurus/utils-common" "2.0.1" + "@docusaurus/utils-validation" "2.0.1" "@mdx-js/react" "^1.6.22" - clsx "^1.1.1" + clsx "^1.2.1" copy-text-to-clipboard "^3.0.1" - infima "0.2.0-alpha.39" + infima "0.2.0-alpha.42" lodash "^4.17.21" nprogress "^0.2.0" postcss "^8.4.14" - prism-react-renderer "^1.3.3" + prism-react-renderer "^1.3.5" prismjs "^1.28.0" react-router-dom "^5.3.3" rtlcss "^3.5.0" tslib "^2.4.0" + utility-types "^3.10.0" -"@docusaurus/theme-common@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/theme-common/-/theme-common-2.0.0-beta.21.tgz#508478251982d01655ef505ccb2420db38623db8" - integrity sha512-fTKoTLRfjuFG6c3iwnVjIIOensxWMgdBKLfyE5iih3Lq7tQgkE7NyTGG9BKLrnTJ7cAD2UXdXM9xbB7tBf1qzg== - dependencies: - "@docusaurus/module-type-aliases" "2.0.0-beta.21" - "@docusaurus/plugin-content-blog" "2.0.0-beta.21" - "@docusaurus/plugin-content-docs" "2.0.0-beta.21" - "@docusaurus/plugin-content-pages" "2.0.0-beta.21" - clsx "^1.1.1" +"@docusaurus/theme-common@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/theme-common/-/theme-common-2.0.1.tgz#9594d58fbef11fe480967b5ce4cdbb3cd78d9ca3" + integrity sha512-I3b6e/ryiTQMsbES40cP0DRGnfr0E2qghVq+XecyMKjBPejISoSFEDn0MsnbW8Q26k1Dh/0qDH8QKDqaZZgLhA== + dependencies: + "@docusaurus/mdx-loader" "2.0.1" + "@docusaurus/module-type-aliases" "2.0.1" + "@docusaurus/plugin-content-blog" "2.0.1" + "@docusaurus/plugin-content-docs" "2.0.1" + "@docusaurus/plugin-content-pages" "2.0.1" + "@docusaurus/utils" "2.0.1" + "@types/history" "^4.7.11" + "@types/react" "*" + "@types/react-router-config" "*" + clsx "^1.2.1" parse-numeric-range "^1.3.0" - prism-react-renderer "^1.3.3" + prism-react-renderer "^1.3.5" tslib "^2.4.0" utility-types "^3.10.0" -"@docusaurus/theme-search-algolia@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/theme-search-algolia/-/theme-search-algolia-2.0.0-beta.21.tgz#2891f11372e2542e4e1426c3100b72c2d30d4d68" - integrity sha512-T1jKT8MVSSfnztSqeebUOpWHPoHKtwDXtKYE0xC99JWoZ+mMfv8AFhVSoSddn54jLJjV36mxg841eHQIySMCpQ== - dependencies: - "@docsearch/react" "^3.1.0" - "@docusaurus/core" "2.0.0-beta.21" - "@docusaurus/logger" "2.0.0-beta.21" - "@docusaurus/plugin-content-docs" "2.0.0-beta.21" - "@docusaurus/theme-common" "2.0.0-beta.21" - "@docusaurus/theme-translations" "2.0.0-beta.21" - "@docusaurus/utils" "2.0.0-beta.21" - "@docusaurus/utils-validation" "2.0.0-beta.21" +"@docusaurus/theme-search-algolia@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/theme-search-algolia/-/theme-search-algolia-2.0.1.tgz#0aab8407b2163f67eb4c48f1de33944e1695fa74" + integrity sha512-cw3NaOSKbYlsY6uNj4PgO+5mwyQ3aEWre5RlmvjStaz2cbD15Nr69VG8Rd/F6Q5VsCT8BvSdkPDdDG5d/ACexg== + dependencies: + "@docsearch/react" "^3.1.1" + "@docusaurus/core" "2.0.1" + "@docusaurus/logger" "2.0.1" + "@docusaurus/plugin-content-docs" "2.0.1" + "@docusaurus/theme-common" "2.0.1" + "@docusaurus/theme-translations" "2.0.1" + "@docusaurus/utils" "2.0.1" + "@docusaurus/utils-validation" "2.0.1" algoliasearch "^4.13.1" - algoliasearch-helper "^3.8.2" - clsx "^1.1.1" + algoliasearch-helper "^3.10.0" + clsx "^1.2.1" eta "^1.12.3" fs-extra "^10.1.0" lodash "^4.17.21" tslib "^2.4.0" utility-types "^3.10.0" -"@docusaurus/theme-translations@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/theme-translations/-/theme-translations-2.0.0-beta.21.tgz#5da60ffc58de256b96316c5e0fe2733c1e83f22c" - integrity sha512-dLVT9OIIBs6MpzMb1bAy+C0DPJK3e3DNctG+ES0EP45gzEqQxzs4IsghpT+QDaOsuhNnAlosgJpFWX3rqxF9xA== +"@docusaurus/theme-translations@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/theme-translations/-/theme-translations-2.0.1.tgz#955a687c974265a811bfc743d98ef3eab0379100" + integrity sha512-v1MYYlbsdX+rtKnXFcIAn9ar0Z6K0yjqnCYS0p/KLCLrfJwfJ8A3oRJw2HiaIb8jQfk1WMY2h5Qi1p4vHOekQw== dependencies: fs-extra "^10.1.0" tslib "^2.4.0" -"@docusaurus/types@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/types/-/types-2.0.0-beta.21.tgz#36659c6c012663040dcd4cbc97b5d7a555dae229" - integrity sha512-/GH6Npmq81eQfMC/ikS00QSv9jNyO1RXEpNSx5GLA3sFX8Iib26g2YI2zqNplM8nyxzZ2jVBuvUoeODTIbTchQ== +"@docusaurus/types@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/types/-/types-2.0.1.tgz#8696a70e85c4b9be80b38ac592d520f6fe72618b" + integrity sha512-o+4hAFWkj3sBszVnRTAnNqtAIuIW0bNaYyDwQhQ6bdz3RAPEq9cDKZxMpajsj4z2nRty8XjzhyufAAjxFTyrfg== dependencies: + "@types/history" "^4.7.11" + "@types/react" "*" commander "^5.1.0" - history "^4.9.0" joi "^17.6.0" react-helmet-async "^1.3.0" utility-types "^3.10.0" - webpack "^5.72.1" + webpack "^5.73.0" webpack-merge "^5.8.0" -"@docusaurus/utils-common@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/utils-common/-/utils-common-2.0.0-beta.21.tgz#81e86ed04ad62b75e9ba6a5e7689dc23d5f36a0a" - integrity sha512-5w+6KQuJb6pUR2M8xyVuTMvO5NFQm/p8TOTDFTx60wt3p0P1rRX00v6FYsD4PK6pgmuoKjt2+Ls8dtSXc4qFpQ== +"@docusaurus/utils-common@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/utils-common/-/utils-common-2.0.1.tgz#b6f2b029547f739e1431ec84abd16974edf495e0" + integrity sha512-kajCCDCXRd1HFH5EUW31MPaQcsyNlGakpkDoTBtBvpa4EIPvWaSKy7TIqYKHrZjX4tnJ0YbEJvaXfjjgdq5xSg== dependencies: tslib "^2.4.0" -"@docusaurus/utils-validation@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/utils-validation/-/utils-validation-2.0.0-beta.21.tgz#10169661be5f8a233f4c12202ee5802ccb77400f" - integrity sha512-6NG1FHTRjv1MFzqW//292z7uCs77vntpWEbZBHk3n67aB1HoMn5SOwjLPtRDjbCgn6HCHFmdiJr6euCbjhYolg== +"@docusaurus/utils-validation@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/utils-validation/-/utils-validation-2.0.1.tgz#69f7d4944288d71f00fdba6dde10f05008f04308" + integrity sha512-f14AnwFBy4/1A19zWthK+Ii80YDz+4qt8oPpK3julywXsheSxPBqgsND3LVBBvB2p3rJHvbo2m3HyB9Tco1JRw== dependencies: - "@docusaurus/logger" "2.0.0-beta.21" - "@docusaurus/utils" "2.0.0-beta.21" + "@docusaurus/logger" "2.0.1" + "@docusaurus/utils" "2.0.1" joi "^17.6.0" js-yaml "^4.1.0" tslib "^2.4.0" -"@docusaurus/utils@2.0.0-beta.21": - version "2.0.0-beta.21" - resolved "https://registry.yarnpkg.com/@docusaurus/utils/-/utils-2.0.0-beta.21.tgz#8fc4499c4cfedd29805025d930f8008cad255044" - integrity sha512-M/BrVCDmmUPZLxtiStBgzpQ4I5hqkggcpnQmEN+LbvbohjbtVnnnZQ0vptIziv1w8jry/woY+ePsyOO7O/yeLQ== +"@docusaurus/utils@2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@docusaurus/utils/-/utils-2.0.1.tgz#37b4b42e29175e5d2d811fcbf9f93bffeca7c353" + integrity sha512-u2Vdl/eoVwMfUjDCkg7FjxoiwFs/XhVVtNxQEw8cvB+qaw6QWyT73m96VZzWtUb1fDOefHoZ+bZ0ObFeKk9lMQ== dependencies: - "@docusaurus/logger" "2.0.0-beta.21" + "@docusaurus/logger" "2.0.1" "@svgr/webpack" "^6.2.1" file-loader "^6.2.0" fs-extra "^10.1.0" @@ -1568,7 +2030,7 @@ shelljs "^0.8.5" tslib "^2.4.0" url-loader "^4.1.1" - webpack "^5.72.1" + webpack "^5.73.0" "@hapi/hoek@^9.0.0": version "9.3.0" @@ -1622,6 +2084,14 @@ resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz#add4c98d341472a289190b424efbdb096991bb24" integrity sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw== +"@jridgewell/trace-mapping@^0.3.14": + version "0.3.15" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.15.tgz#aba35c48a38d3fd84b37e66c9c0423f9744f9774" + integrity sha512-oWZNOULl+UbhsgB51uuZzglikfIKSUBO/M9W2OfEjn7cmqoAiCgmv9lyACTUacZwBz0ITnJ2NqjU8Tx0DHL88g== + dependencies: + "@jridgewell/resolve-uri" "^3.0.3" + "@jridgewell/sourcemap-codec" "^1.4.10" + "@jridgewell/trace-mapping@^0.3.7", "@jridgewell/trace-mapping@^0.3.9": version "0.3.14" resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.14.tgz#b231a081d8f66796e475ad588a1ef473112701ed" @@ -1718,7 +2188,7 @@ resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.14.0.tgz#9fb3a3cf3132328151f353de4632e01e52102bea" integrity sha512-9NET910DNaIPngYnLLPeg+Ogzqsi9uM4mSboU5y6p8S5DzMTVEsJZrawi+BoDNUVBa2DhJqQYUFvMDfgU062LQ== -"@slorber/static-site-generator-webpack-plugin@^4.0.4": +"@slorber/static-site-generator-webpack-plugin@^4.0.7": version "4.0.7" resolved "https://registry.yarnpkg.com/@slorber/static-site-generator-webpack-plugin/-/static-site-generator-webpack-plugin-4.0.7.tgz#fc1678bddefab014e2145cbe25b3ce4e1cfc36f3" integrity sha512-Ug7x6z5lwrz0WqdnNFOMYrDQNTPAprvHLSh6+/fmml3qUiz6l5eq+2MzLKWtn/q5K5NpSiFsZTP/fck/3vjSxA== @@ -1994,7 +2464,7 @@ resolved "https://registry.yarnpkg.com/@types/range-parser/-/range-parser-1.2.4.tgz#cd667bcfdd025213aafb7ca5915a932590acdcdc" integrity sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw== -"@types/react-router-config@*": +"@types/react-router-config@*", "@types/react-router-config@^5.0.6": version "5.0.6" resolved "https://registry.yarnpkg.com/@types/react-router-config/-/react-router-config-5.0.6.tgz#87c5c57e72d241db900d9734512c50ccec062451" integrity sha512-db1mx37a1EJDf1XeX8jJN7R3PZABmJQXR8r28yUjVMFSjkmnQo6X6pOEEmNl+Tp2gYQOGPdYbFIipBtdElZ3Yg== @@ -2229,11 +2699,16 @@ acorn-walk@^8.0.0: resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-8.2.0.tgz#741210f2e2426454508853a2f44d0ab83b7f69c1" integrity sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA== -acorn@^8.0.4, acorn@^8.4.1, acorn@^8.5.0: +acorn@^8.0.4, acorn@^8.5.0: version "8.7.1" resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.7.1.tgz#0197122c843d1bf6d0a5e83220a788f278f63c30" integrity sha512-Xx54uLJQZ19lKygFXOWsscKUbsBZW0CPykPhVQdhIeIwrbPmJzqeASDInc8nKBnp/JT6igTs82qPXz069H8I/A== +acorn@^8.7.1: + version "8.8.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.8.0.tgz#88c0187620435c7f6015803f5539dae05a9dbea8" + integrity sha512-QOxyigPVrpZ2GXT+PFyZTl6TtOFc5egxHIP9IlQ+RbupQuX4RkT/Bee4/kQuC02Xkzg84JcT7oLYtDIQxp+v7w== + address@^1.0.1, address@^1.1.2: version "1.2.0" resolved "https://registry.yarnpkg.com/address/-/address-1.2.0.tgz#d352a62c92fee90f89a693eccd2a8b2139ab02d9" @@ -2286,10 +2761,10 @@ ajv@^8.0.0, ajv@^8.8.0: require-from-string "^2.0.2" uri-js "^4.2.2" -algoliasearch-helper@^3.8.2: - version "3.10.0" - resolved "https://registry.yarnpkg.com/algoliasearch-helper/-/algoliasearch-helper-3.10.0.tgz#59a0f645dd3c7e55cf01faa568d1af50c49d36f6" - integrity sha512-4E4od8qWWDMVvQ3jaRX6Oks/k35ywD011wAA4LbYMMjOtaZV6VWaTjRr4iN2bdaXP2o1BP7SLFMBf3wvnHmd8Q== +algoliasearch-helper@^3.10.0: + version "3.11.0" + resolved "https://registry.yarnpkg.com/algoliasearch-helper/-/algoliasearch-helper-3.11.0.tgz#c4355056d97748a92f6ff0d4fce153b96b561ddb" + integrity sha512-TLl/MSjtQ98mgkd8hngWkzSjE+dAWldZ1NpJtv2mT+ZoFJ2P2zDE85oF9WafJOXWN9FbVRmyxpO5H+qXcNaFng== dependencies: "@algolia/events" "^4.0.1" @@ -2464,6 +2939,15 @@ babel-plugin-polyfill-corejs2@^0.3.1: "@babel/helper-define-polyfill-provider" "^0.3.1" semver "^6.1.1" +babel-plugin-polyfill-corejs2@^0.3.2: + version "0.3.2" + resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.3.2.tgz#e4c31d4c89b56f3cf85b92558954c66b54bd972d" + integrity sha512-LPnodUl3lS0/4wN3Rb+m+UK8s7lj2jcLRrjho4gLw+OJs+I4bvGXshINesY5xx/apM+biTnQ9reDI8yj+0M5+Q== + dependencies: + "@babel/compat-data" "^7.17.7" + "@babel/helper-define-polyfill-provider" "^0.3.2" + semver "^6.1.1" + babel-plugin-polyfill-corejs3@^0.5.2: version "0.5.2" resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.5.2.tgz#aabe4b2fa04a6e038b688c5e55d44e78cd3a5f72" @@ -2472,6 +2956,14 @@ babel-plugin-polyfill-corejs3@^0.5.2: "@babel/helper-define-polyfill-provider" "^0.3.1" core-js-compat "^3.21.0" +babel-plugin-polyfill-corejs3@^0.5.3: + version "0.5.3" + resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.5.3.tgz#d7e09c9a899079d71a8b670c6181af56ec19c5c7" + integrity sha512-zKsXDh0XjnrUEW0mxIHLfjBfnXSMr5Q/goMe/fxpQnLm07mcOZiIZHBNWCMx60HmdvjxfXcalac0tfFg0wqxyw== + dependencies: + "@babel/helper-define-polyfill-provider" "^0.3.2" + core-js-compat "^3.21.0" + babel-plugin-polyfill-regenerator@^0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.3.1.tgz#2c0678ea47c75c8cc2fbb1852278d8fb68233990" @@ -2479,6 +2971,13 @@ babel-plugin-polyfill-regenerator@^0.3.1: dependencies: "@babel/helper-define-polyfill-provider" "^0.3.1" +babel-plugin-polyfill-regenerator@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.4.0.tgz#8f51809b6d5883e07e71548d75966ff7635527fe" + integrity sha512-RW1cnryiADFeHmfLS+WW/G431p1PsW5qdRdz0SDRi7TKcUgc7Oh/uXkT7MZ/+tGsT1BkczEAmD5XjUyJ5SWDTw== + dependencies: + "@babel/helper-define-polyfill-provider" "^0.3.2" + bail@^1.0.0: version "1.0.5" resolved "https://registry.yarnpkg.com/bail/-/bail-1.0.5.tgz#b6fa133404a392cbc1f8c4bf63f5953351e7a776" @@ -2669,7 +3168,7 @@ caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001335, caniuse-lite@^1.0.30001359: resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001363.tgz#26bec2d606924ba318235944e1193304ea7c4f15" integrity sha512-HpQhpzTGGPVMnCjIomjt+jvyUu8vNFo3TaDiZ/RcoTrlOq/5+tC8zHdsbgFB6MxmaY+jCpsH09aD80Bb4Ow3Sg== -ccount@^1.0.0, ccount@^1.0.3: +ccount@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/ccount/-/ccount-1.1.0.tgz#246687debb6014735131be8abab2d93898f8d043" integrity sha512-vlNK021QdI7PNeiUh/lKkC/mNHHfV0m/Ad5JoI0TYtlBnJAslM/JIkm/tGC88bkLIwO6OQ5uV6ztS6kVAtCDlg== @@ -2718,7 +3217,7 @@ cheerio-select@^2.1.0: domhandler "^5.0.3" domutils "^3.0.1" -cheerio@^1.0.0-rc.11: +cheerio@^1.0.0-rc.12: version "1.0.0-rc.12" resolved "https://registry.yarnpkg.com/cheerio/-/cheerio-1.0.0-rc.12.tgz#788bf7466506b1c6bf5fae51d24a2c4d62e47683" integrity sha512-VqR8m68vM46BNnuZ5NtnGBKIE/DfN0cRIzg9n40EIq9NOv90ayxLBXA8fXC5gquFRGJSTRqBq25Jt2ECLR431Q== @@ -2803,7 +3302,7 @@ clone-response@^1.0.2: dependencies: mimic-response "^1.0.0" -clsx@^1.1.1: +clsx@^1.1.1, clsx@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/clsx/-/clsx-1.2.1.tgz#0ddc4a20a549b59c93a4116bb26f5294ca17dc12" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== @@ -2993,10 +3492,10 @@ core-js-pure@^3.20.2: resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.23.3.tgz#bcd02d3d8ec68ad871ef50d5ccbb248ddb54f401" integrity sha512-XpoouuqIj4P+GWtdyV8ZO3/u4KftkeDVMfvp+308eGMhCrA3lVDSmAxO0c6GGOcmgVlaKDrgWVMo49h2ab/TDA== -core-js@^3.22.7: - version "3.23.3" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.23.3.tgz#3b977612b15da6da0c9cc4aec487e8d24f371112" - integrity sha512-oAKwkj9xcWNBAvGbT//WiCdOMpb9XQG92/Fe3ABFM/R16BsHgePG00mFOgKf7IsCtfj8tA1kHtf/VwErhriz5Q== +core-js@^3.23.3: + version "3.24.1" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.24.1.tgz#cf7724d41724154010a6576b7b57d94c5d66e64f" + integrity sha512-0QTBSYSUZ6Gq21utGzkfITDylE8jWC9Ne1D2MrhvlsZBI1x39OdDIVbzSqtgMndIy6BlHxBXpMGqzZmnztg2rg== core-util-is@~1.0.0: version "1.0.3" @@ -3117,7 +3616,7 @@ cssesc@^3.0.0: resolved "https://registry.yarnpkg.com/cssesc/-/cssesc-3.0.0.tgz#37741919903b868565e1c09ea747445cd18983ee" integrity sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg== -cssnano-preset-advanced@^5.3.5: +cssnano-preset-advanced@^5.3.8: version "5.3.8" resolved "https://registry.yarnpkg.com/cssnano-preset-advanced/-/cssnano-preset-advanced-5.3.8.tgz#027b1d05ef896d908178c483f0ec4190cb50ef9a" integrity sha512-xUlLLnEB1LjpEik+zgRNlk8Y/koBPPtONZjp7JKbXigeAmCrFvq9H0pXW5jJV45bQWAlmJ0sKy+IMr0XxLYQZg== @@ -3169,7 +3668,16 @@ cssnano-utils@^3.1.0: resolved "https://registry.yarnpkg.com/cssnano-utils/-/cssnano-utils-3.1.0.tgz#95684d08c91511edfc70d2636338ca37ef3a6861" integrity sha512-JQNR19/YZhz4psLX/rQ9M83e3z2Wf/HdJbryzte4a3NSuafyp9w/I4U+hx5C2S9g41qlstH7DEWnZaaj83OuEA== -cssnano@^5.1.8, cssnano@^5.1.9: +cssnano@^5.1.12: + version "5.1.13" + resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-5.1.13.tgz#83d0926e72955332dc4802a7070296e6258efc0a" + integrity sha512-S2SL2ekdEz6w6a2epXn4CmMKU4K3KpcyXLKfAYc9UQQqJRkD/2eLUG0vJ3Db/9OvO5GuAdgXw3pFbR6abqghDQ== + dependencies: + cssnano-preset-default "^5.2.12" + lilconfig "^2.0.3" + yaml "^1.10.2" + +cssnano@^5.1.8: version "5.1.12" resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-5.1.12.tgz#bcd0b64d6be8692de79332c501daa7ece969816c" integrity sha512-TgvArbEZu0lk/dvg2ja+B7kYoD7BBCmn3+k58xD0qjrGHsFzXY/wKTo9M5egcUCabPol05e/PVoIu79s2JN4WQ== @@ -3456,7 +3964,7 @@ end-of-stream@^1.1.0: dependencies: once "^1.4.0" -enhanced-resolve@^5.9.3: +enhanced-resolve@^5.10.0: version "5.10.0" resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.10.0.tgz#0dc579c3bb2a1032e357ac45b8f3a6f3ad4fb1e6" integrity sha512-T0yTFjdpldGY8PmuXXR0PyQ1ufZpEGiHVrp7zHKB7jdR4qlmZHhONVM5AQOAWXuF/w3dnHbEQVrNptJgt7F+cQ== @@ -4084,17 +4592,6 @@ hast-to-hyperscript@^9.0.0: unist-util-is "^4.0.0" web-namespaces "^1.0.0" -hast-util-from-parse5@^5.0.0: - version "5.0.3" - resolved "https://registry.yarnpkg.com/hast-util-from-parse5/-/hast-util-from-parse5-5.0.3.tgz#3089dc0ee2ccf6ec8bc416919b51a54a589e097c" - integrity sha512-gOc8UB99F6eWVWFtM9jUikjN7QkWxB3nY0df5Z0Zq1/Nkwl5V4hAAsl0tmwlgWl/1shlTF8DnNYLO8X6wRV9pA== - dependencies: - ccount "^1.0.3" - hastscript "^5.0.0" - property-information "^5.0.0" - web-namespaces "^1.1.2" - xtend "^4.0.1" - hast-util-from-parse5@^6.0.0: version "6.0.1" resolved "https://registry.yarnpkg.com/hast-util-from-parse5/-/hast-util-from-parse5-6.0.1.tgz#554e34abdeea25ac76f5bd950a1f0180e0b3bc2a" @@ -4139,16 +4636,6 @@ hast-util-to-parse5@^6.0.0: xtend "^4.0.0" zwitch "^1.0.0" -hastscript@^5.0.0: - version "5.1.2" - resolved "https://registry.yarnpkg.com/hastscript/-/hastscript-5.1.2.tgz#bde2c2e56d04c62dd24e8c5df288d050a355fb8a" - integrity sha512-WlztFuK+Lrvi3EggsqOkQ52rKbxkXL3RwB6t5lwoa8QLMemoWfBuL43eDrwOamJyR7uKQKdmKYaBH1NZBiIRrQ== - dependencies: - comma-separated-tokens "^1.0.0" - hast-util-parse-selector "^2.0.0" - property-information "^5.0.0" - space-separated-tokens "^1.0.0" - hastscript@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/hastscript/-/hastscript-6.0.0.tgz#e8768d7eac56c3fdeac8a92830d58e811e5bf640" @@ -4366,10 +4853,10 @@ indent-string@^4.0.0: resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-4.0.0.tgz#624f8f4497d619b2d9768531d58f4122854d7251" integrity sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg== -infima@0.2.0-alpha.39: - version "0.2.0-alpha.39" - resolved "https://registry.yarnpkg.com/infima/-/infima-0.2.0-alpha.39.tgz#054b13ac44f3e9a42bc083988f1a1586add2f59c" - integrity sha512-UyYiwD3nwHakGhuOUfpe3baJ8gkiPpRVx4a4sE/Ag+932+Y6swtLsdPoRR8ezhwqGnduzxmFkjumV9roz6QoLw== +infima@0.2.0-alpha.42: + version "0.2.0-alpha.42" + resolved "https://registry.yarnpkg.com/infima/-/infima-0.2.0-alpha.42.tgz#f6e86a655ad40877c6b4d11b2ede681eb5470aa5" + integrity sha512-ift8OXNbQQwtbIt6z16KnSWP7uJ/SysSMFI4F87MNRTicypfl4Pv3E2OGVv6N3nSZFJvA8imYulCBS64iyHYww== inflight@^1.0.4: version "1.0.6" @@ -4996,7 +5483,7 @@ mini-create-react-context@^0.4.0: "@babel/runtime" "^7.12.1" tiny-warning "^1.0.3" -mini-css-extract-plugin@^2.6.0: +mini-css-extract-plugin@^2.6.1: version "2.6.1" resolved "https://registry.yarnpkg.com/mini-css-extract-plugin/-/mini-css-extract-plugin-2.6.1.tgz#9a1251d15f2035c342d99a468ab9da7a0451b71e" integrity sha512-wd+SD57/K6DiV7jIR34P+s3uckTRuQvx0tKPcvjFlrEylk6P4mQ2KSWk1hblj1Kxaqok7LogKOieygXqBczNlg== @@ -5331,11 +5818,6 @@ parse5-htmlparser2-tree-adapter@^7.0.0: domhandler "^5.0.2" parse5 "^7.0.0" -parse5@^5.0.0: - version "5.1.1" - resolved "https://registry.yarnpkg.com/parse5/-/parse5-5.1.1.tgz#f68e4e5ba1852ac2cadc00f4555fff6c2abb6178" - integrity sha512-ugq4DFI0Ptb+WWjAdOK16+u/nHfiIrcE+sh8kZMaM0WllQKLI9rOUq6c2b7cwPkXdzfQESqvoqK6ug7U/Yyzug== - parse5@^6.0.0: version "6.0.1" resolved "https://registry.yarnpkg.com/parse5/-/parse5-6.0.1.tgz#e1a1c085c569b3dc08321184f19a39cc27f7c30b" @@ -5745,7 +6227,7 @@ pretty-time@^1.1.0: resolved "https://registry.yarnpkg.com/pretty-time/-/pretty-time-1.1.0.tgz#ffb7429afabb8535c346a34e41873adf3d74dd0e" integrity sha512-28iF6xPQrP8Oa6uxE6a1biz+lWeTOAPKggvjB8HAs6nVMKZwf5bG++632Dx614hIWgUPkgivRfG+a8uAXGTIbA== -prism-react-renderer@^1.3.1, prism-react-renderer@^1.3.3: +prism-react-renderer@^1.3.1, prism-react-renderer@^1.3.5: version "1.3.5" resolved "https://registry.yarnpkg.com/prism-react-renderer/-/prism-react-renderer-1.3.5.tgz#786bb69aa6f73c32ba1ee813fbe17a0115435085" integrity sha512-IJ+MSwBWKG+SM3b2SUfdrhC+gu01QkV2KmRQgREThBfSQRoufqRfxfHUxpG1WcaFjP+kojcFyO9Qqtpgt3qLCg== @@ -6145,29 +6627,11 @@ regjsparser@^0.8.2: dependencies: jsesc "~0.5.0" -rehype-parse@^6.0.2: - version "6.0.2" - resolved "https://registry.yarnpkg.com/rehype-parse/-/rehype-parse-6.0.2.tgz#aeb3fdd68085f9f796f1d3137ae2b85a98406964" - integrity sha512-0S3CpvpTAgGmnz8kiCyFLGuW5yA4OQhyNTm/nwPopZ7+PI11WnGl1TTWTGv/2hPEe/g2jRLlhVVSsoDH8waRug== - dependencies: - hast-util-from-parse5 "^5.0.0" - parse5 "^5.0.0" - xtend "^4.0.0" - relateurl@^0.2.7: version "0.2.7" resolved "https://registry.yarnpkg.com/relateurl/-/relateurl-0.2.7.tgz#54dbf377e51440aca90a4cd274600d3ff2d888a9" integrity sha512-G08Dxvm4iDN3MLM0EsP62EDV9IuhXPR6blNz6Utcp7zyV3tr4HVNINt6MpaRWbxoOHT3Q7YN2P+jaHX8vUbgog== -remark-admonitions@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/remark-admonitions/-/remark-admonitions-1.2.1.tgz#87caa1a442aa7b4c0cafa04798ed58a342307870" - integrity sha512-Ji6p68VDvD+H1oS95Fdx9Ar5WA2wcDA4kwrrhVU7fGctC6+d3uiMICu7w7/2Xld+lnU7/gi+432+rRbup5S8ow== - dependencies: - rehype-parse "^6.0.2" - unified "^8.4.2" - unist-util-visit "^2.0.1" - remark-emoji@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/remark-emoji/-/remark-emoji-2.2.0.tgz#1c702090a1525da5b80e15a8f963ef2c8236cac7" @@ -6845,7 +7309,7 @@ tapable@^2.0.0, tapable@^2.1.1, tapable@^2.2.0: resolved "https://registry.yarnpkg.com/tapable/-/tapable-2.2.1.tgz#1967a73ef4060a82f12ab96af86d52fdb76eeca0" integrity sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ== -terser-webpack-plugin@^5.1.3, terser-webpack-plugin@^5.3.1: +terser-webpack-plugin@^5.1.3: version "5.3.3" resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.3.tgz#8033db876dd5875487213e87c627bca323e5ed90" integrity sha512-Fx60G5HNYknNTNQnzQ1VePRuu89ZVYWfjRAeT5rITuCY/1b08s49e5kSQwHDirKZWuoKOBRFS98EUUoZ9kLEwQ== @@ -6856,7 +7320,18 @@ terser-webpack-plugin@^5.1.3, terser-webpack-plugin@^5.3.1: serialize-javascript "^6.0.0" terser "^5.7.2" -terser@^5.10.0, terser@^5.7.2: +terser-webpack-plugin@^5.3.3: + version "5.3.5" + resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.5.tgz#f7d82286031f915a4f8fb81af4bd35d2e3c011bc" + integrity sha512-AOEDLDxD2zylUGf/wxHxklEkOe2/r+seuyOWujejFrIxHf11brA1/dWQNIgXa1c6/Wkxgu7zvv0JhOWfc2ELEA== + dependencies: + "@jridgewell/trace-mapping" "^0.3.14" + jest-worker "^27.4.5" + schema-utils "^3.1.1" + serialize-javascript "^6.0.0" + terser "^5.14.1" + +terser@^5.10.0, terser@^5.14.1, terser@^5.7.2: version "5.14.2" resolved "https://registry.yarnpkg.com/terser/-/terser-5.14.2.tgz#9ac9f22b06994d736174f4091aa368db896f1c10" integrity sha512-oL0rGeM/WFQCUd0y2QrWxYnq7tfSuKBiqTjRPWrRgB46WD/kiwHwF8T23z78H6Q6kGCuuHcPB+KULHRdxvVGQA== @@ -7011,13 +7486,14 @@ unified@9.2.0: trough "^1.0.0" vfile "^4.0.0" -unified@^8.4.2: - version "8.4.2" - resolved "https://registry.yarnpkg.com/unified/-/unified-8.4.2.tgz#13ad58b4a437faa2751a4a4c6a16f680c500fff1" - integrity sha512-JCrmN13jI4+h9UAyKEoGcDZV+i1E7BLFuG7OsaDvTXI5P0qhHX+vZO/kOhz9jn8HGENDKbwSeB0nVOg4gVStGA== +unified@^9.2.2: + version "9.2.2" + resolved "https://registry.yarnpkg.com/unified/-/unified-9.2.2.tgz#67649a1abfc3ab85d2969502902775eb03146975" + integrity sha512-Sg7j110mtefBD+qunSLO1lqOEKdrwBFBrR6Qd8f4uwkhWNlbkaqwHse6e7QvD3AP/MNoJdEDLaf8OxYyoWgorQ== dependencies: bail "^1.0.0" extend "^3.0.0" + is-buffer "^2.0.0" is-plain-obj "^2.0.0" trough "^1.0.0" vfile "^4.0.0" @@ -7078,7 +7554,7 @@ unist-util-visit-parents@^3.0.0: "@types/unist" "^2.0.0" unist-util-is "^4.0.0" -unist-util-visit@2.0.3, unist-util-visit@^2.0.0, unist-util-visit@^2.0.1, unist-util-visit@^2.0.3: +unist-util-visit@2.0.3, unist-util-visit@^2.0.0, unist-util-visit@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-2.0.3.tgz#c3703893146df47203bb8a9795af47d7b971208c" integrity sha512-iJ4/RczbJMkD0712mGktuGpm/U4By4FfDonL7N/9tATGIF4imikjOuagyMY53tnZq3NP6BcmlrHhEKAfGWjh7Q== @@ -7234,7 +7710,7 @@ wait-on@^6.0.1: minimist "^1.2.5" rxjs "^7.5.4" -watchpack@^2.3.1: +watchpack@^2.4.0: version "2.4.0" resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.0.tgz#fa33032374962c78113f93c7f2fb4c54c9862a5d" integrity sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg== @@ -7249,7 +7725,7 @@ wbuf@^1.1.0, wbuf@^1.7.3: dependencies: minimalistic-assert "^1.0.0" -web-namespaces@^1.0.0, web-namespaces@^1.1.2: +web-namespaces@^1.0.0: version "1.1.4" resolved "https://registry.yarnpkg.com/web-namespaces/-/web-namespaces-1.1.4.tgz#bc98a3de60dadd7faefc403d1076d529f5e030ec" integrity sha512-wYxSGajtmoP4WxfejAPIr4l0fVh+jeMXZb08wNc0tMg6xsfZXj3cECqIK0G7ZAqUq0PP8WlMDtaOGVBTAWztNw== @@ -7285,10 +7761,10 @@ webpack-dev-middleware@^5.3.1: range-parser "^1.2.1" schema-utils "^4.0.0" -webpack-dev-server@^4.9.0: - version "4.9.3" - resolved "https://registry.yarnpkg.com/webpack-dev-server/-/webpack-dev-server-4.9.3.tgz#2360a5d6d532acb5410a668417ad549ee3b8a3c9" - integrity sha512-3qp/eoboZG5/6QgiZ3llN8TUzkSpYg1Ko9khWX1h40MIEUNS2mDoIa8aXsPfskER+GbTvs/IJZ1QTBBhhuetSw== +webpack-dev-server@^4.9.3: + version "4.10.0" + resolved "https://registry.yarnpkg.com/webpack-dev-server/-/webpack-dev-server-4.10.0.tgz#de270d0009eba050546912be90116e7fd740a9ca" + integrity sha512-7dezwAs+k6yXVFZ+MaL8VnE+APobiO3zvpp3rBHe/HmWQ+avwh0Q3d0xxacOiBybZZ3syTZw9HXzpa3YNbAZDQ== dependencies: "@types/bonjour" "^3.5.9" "@types/connect-history-api-fallback" "^1.3.5" @@ -7333,21 +7809,21 @@ webpack-sources@^3.2.2, webpack-sources@^3.2.3: resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.2.3.tgz#2d4daab8451fd4b240cc27055ff6a0c2ccea0cde" integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== -webpack@^5.72.1: - version "5.73.0" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.73.0.tgz#bbd17738f8a53ee5760ea2f59dce7f3431d35d38" - integrity sha512-svjudQRPPa0YiOYa2lM/Gacw0r6PvxptHj4FuEKQ2kX05ZLkjbVc5MnPs6its5j7IZljnIqSVo/OsY2X0IpHGA== +webpack@^5.73.0: + version "5.74.0" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.74.0.tgz#02a5dac19a17e0bb47093f2be67c695102a55980" + integrity sha512-A2InDwnhhGN4LYctJj6M1JEaGL7Luj6LOmyBHjcI8529cm5p6VXiTIW2sn6ffvEAKmveLzvu4jrihwXtPojlAA== dependencies: "@types/eslint-scope" "^3.7.3" "@types/estree" "^0.0.51" "@webassemblyjs/ast" "1.11.1" "@webassemblyjs/wasm-edit" "1.11.1" "@webassemblyjs/wasm-parser" "1.11.1" - acorn "^8.4.1" + acorn "^8.7.1" acorn-import-assertions "^1.7.6" browserslist "^4.14.5" chrome-trace-event "^1.0.2" - enhanced-resolve "^5.9.3" + enhanced-resolve "^5.10.0" es-module-lexer "^0.9.0" eslint-scope "5.1.1" events "^3.2.0" @@ -7360,7 +7836,7 @@ webpack@^5.72.1: schema-utils "^3.1.0" tapable "^2.1.1" terser-webpack-plugin "^5.1.3" - watchpack "^2.3.1" + watchpack "^2.4.0" webpack-sources "^3.2.3" webpackbar@^5.0.2: From 957490e40e412c39f03b7bc1b120af60615dc17a Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 03:03:29 -0300 Subject: [PATCH 03/28] chore: Disabled git AutoCrLf conversions --- .gitattributes | 2 +- src/.gitattributes | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) delete mode 100644 src/.gitattributes diff --git a/.gitattributes b/.gitattributes index 0ae1939d..5378fe08 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1 +1 @@ -*.md eol=lf \ No newline at end of file +* -text \ No newline at end of file diff --git a/src/.gitattributes b/src/.gitattributes deleted file mode 100644 index c08f7879..00000000 --- a/src/.gitattributes +++ /dev/null @@ -1,2 +0,0 @@ -gsudo.extras\*.ps1 text eol=crlf -gsudo.extras\* text eol=lf \ No newline at end of file From e21594039f96661cc9deb0f61bca4e6e0d0eba5d Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 03:41:21 -0300 Subject: [PATCH 04/28] chore(build): Remove .pdb files from final artifacts --- build/04-release-GitHub.ps1 | 67 ++++++++--------- build/Build.bat | 138 ------------------------------------ build/BuildInstaller.cmd | 20 ------ build/InstallTools.cmd | 5 -- build/UploadToChoco.bat | 17 ----- build/UploadToGitHub.bat | 30 -------- 6 files changed, 35 insertions(+), 242 deletions(-) delete mode 100644 build/Build.bat delete mode 100644 build/BuildInstaller.cmd delete mode 100644 build/InstallTools.cmd delete mode 100644 build/UploadToChoco.bat delete mode 100644 build/UploadToGitHub.bat diff --git a/build/04-release-GitHub.ps1 b/build/04-release-GitHub.ps1 index 2d881f9f..f1e86acb 100644 --- a/build/04-release-GitHub.ps1 +++ b/build/04-release-GitHub.ps1 @@ -1,33 +1,36 @@ -pushd $PSScriptRoot\.. - -if ($env:version) { - "- Getting version from env:version" - $version = $env:version - $version_MajorMinorPatch=$env:version_MajorMinorPatch -} else { - "- Getting version using GitVersion" - $version = $(gitversion /showvariable LegacySemVer) - $version_MajorMinorPatch=$(gitversion /showvariable MajorMinorPatch) -} -"- Using version number v$version / v$version_MajorMinorPatch" - -Get-ChildItem .\artifacts\ -File | Remove-Item - -"- Packaging v$version" -Compress-Archive -Path ./artifacts/x86,./artifacts/x64,./artifacts/net46-AnyCpu -DestinationPath "artifacts/gsudo.v$($version).zip" -force -CompressionLevel Optimal -(Get-FileHash artifacts\gsudo.v$($version).zip).hash > artifacts\gsudo.v$($version).zip.sha256 - -$msbuild = &"${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -latest -prerelease -products * -requires Microsoft.Component.MSBuild -find MSBuild\**\Bin\MSBuild.exe - -$outdir = "$PSScriptRoot\..\artifacts" - -"- Building Installer" -(gc src\gsudo.Installer\Constants.Template.wxi) -replace '#VERSION#', "$version" | Out-File -encoding UTF8 src\gsudo.Installer\Constants.wxi -& $msbuild /t:Rebuild /p:Configuration=Release src\gsudo.Installer.sln /v:Minimal /p:OutputPath=$outdir || (popd && exit 1) -rm .\artifacts\gsudoSetup.wixpdb - -"- Code Signing Installer" -& $PSScriptRoot\03-sign.ps1 artifacts\gsudoSetup.msi || (popd && exit 1) -(Get-FileHash artifacts\gsudoSetup.msi).hash > artifacts\gsudoSetup.msi.sha256 - +pushd $PSScriptRoot\.. + +if ($env:version) { + "- Getting version from env:version" + $version = $env:version + $version_MajorMinorPatch=$env:version_MajorMinorPatch +} else { + "- Getting version using GitVersion" + $version = $(gitversion /showvariable LegacySemVer) + $version_MajorMinorPatch=$(gitversion /showvariable MajorMinorPatch) +} +"- Using version number v$version / v$version_MajorMinorPatch" + +Get-ChildItem .\artifacts\ -File | Remove-Item + +"- Packaging v$version" + +$files = Get-ChildItem -Path ./artifacts/x86,./artifacts/x64,./artifacts/net46-AnyCpu -Exclude *.pdb +Compress-Archive -Path $files -DestinationPath "artifacts/gsudo.v$($version).zip" -force -CompressionLevel Optimal + +(Get-FileHash artifacts\gsudo.v$($version).zip).hash > artifacts\gsudo.v$($version).zip.sha256 + +$msbuild = &"${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -latest -prerelease -products * -requires Microsoft.Component.MSBuild -find MSBuild\**\Bin\MSBuild.exe + +$outdir = "$PSScriptRoot\..\artifacts" + +"- Building Installer" +(gc src\gsudo.Installer\Constants.Template.wxi) -replace '#VERSION#', "$version" | Out-File -encoding UTF8 src\gsudo.Installer\Constants.wxi +& $msbuild /t:Rebuild /p:Configuration=Release src\gsudo.Installer.sln /v:Minimal /p:OutputPath=$outdir || (popd && exit 1) +rm .\artifacts\gsudoSetup.wixpdb + +"- Code Signing Installer" +& $PSScriptRoot\03-sign.ps1 artifacts\gsudoSetup.msi || (popd && exit 1) +(Get-FileHash artifacts\gsudoSetup.msi).hash > artifacts\gsudoSetup.msi.sha256 + popd \ No newline at end of file diff --git a/build/Build.bat b/build/Build.bat deleted file mode 100644 index 24b3aa17..00000000 --- a/build/Build.bat +++ /dev/null @@ -1,138 +0,0 @@ -@Echo off -:: Did you run InstallTools.cmd? - -pushd %~dp0\.. - -:: Determine Version -gitversion /showvariable LegacySemVer > "%temp%\version.tmp" -SET /P version= < "%temp%\version.tmp" - -gitversion /showvariable MajorMinorPatch > "%temp%\version.tmp" -SET /P MajorMinorPatch= < "%temp%\version.tmp" - -set REPO_ROOT_FOLDER=%cd% -set BIN_FOLDER=%cd%\src\gsudo\bin\ -set OUTPUT_FOLDER=%REPO_ROOT_FOLDER%\Build\Releases\%version% - -popd - -if NOT DEFINED msbuild set msbuild="C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\MSBuild.exe" -if NOT DEFINED SignToolPath set SignToolPath="C:\Program Files (x86)\Microsoft SDKs\ClickOnce\SignTool\" - -if ''=='%version%' echo Missing version number & goto badend -if 'skipbuild'=='%1' goto skipbuild - -echo Building with version number v%version% - -:: Cleanup -del %BIN_FOLDER%\*.* /q -rd %BIN_FOLDER%\package /q /s 2>nul - -mkdir %BIN_FOLDER%\package 2> nul -mkdir %BIN_FOLDER%\package\x64 2> nul -mkdir %BIN_FOLDER%\package\x86 2> nul -mkdir %BIN_FOLDER%\package\net46-AnyCpu 2> nul - -IF EXIST %OUTPUT_FOLDER% RD %OUTPUT_FOLDER% /q /s -mkdir %OUTPUT_FOLDER% 2> nul - -:: Build -echo Build net7.0 win-x64 -cmd /c rd .\src\gsudo\obj /s /q -dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x64 --sc -p:PublishAot=true -p:IlcOptimizationPreference=Size -v minimal -p:WarningLevel=0 - -echo Build net7.0 win-x86 -cmd /c rd .\src\gsudo\obj /s /q -dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x86 --sc -p:PublishReadyToRun=true -p:PublishSingleFile=true - -echo Build net46 AnyCpu -cmd /c rd .\src\gsudo\obj /s /q -dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net46 -p:Platform=AnyCpu - -if errorlevel 1 goto badend -echo Build Succeded. - -echo Running ILMerge for net46 -pushd %BIN_FOLDER%\net46\publish - -ilmerge gsudo.exe System.Security.Claims.dll System.Security.Principal.Windows.dll /out:%BIN_FOLDER%\package\net46-AnyCpu\gsudo.exe /target:exe /targetplatform:v4,"C:\Windows\Microsoft.NET\Framework\v4.0.30319" /ndebug -if errorlevel 1 echo ILMerge Failed - Try: choco install ilmerge & pause & popd & goto badend - -popd - -copy %REPO_ROOT_FOLDER%\src\gsudo.Wrappers\*.* %BIN_FOLDER%\package\x64 -copy %REPO_ROOT_FOLDER%\src\gsudo.Wrappers\*.* %BIN_FOLDER%\package\x86 -copy %REPO_ROOT_FOLDER%\src\gsudo.Wrappers\*.* %BIN_FOLDER%\package\net46-AnyCpu - -copy %BIN_FOLDER%\net7.0\win-x64\publish\gsudo.exe %BIN_FOLDER%\package\x64 -copy %BIN_FOLDER%\net7.0\win-x86\publish\gsudo.exe %BIN_FOLDER%\package\x86 - -:: Code Sign -if 'skipsign'=='%1' goto skipsign - -echo Signing exe. -pushd %BIN_FOLDER% - -::%SignToolPath%signtool.exe sign /n "Open Source Developer, Gerardo Grignoli" /fd SHA256 /tr "http://time.certum.pl" package\x64\*.* package\x86\*.* package\net46-AnyCpu\*.* -%SignToolPath%signtool.exe sign /f C:\git\code_signing.pfx /p 1234 /fd SHA256 /t http://timestamp.digicert.com package\x64\*.exe package\x64\*.p* package\x86\*.exe package\x86\*.p* package\net46-AnyCpu\*.exe package\net46-AnyCpu\*.p* - -if errorlevel 1 echo Sign Failed & pause & popd & goto badend -echo Sign successfull - -popd -:skipsign - -echo Building Installer - -%msbuild% /t:Restore,Rebuild /p:Configuration=Release %REPO_ROOT_FOLDER%\src\gsudo.Installer.sln /v:Minimal -if errorlevel 1 echo Buid Failed & pause & popd & goto badend - -echo Signing Installer - -if 'skipsign'=='%1' goto skipbuild -::%SignToolPath%signtool.exe sign /n "Open Source Developer, Gerardo Grignoli" /fd SHA256 /t http://timestamp.digicert.com %REPO_ROOT_FOLDER%\src\gsudo.Installer\bin\Release\gsudomsi.msi -%SignToolPath%signtool.exe sign /f C:\git\code_signing.pfx /p 1234 /fd SHA256 /t http://timestamp.digicert.com %REPO_ROOT_FOLDER%\src\gsudo.Installer\bin\Release\gsudomsi.msi - -:skipbuild - -COPY %REPO_ROOT_FOLDER%\src\gsudo.Installer\bin\Release\gsudomsi.msi %OUTPUT_FOLDER%\gsudoSetup.msi -COPY %BIN_FOLDER%\package\*.* %OUTPUT_FOLDER%\bin - -:: Apply version number to gsudoModule.psd1 -pushd %OUTPUT_FOLDER%\bin -powershell -NoProfile -Command "(gc gsudoModule.psd1) -replace 'ModuleVersion = \"0.1\"', 'ModuleVersion = \"%MajorMinorPatch%\"' | Out-File -encoding UTF8 gsudoModule.psd1" -popd - -pushd %REPO_ROOT_FOLDER%\Build - -:: Create GitHub release ZIP + ZIP hash -Set PSModulePath= -7z a "%OUTPUT_FOLDER%\gsudo.v%version%.zip" %BIN_FOLDER%\package\x86 -7z a "%OUTPUT_FOLDER%\gsudo.v%version%.zip" %BIN_FOLDER%\package\x64 -7z a "%OUTPUT_FOLDER%\gsudo.v%version%.zip" %BIN_FOLDER%\package\net46-AnyCpu - -powershell -NoProfile -Command ECHO (Get-FileHash %OUTPUT_FOLDER%\gsudo.v%version%.zip).hash > %OUTPUT_FOLDER%\gsudo.v%version%.zip.sha256 -powershell -NoProfile -Command ECHO (Get-FileHash %OUTPUT_FOLDER%\gsudoSetup.msi).hash > %OUTPUT_FOLDER%\gsudoSetup.msi.sha256 - -:: Chocolatey -git clean %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo\Bin -xf -md %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo\Bin 2> nul -copy %BIN_FOLDER%\package\net46-AnyCpu\*.* %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo\Bin\ -copy %REPO_ROOT_FOLDER%\Build\Chocolatey\verification.txt.template %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo\Tools\VERIFICATION.txt - -popd & pushd %REPO_ROOT_FOLDER%\Build\Chocolatey\gsudo - -powershell -NoProfile -Command "(gc gsudo.nuspec.template) -replace '#VERSION#', '%version%' | Out-File -encoding UTF8 gsudo.nuspec" -echo --- >> tools\verification.txt -echo Version Hashes for v%version% >> tools\verification.txt -echo. >> tools\verification.txt -powershell -NoProfile -Command "Get-FileHash bin\*.* | Out-String -Width 200" >> tools\verification.txt -echo. >> tools\verification.txt -powershell -NoProfile -Command "Get-childitem *.bak -Recurse | Remove-Item" -cd .. -choco pack gsudo\gsudo.nuspec -outdir="%OUTPUT_FOLDER%" - -popd -exit /b 0 -:badend -exit /b 1 diff --git a/build/BuildInstaller.cmd b/build/BuildInstaller.cmd deleted file mode 100644 index d1b69e83..00000000 --- a/build/BuildInstaller.cmd +++ /dev/null @@ -1,20 +0,0 @@ -@pushd %~dp0 -@if ''=='%1' echo Missing version number -@if ''=='%1' goto end -set version=%1 -if 'skipbuild'=='%2' goto skipbuild - -if NOT DEFINED msbuild set msbuild="C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\MSBuild\Current\Bin\MSBuild.exe" -if NOT DEFINED SignToolPath set SignToolPath="C:\Program Files (x86)\Windows Kits\10\bin\10.0.18362.0\x64\" - -@echo Building with version number v%version% - -powershell -NoProfile -Command "(gc ..\src\gsudo.Installer\Constants.Template.wxi) -replace '#VERSION#', '%version%' | Out-File -encoding UTF8 ..\src\gsudo.Installer\Constants.wxi" -%msbuild% /t:Rebuild /p:Configuration=Release /p:WarningLevel=0 ..\src\gsudo.Installer.sln /p:Version=%version% -%SignToolPath%signtool.exe sign /n "Open Source Developer, Gerardo Grignoli" /fd SHA256 /tr "http://time.certum.pl" ..\src\gsudo.Installer\bin\Release\gsudomsi.msi - -goto end -:badend -exit /b 1 -:end -@popd \ No newline at end of file diff --git a/build/InstallTools.cmd b/build/InstallTools.cmd deleted file mode 100644 index 3660594b..00000000 --- a/build/InstallTools.cmd +++ /dev/null @@ -1,5 +0,0 @@ -choco install ilmerge -choco install GitVersion.Portable -choco install wixtoolset -choco install hub -choco install dotnet-7.0-sdk --pre \ No newline at end of file diff --git a/build/UploadToChoco.bat b/build/UploadToChoco.bat deleted file mode 100644 index 3fe6e002..00000000 --- a/build/UploadToChoco.bat +++ /dev/null @@ -1,17 +0,0 @@ -@Echo off - -pushd %~dp0\.. -set REPO_ROOT_FOLDER=%cd% - -:: Determine Version -gitversion /showvariable LegacySemVer > "%temp%\version.tmp" -SET /P version= < "%temp%\version.tmp" -set OUTPUT_FOLDER=%REPO_ROOT_FOLDER%\Build\Releases\%version% - -popd -pushd %OUTPUT_FOLDER% -echo Uploading v%version% to chocolatey -echo on -choco push gsudo.%version%.nupkg - -@popd \ No newline at end of file diff --git a/build/UploadToGitHub.bat b/build/UploadToGitHub.bat deleted file mode 100644 index f08d42ca..00000000 --- a/build/UploadToGitHub.bat +++ /dev/null @@ -1,30 +0,0 @@ -@Echo off - -pushd %~dp0\.. - -:: Determine Version -gitversion /showvariable LegacySemVer > "%temp%\version.tmp" -SET /P version= < "%temp%\version.tmp" - -set REPO_ROOT_FOLDER=%cd% -set BIN_FOLDER=%cd%\src\gsudo\bin -set OUTPUT_FOLDER=%REPO_ROOT_FOLDER%\Build\Releases\%version% - -popd - -if 'a'=='a%version%' echo Missing version number -if 'a'=='a%version%' goto end -echo Creating release: v%version% -pushd %~dp0\Releases\%version% -::scoop install hub - -:: Create release notes -pwsh -c """gsudo v%version%`n`n### Features`n### Fixes`n"" | Out-File ReleaseNotes.txt" -pwsh -nop -c "git log \"$((git tag)[-1])..HEAD\" --pretty=\"format:- %%s (%%h)\" | Out-File ReleaseNotes.txt -Append" -::pwsh -c "$arr=git log \"$((git tag)[-1])..HEAD\" --pretty=\"format:- %%s (%%h)\" | Sort-Object; $arr | %%{ $_.substring(0, $_.IndexOf(\":\")+1) } | %%{$_.toLower()} | select -unique | group | sort {$_.name} | %% { \"### $($_.name)\"; ($arr -like \"$($_.name)*\").Substring(\"$($_.name)\".Length)|%% {\"- $_\"} } | Out-File ReleaseNotes.txt -Append" -pwsh -nop -c "$tags=$(git tag); ""`r`n**Full Changelog**: https://github.com/gerardog/gsudo/compare/$($tags[-1])...v%version%"" | Out-File ReleaseNotes.txt -Append" - -echo on -hub release create -d -a gsudo.v%version%.zip -a gsudo.v%version%.zip.sha256 -a gsudoSetup.msi -a gsudoSetup.msi.sha256 -F ReleaseNotes.txt v%version% -@popd -:end From 2325a36536c95607f02221f885dfca093d00d3cf Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 03:54:17 -0300 Subject: [PATCH 05/28] chore(build): Github Actions relaunch do not create a duplicate release --- .github/workflows/build.yml | 350 ++++++++++++++++++------------------ 1 file changed, 177 insertions(+), 173 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9609b4c5..9dec94c1 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,173 +1,177 @@ -name: Build, Test & Release - -on: - push: - branches: - - Feature.NetCore - - master - -jobs: - test: - name: Test - runs-on: windows-latest - permissions: - id-token: write - contents: read - checks: write - steps: - - uses: actions/setup-dotnet@v2 - with: - dotnet-version: '7.0.x' - include-prerelease: true - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - name: Run Tests - run: ./build/02-test.ps1 - - name: Test Report DotNet - uses: dorny/test-reporter@v1 - if: success() || failure() # run this step even if previous step failed - with: - name: TestsResults (dotnet) - path: "**/TestResults*.trx" - reporter: dotnet-trx - fail-on-error: false - - name: Test Report PowerShell v5 - uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs - if: success() || failure() # run this step even if previous step failed - with: - test_results_path: ./testResults_PS5.xml - report_name: TestResults PowerShell v5.x - report_title: PowerShell v5 Tests - github_token: ${{ secrets.GITHUB_TOKEN }} - - - name: Test Report PowerShell v7 - uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs - if: success() || failure() # run this step even if previous step failed - with: - test_results_path: ./testResults_PS7.xml - report_name: TestResults PowerShell Core (v7.x) - report_title: PowerShell v7 Tests - github_token: ${{ secrets.GITHUB_TOKEN }} -# - uses: OrbitalOwen/desktop-screenshot-action@0.1 -# if: always() -# with: -# file-name: 'desktop.jpg' - - build: - name: Build - runs-on: windows-latest - steps: - - uses: actions/setup-dotnet@v2 - with: - dotnet-version: '7.0.x' - include-prerelease: true - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - name: Install dependencies - run: choco install GitVersion.Portable ilmerge --confirm --no-progress - - name: Update project version - run: gitversion /l console /output buildserver /updateAssemblyInfo /verbosity minimal - - name: Get project version - id: getversion - run: | - echo "::set-output name=version::$(gitversion /showvariable LegacySemVer)" - echo "::set-output name=version_MajorMinorPatch::$(gitversion /showvariable MajorMinorPatch)" - - name: Build - run: ./build/01-build.ps1 - - name: Upload build artifacts - uses: actions/upload-artifact@v3 - with: - name: Binaries - path: ./artifacts - outputs: - version: ${{ steps.getversion.outputs.version }} - version_MajorMinorPatch: ${{ steps.getversion.outputs.version_MajorMinorPatch }} - - release: - name: Sign & Release to GitHub - #if: github.ref == 'refs/heads/master' && github.repository == 'gerardog/gsudo' - if: github.repository == 'gerardog/gsudo' - runs-on: windows-latest - needs: [build, test] - #needs: build - environment: - name: release-github - env: - cert_path: "C:\\secret\\cert.pfx" - cert_key: ${{ secrets.P_F_X_Key }} - version: ${{ needs.build.outputs.version }} - version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} - permissions: - contents: write - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - uses: actions/download-artifact@v3 - with: - name: Binaries - path: ./artifacts - - name: Decode certificate - # First encode and upload as environment secret using: [convert]::ToBase64String((Get-Content .\code_signing.pfx -AsByteStream)) - run: | - $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.p_f_x }}") - $_ = mkdir (split-path -parent $env:cert_path) -ErrorAction Ignore - [IO.File]::WriteAllBytes("$env:cert_path", $pfx_cert_byte) - - name: Code Sign - run: ./build/03-sign.ps1 - - name: Upload build artifacts - uses: actions/upload-artifact@v3 - with: - name: Binaries - path: ./artifacts - - name: Package for GitHub Release - run: ./build/04-release-GitHub.ps1 - - name: Remove the pfx - run: Remove-Item -path $env:cert_path - - name: Upload installer artifacts - uses: actions/upload-artifact@v3 - with: - name: Installer - path: ./artifacts/gsudoSetup.msi - - name: Create Release - uses: ncipollo/release-action@v1.10.0 - with: - artifacts: "artifacts/*.*" - token: ${{ secrets.GITHUB_TOKEN }} - draft: true - generateReleaseNotes: true - name: gsudo v${{env.version}} - tag: v${{env.version}} - commit: ${{env.GITHUB_SHA}} - - chocolatey: - name: Pack & Release to Chocolatey - #if: github.ref == 'refs/heads/master' && github.repository == 'gerardog/gsudo' - if: github.repository == 'gerardog/gsudo' - runs-on: windows-latest - #needs: [build, test] - needs: [build, release] - environment: - name: release-chocolatey - env: - version: ${{ needs.build.outputs.version }} - version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - uses: actions/download-artifact@v3 - with: - name: Binaries - path: ./artifacts - - name: Import Chocolatey Api Key - run: choco apikey --key ${{ secrets.CHOCOLATEY_APIKEY }} --source https://push.chocolatey.org/ - - name: Build Package for Chocolatey & Upload - run: ./build/05-release-Chocolatey.ps1 - - name: Upload build artifacts - uses: actions/upload-artifact@v3 - with: - name: Binaries - path: ./artifacts +name: Build, Test & Release + +on: + push: + branches: + - Feature.NetCore + - master + +jobs: + test: + name: Test + runs-on: windows-latest + permissions: + id-token: write + contents: read + checks: write + steps: + - uses: actions/setup-dotnet@v2 + with: + dotnet-version: '7.0.x' + include-prerelease: true + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Run Tests + run: ./build/02-test.ps1 + - name: Test Report DotNet + uses: dorny/test-reporter@v1 + if: success() || failure() # run this step even if previous step failed + with: + name: TestsResults (dotnet) + path: "**/TestResults*.trx" + reporter: dotnet-trx + fail-on-error: false + - name: Test Report PowerShell v5 + uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs + if: success() || failure() # run this step even if previous step failed + with: + test_results_path: ./testResults_PS5.xml + report_name: TestResults PowerShell v5.x + report_title: PowerShell v5 Tests + github_token: ${{ secrets.GITHUB_TOKEN }} + + - name: Test Report PowerShell v7 + uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs + if: success() || failure() # run this step even if previous step failed + with: + test_results_path: ./testResults_PS7.xml + report_name: TestResults PowerShell Core (v7.x) + report_title: PowerShell v7 Tests + github_token: ${{ secrets.GITHUB_TOKEN }} +# - uses: OrbitalOwen/desktop-screenshot-action@0.1 +# if: always() +# with: +# file-name: 'desktop.jpg' + + build: + name: Build + runs-on: windows-latest + steps: + - uses: actions/setup-dotnet@v2 + with: + dotnet-version: '7.0.x' + include-prerelease: true + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Install dependencies + run: choco install GitVersion.Portable ilmerge --confirm --no-progress + - name: Update project version + run: gitversion /l console /output buildserver /updateAssemblyInfo /verbosity minimal + - name: Get project version + id: getversion + run: | + echo "::set-output name=version::$(gitversion /showvariable LegacySemVer)" + echo "::set-output name=version_MajorMinorPatch::$(gitversion /showvariable MajorMinorPatch)" + - name: Build + run: ./build/01-build.ps1 + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: Binaries + path: ./artifacts + outputs: + version: ${{ steps.getversion.outputs.version }} + version_MajorMinorPatch: ${{ steps.getversion.outputs.version_MajorMinorPatch }} + + release: + name: Sign & Release to GitHub + #if: github.ref == 'refs/heads/master' && github.repository == 'gerardog/gsudo' + if: github.repository == 'gerardog/gsudo' + runs-on: windows-latest + needs: [build, test] + #needs: build + environment: + name: release-github + env: + cert_path: "C:\\secret\\cert.pfx" + cert_key: ${{ secrets.P_F_X_Key }} + version: ${{ needs.build.outputs.version }} + version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} + permissions: + contents: write + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: actions/download-artifact@v3 + with: + name: Binaries + path: ./artifacts + - name: Decode certificate + # First encode and upload as environment secret using: [convert]::ToBase64String((Get-Content .\code_signing.pfx -AsByteStream)) + run: | + $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.p_f_x }}") + $_ = mkdir (split-path -parent $env:cert_path) -ErrorAction Ignore + [IO.File]::WriteAllBytes("$env:cert_path", $pfx_cert_byte) + - name: Code Sign + run: ./build/03-sign.ps1 + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: Binaries + path: ./artifacts + - name: Package for GitHub Release + run: ./build/04-release-GitHub.ps1 + - name: Remove the pfx + run: Remove-Item -path $env:cert_path + - name: Upload installer artifacts + uses: actions/upload-artifact@v3 + with: + name: Installer + path: ./artifacts/gsudoSetup.msi + - name: Create Release + uses: ncipollo/release-action@v1.10.0 + with: + artifacts: "artifacts/*.*" + token: ${{ secrets.GITHUB_TOKEN }} + draft: true + prerelease: true + generateReleaseNotes: true + name: gsudo v${{env.version}} + tag: v${{env.version}} + commit: ${{env.GITHUB_SHA}} + allowUpdates: true + omitBodyDuringUpdate: true + replacesArtifacts: true + + chocolatey: + name: Pack & Release to Chocolatey + #if: github.ref == 'refs/heads/master' && github.repository == 'gerardog/gsudo' + if: github.repository == 'gerardog/gsudo' + runs-on: windows-latest + #needs: [build, test] + needs: [build, release] + environment: + name: release-chocolatey + env: + version: ${{ needs.build.outputs.version }} + version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: actions/download-artifact@v3 + with: + name: Binaries + path: ./artifacts + - name: Import Chocolatey Api Key + run: choco apikey --key ${{ secrets.CHOCOLATEY_APIKEY }} --source https://push.chocolatey.org/ + - name: Build Package for Chocolatey & Upload + run: ./build/05-release-Chocolatey.ps1 + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: Binaries + path: ./artifacts From 55cdc9a7425dffeccd4bba7d4bcb35e7d64f2ff9 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 14:47:23 -0300 Subject: [PATCH 06/28] chore(build) --- .github/workflows/ci.yml | 83 +++++++++++++++++++ .github/workflows/{build.yml => release.yml} | 84 +------------------- 2 files changed, 87 insertions(+), 80 deletions(-) create mode 100644 .github/workflows/ci.yml rename .github/workflows/{build.yml => release.yml} (50%) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..98546410 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,83 @@ +name: CI Build & Test + +on: + push: + +jobs: + test: + name: Test + runs-on: windows-latest + permissions: + id-token: write + contents: read + checks: write + steps: + - uses: actions/setup-dotnet@v2 + with: + dotnet-version: '7.0.x' + include-prerelease: true + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Run Tests + run: ./build/02-test.ps1 + - name: Test Report DotNet + uses: dorny/test-reporter@v1 + if: success() || failure() # run this step even if previous step failed + with: + name: TestsResults (dotnet) + path: "**/TestResults*.trx" + reporter: dotnet-trx + fail-on-error: false + - name: Test Report PowerShell v5 + uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs + if: success() || failure() # run this step even if previous step failed + with: + test_results_path: ./testResults_PS5.xml + report_name: TestResults PowerShell v5.x + report_title: PowerShell v5 Tests + github_token: ${{ secrets.GITHUB_TOKEN }} + + - name: Test Report PowerShell v7 + uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs + if: success() || failure() # run this step even if previous step failed + with: + test_results_path: ./testResults_PS7.xml + report_name: TestResults PowerShell Core (v7.x) + report_title: PowerShell v7 Tests + github_token: ${{ secrets.GITHUB_TOKEN }} +# - uses: OrbitalOwen/desktop-screenshot-action@0.1 +# if: always() +# with: +# file-name: 'desktop.jpg' + + build: + name: Build + runs-on: windows-latest + steps: + - uses: actions/setup-dotnet@v2 + with: + dotnet-version: '7.0.x' + include-prerelease: true + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Install dependencies + run: choco install GitVersion.Portable ilmerge --confirm --no-progress + - name: Update project version + run: gitversion /l console /output buildserver /updateAssemblyInfo /verbosity minimal + - name: Get project version + id: getversion + run: | + echo "::set-output name=version::$(gitversion /showvariable LegacySemVer)" + echo "::set-output name=version_MajorMinorPatch::$(gitversion /showvariable MajorMinorPatch)" + - name: Build + run: ./build/01-build.ps1 + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: Binaries + path: ./artifacts + outputs: + version: ${{ steps.getversion.outputs.version }} + version_MajorMinorPatch: ${{ steps.getversion.outputs.version_MajorMinorPatch }} \ No newline at end of file diff --git a/.github/workflows/build.yml b/.github/workflows/release.yml similarity index 50% rename from .github/workflows/build.yml rename to .github/workflows/release.yml index 9dec94c1..1520cc42 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/release.yml @@ -1,89 +1,13 @@ -name: Build, Test & Release +name: Release on: push: - branches: - - Feature.NetCore - - master + tags: + - v* jobs: - test: - name: Test - runs-on: windows-latest - permissions: - id-token: write - contents: read - checks: write - steps: - - uses: actions/setup-dotnet@v2 - with: - dotnet-version: '7.0.x' - include-prerelease: true - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - name: Run Tests - run: ./build/02-test.ps1 - - name: Test Report DotNet - uses: dorny/test-reporter@v1 - if: success() || failure() # run this step even if previous step failed - with: - name: TestsResults (dotnet) - path: "**/TestResults*.trx" - reporter: dotnet-trx - fail-on-error: false - - name: Test Report PowerShell v5 - uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs - if: success() || failure() # run this step even if previous step failed - with: - test_results_path: ./testResults_PS5.xml - report_name: TestResults PowerShell v5.x - report_title: PowerShell v5 Tests - github_token: ${{ secrets.GITHUB_TOKEN }} - - - name: Test Report PowerShell v7 - uses: zyborg/pester-tests-report@v1.5.0 # https://github.com/zyborg/pester-tests-report#inputs - if: success() || failure() # run this step even if previous step failed - with: - test_results_path: ./testResults_PS7.xml - report_name: TestResults PowerShell Core (v7.x) - report_title: PowerShell v7 Tests - github_token: ${{ secrets.GITHUB_TOKEN }} -# - uses: OrbitalOwen/desktop-screenshot-action@0.1 -# if: always() -# with: -# file-name: 'desktop.jpg' - build: - name: Build - runs-on: windows-latest - steps: - - uses: actions/setup-dotnet@v2 - with: - dotnet-version: '7.0.x' - include-prerelease: true - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - name: Install dependencies - run: choco install GitVersion.Portable ilmerge --confirm --no-progress - - name: Update project version - run: gitversion /l console /output buildserver /updateAssemblyInfo /verbosity minimal - - name: Get project version - id: getversion - run: | - echo "::set-output name=version::$(gitversion /showvariable LegacySemVer)" - echo "::set-output name=version_MajorMinorPatch::$(gitversion /showvariable MajorMinorPatch)" - - name: Build - run: ./build/01-build.ps1 - - name: Upload build artifacts - uses: actions/upload-artifact@v3 - with: - name: Binaries - path: ./artifacts - outputs: - version: ${{ steps.getversion.outputs.version }} - version_MajorMinorPatch: ${{ steps.getversion.outputs.version_MajorMinorPatch }} + uses: ./.github/workflows/ci.yml release: name: Sign & Release to GitHub From f63d3d5d13b0c1fd35e19c6b483a710714957d50 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 14:54:35 -0300 Subject: [PATCH 07/28] chore(build) --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1520cc42..0c34a9fa 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -3,7 +3,7 @@ name: Release on: push: tags: - - v* + - 'v*' jobs: build: From 02ffbaa46ae5445c3475bcc0db93337a8d776325 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 14:59:22 -0300 Subject: [PATCH 08/28] chore(build) --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 98546410..b3d97fe7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,6 +2,7 @@ name: CI Build & Test on: push: + workflow_call: jobs: test: From d048b3e39e5cb1b211154acd585685db95264062 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 15:01:03 -0300 Subject: [PATCH 09/28] chore(build) --- .github/workflows/release.yml | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0c34a9fa..d36248f2 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,15 +14,13 @@ jobs: #if: github.ref == 'refs/heads/master' && github.repository == 'gerardog/gsudo' if: github.repository == 'gerardog/gsudo' runs-on: windows-latest - needs: [build, test] - #needs: build environment: name: release-github env: cert_path: "C:\\secret\\cert.pfx" cert_key: ${{ secrets.P_F_X_Key }} - version: ${{ needs.build.outputs.version }} - version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} +# version: ${{ needs.build.outputs.version }} +# version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} permissions: contents: write steps: @@ -76,12 +74,12 @@ jobs: if: github.repository == 'gerardog/gsudo' runs-on: windows-latest #needs: [build, test] - needs: [build, release] + needs: release environment: name: release-chocolatey - env: - version: ${{ needs.build.outputs.version }} - version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} +# env: +# version: ${{ needs.build.outputs.version }} +# version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} steps: - uses: actions/checkout@v2 with: From 033c40a356a9511640f9f1361190f7d44db76609 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 15:03:41 -0300 Subject: [PATCH 10/28] chore(build) --- .github/workflows/release.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d36248f2..12ae4b48 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -8,6 +8,10 @@ on: jobs: build: uses: ./.github/workflows/ci.yml + permissions: + id-token: write + contents: read + checks: write release: name: Sign & Release to GitHub From dc7e491f9bb697352a174bc2b4e64fcff73a0224 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 15:19:37 -0300 Subject: [PATCH 11/28] chore(build) --- .github/workflows/ci.yml | 10 +++++++++- .github/workflows/release.yml | 16 +++++++++------- 2 files changed, 18 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b3d97fe7..794b2581 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,8 +2,16 @@ name: CI Build & Test on: push: + branches: workflow_call: - + outputs: + version: + description: "Version" + value: ${{ jobs.build.outputs.version }} + version_MajorMinorPatch: + description: "Version (without prerelease tag)" + value: ${{ jobs.build.outputs.version_MajorMinorPatch }} + jobs: test: name: Test diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 12ae4b48..d9c97e33 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -11,7 +11,8 @@ jobs: permissions: id-token: write contents: read - checks: write + checks: write + outputs release: name: Sign & Release to GitHub @@ -20,11 +21,12 @@ jobs: runs-on: windows-latest environment: name: release-github + needs: build env: cert_path: "C:\\secret\\cert.pfx" cert_key: ${{ secrets.P_F_X_Key }} -# version: ${{ needs.build.outputs.version }} -# version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} + version: ${{ needs.build.outputs.version }} + version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} permissions: contents: write steps: @@ -78,12 +80,12 @@ jobs: if: github.repository == 'gerardog/gsudo' runs-on: windows-latest #needs: [build, test] - needs: release + needs: build, release environment: name: release-chocolatey -# env: -# version: ${{ needs.build.outputs.version }} -# version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} + env: + version: ${{ needs.build.outputs.version }} + version_MajorMinorPatch: ${{ needs.build.outputs.version_MajorMinorPatch }} steps: - uses: actions/checkout@v2 with: From 0206646dafd6ed2e193933045b0261a5568a6f03 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 15:23:33 -0300 Subject: [PATCH 12/28] chore(build) --- .github/workflows/release.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d9c97e33..fe0db23c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -12,7 +12,6 @@ jobs: id-token: write contents: read checks: write - outputs release: name: Sign & Release to GitHub From 4e756d1286b3eb19885bc7ed0e049235c1af7733 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 15:24:24 -0300 Subject: [PATCH 13/28] chore(build) --- .github/workflows/release.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index fe0db23c..1f655f23 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -78,8 +78,7 @@ jobs: #if: github.ref == 'refs/heads/master' && github.repository == 'gerardog/gsudo' if: github.repository == 'gerardog/gsudo' runs-on: windows-latest - #needs: [build, test] - needs: build, release + needs: [build, release] environment: name: release-chocolatey env: From c7096089f26a1521623a7a6dd83e5862d4b8a3b9 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 15:27:06 -0300 Subject: [PATCH 14/28] chore(build) --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 794b2581..d865295f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -3,6 +3,8 @@ name: CI Build & Test on: push: branches: + tags-ignore: + - '**' workflow_call: outputs: version: From 9bad789993797168e1544191cef7ae1963fe5a92 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 19:19:24 -0300 Subject: [PATCH 15/28] test --- test | 1 + 1 file changed, 1 insertion(+) create mode 100644 test diff --git a/test b/test new file mode 100644 index 00000000..edf0effb --- /dev/null +++ b/test @@ -0,0 +1 @@ +hi From e0bbfede2334e526b29195b2b234838d6102fb93 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 19:21:43 -0300 Subject: [PATCH 16/28] chore(build) --- .github/workflows/ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d865295f..8816831a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,7 +2,6 @@ name: CI Build & Test on: push: - branches: tags-ignore: - '**' workflow_call: From 845c8c4ff0c5ef787e7c8ea0fdca9dae87b7d11a Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 19:22:37 -0300 Subject: [PATCH 17/28] chore(build) --- test | 1 - 1 file changed, 1 deletion(-) delete mode 100644 test diff --git a/test b/test deleted file mode 100644 index edf0effb..00000000 --- a/test +++ /dev/null @@ -1 +0,0 @@ -hi From 1fb6cfca3f74a60adb3ad375f1e77b3e5901a38d Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 19:24:08 -0300 Subject: [PATCH 18/28] chore(build) --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8816831a..fa5a6719 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,6 +2,8 @@ name: CI Build & Test on: push: + branches: + - '**' tags-ignore: - '**' workflow_call: From 910294189ec619874b507eec3f42ef2830d2dd21 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 19:53:10 -0300 Subject: [PATCH 19/28] chore(build) --- .github/workflows/ci.yml | 2 +- .github/workflows/docs.yml | 82 +++++++++++++++++++------------------ build/04-release-GitHub.ps1 | 6 +-- 3 files changed, 45 insertions(+), 45 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fa5a6719..ea75efe2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,4 +1,4 @@ -name: CI Build & Test +name: CI Build on: push: diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index c9853608..a6710a3b 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,41 +1,43 @@ -name: Build Documentation Website - -on: - push: - branches: - - main - - docs - # Review gh actions docs if you want to further define triggers, paths, etc - # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on - -jobs: - deploy: - name: Deploy Docs to GitHub Pages - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - cache: yarn - cache-dependency-path: '**/yarn.lock' - - name: Install dependencies - run: yarn install --frozen-lockfile - - name: Build website - run: yarn build - - # Popular action to deploy to GitHub Pages: - # Docs: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus - - name: Deploy to GitHub Pages - uses: peaceiris/actions-gh-pages@v3 - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - # Build output to publish to the `gh-pages` branch: - publish_dir: ./docs/build - # The following lines assign commit authorship to the official - # GH-Actions bot for deploys to `gh-pages` branch: - # https://github.com/actions/checkout/issues/13#issuecomment-724415212 - # The GH actions bot is used by default if you didn't specify the two fields. - # You can swap them out with your own user credentials. - user_name: github-actions[bot] +name: Documentation web + +on: + push: + branches: + - main + - docs + paths: + - 'docs/**' + # Review gh actions docs if you want to further define triggers, paths, etc + # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on + +jobs: + deploy: + name: Deploy Docs to GitHub Pages + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v3 + with: + node-version: 16.x + cache: yarn + cache-dependency-path: '**/yarn.lock' + - name: Install dependencies + run: yarn install --frozen-lockfile + - name: Build website + run: yarn build + + # Popular action to deploy to GitHub Pages: + # Docs: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus + - name: Deploy to GitHub Pages + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + # Build output to publish to the `gh-pages` branch: + publish_dir: ./docs/build + # The following lines assign commit authorship to the official + # GH-Actions bot for deploys to `gh-pages` branch: + # https://github.com/actions/checkout/issues/13#issuecomment-724415212 + # The GH actions bot is used by default if you didn't specify the two fields. + # You can swap them out with your own user credentials. + user_name: github-actions[bot] user_email: 41898282+github-actions[bot]@users.noreply.github.com \ No newline at end of file diff --git a/build/04-release-GitHub.ps1 b/build/04-release-GitHub.ps1 index f1e86acb..b4e33659 100644 --- a/build/04-release-GitHub.ps1 +++ b/build/04-release-GitHub.ps1 @@ -14,10 +14,8 @@ if ($env:version) { Get-ChildItem .\artifacts\ -File | Remove-Item "- Packaging v$version" - -$files = Get-ChildItem -Path ./artifacts/x86,./artifacts/x64,./artifacts/net46-AnyCpu -Exclude *.pdb -Compress-Archive -Path $files -DestinationPath "artifacts/gsudo.v$($version).zip" -force -CompressionLevel Optimal - +rm ./Artifacts/*.pdb -Recurse +Compress-Archive -Path ./artifacts/x86,./artifacts/x64,./artifacts/net46-AnyCpu -DestinationPath "artifacts/gsudo.v$($version).zip" -force -CompressionLevel Optimal (Get-FileHash artifacts\gsudo.v$($version).zip).hash > artifacts\gsudo.v$($version).zip.sha256 $msbuild = &"${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -latest -prerelease -products * -requires Microsoft.Component.MSBuild -find MSBuild\**\Bin\MSBuild.exe From fa41c977b9d8d7ee83998e86a4d99ab9504342f0 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 20:15:05 -0300 Subject: [PATCH 20/28] chore(build) --- build/04-release-GitHub.ps1 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/build/04-release-GitHub.ps1 b/build/04-release-GitHub.ps1 index b4e33659..5fadf8f0 100644 --- a/build/04-release-GitHub.ps1 +++ b/build/04-release-GitHub.ps1 @@ -11,10 +11,10 @@ if ($env:version) { } "- Using version number v$version / v$version_MajorMinorPatch" -Get-ChildItem .\artifacts\ -File | Remove-Item - "- Packaging v$version" -rm ./Artifacts/*.pdb -Recurse +Get-ChildItem .\artifacts\ -File | Remove-Item # Remove files on artifacts root +Get-ChildItem .\artifacts\ -Filter *.pdb -Recurse | Remove-Item # Remove *.pdb on subfolders + Compress-Archive -Path ./artifacts/x86,./artifacts/x64,./artifacts/net46-AnyCpu -DestinationPath "artifacts/gsudo.v$($version).zip" -force -CompressionLevel Optimal (Get-FileHash artifacts\gsudo.v$($version).zip).hash > artifacts\gsudo.v$($version).zip.sha256 From 3422e17277c3ce3d7faa679ef7945e0f02c03051 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sat, 3 Sep 2022 20:30:22 -0300 Subject: [PATCH 21/28] chore(build) --- appveyor.yml | 53 ---------------------------------------------------- 1 file changed, 53 deletions(-) delete mode 100644 appveyor.yml diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index 0bfc4dc6..00000000 --- a/appveyor.yml +++ /dev/null @@ -1,53 +0,0 @@ -image: Visual Studio 2022 -clone_folder: c:\git\gsudo -platform: Any CPU -configuration: Release - -cache: - - src\gsudo\packages -> **\packages.config # preserve "packages" directory in the root of build folder but will reset it if packages.config is modified - - '%LocalAppData%\NuGet\Cache' # NuGet < v3 - - '%LocalAppData%\NuGet\v3-cache' # NuGet v3 - -init: - - git config --global core.autocrlf true - - powershell -noprofile -command "Install-Module PSReadLine -Force -SkipPublisherCheck -AllowPrerelease" - -install: - - choco install dotnet-7.0-sdk --pre - - choco install gitversion.portable -y - - ps: Install-Module Pester -Force -SkipPublisherCheck -Scope CurrentUser - -before_build: - - ps: gitversion /l console /output buildserver /updateAssemblyInfo /verbosity minimal - -build_script: - - dotnet restore src\gsudo.sln - - dotnet build src\gsudo.sln -c Release - # net 7.0 x64 build with NativeAOT - - dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x64 --sc -p:PublishAot=true -p:TrimmerDefaultAction=link -p:IlcOptimizationPreference=Size - # net 7.0 x86 does not support NativeAOT - - dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net7.0 -r win-x86 --sc -p:PublishReadyToRun=true -p:PublishSingleFile=true - # net framework 4.6 AnyCpu - - dotnet publish .\src\gsudo\gsudo.csproj -c Release -f net46 -p:Platform=x64 - -after_build: - - 7z a gsudo.net70.x64.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip .\src\gsudo\bin\net7.0\win-x64\publish\*.* .\src\gsudo.Wrappers\gsudoModule.* .\src\gsudo.Wrappers\Invoke-gsudo.ps1 - - appveyor PushArtifact gsudo.net70.x64.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip - - - 7z a gsudo.net70.x86.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip .\src\gsudo\bin\net7.0\win-x86\publish\*.* .\src\gsudo.Wrappers\gsudoModule.* .\src\gsudo.Wrappers\Invoke-gsudo.ps1 - - appveyor PushArtifact gsudo.net70.x86.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip - - - 7z a gsudo.net46.AnyCpu.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip .\src\gsudo\bin\net46\publish\*.* .\src\gsudo.Wrappers\gsudoModule.* .\src\gsudo.Wrappers\Invoke-gsudo.ps1 - - appveyor PushArtifact gsudo.net46.AnyCpu.Unsigned.v%APPVEYOR_BUILD_VERSION%.zip - -test_script: - - ps: $Env:Path+=";$($Env:APPVEYOR_BUILD_FOLDER)/src/gsudo/bin/net7.0/win-x64/publish;"; - - vstest.console /logger:Appveyor %APPVEYOR_BUILD_FOLDER%\src\gsudo.Tests\bin\%CONFIGURATION%\net7.0\gsudo.Tests.dll - - powershell -c Invoke-Pester -EnableExit -OutputFile Powershell5Tests.xml -OutputFormat NUnitXml - - pwsh -c Invoke-Pester -EnableExit -OutputFile PowershellCoreTests.xml -OutputFormat NUnitXml - - ps: | - (New-Object 'System.Net.WebClient').UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path "Powershell5Tests.xml")) - (New-Object 'System.Net.WebClient').UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path "PowershellCoreTests.xml")) - -on_finish: - - ps: if($env:APPVEYOR_RDP_ENABLED -eq 'TRUE') { $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1')) } \ No newline at end of file From 7d7bfe097a75536bb4f0f4c98186b0ad70822262 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sun, 4 Sep 2022 18:01:19 -0300 Subject: [PATCH 22/28] chore: Allow Docs workflow trigger from master branch --- .github/workflows/docs.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index a6710a3b..71f7f557 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -3,7 +3,7 @@ name: Documentation web on: push: branches: - - main + - master - docs paths: - 'docs/**' @@ -40,4 +40,4 @@ jobs: # The GH actions bot is used by default if you didn't specify the two fields. # You can swap them out with your own user credentials. user_name: github-actions[bot] - user_email: 41898282+github-actions[bot]@users.noreply.github.com \ No newline at end of file + user_email: 41898282+github-actions[bot]@users.noreply.github.com From 76ddae9568b58e9db93187b403795f1305b5c4d8 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sun, 4 Sep 2022 18:21:17 -0300 Subject: [PATCH 23/28] docs: Clean docs workflow --- .github/workflows/docs.yml | 52 ++++++++++++++++++++++---------------- 1 file changed, 30 insertions(+), 22 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 71f7f557..4e5a568b 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,4 +1,4 @@ -name: Documentation web +name: Docs Build & Deploy on: push: @@ -6,16 +6,30 @@ on: - master - docs paths: - - 'docs/**' - # Review gh actions docs if you want to further define triggers, paths, etc - # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on + - 'docs/**' + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read + pages: write + id-token: write + +# Allow one concurrent deployment +concurrency: + group: "pages" + cancel-in-progress: true jobs: deploy: - name: Deploy Docs to GitHub Pages - runs-on: ubuntu-latest + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - name: Checkout + uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: 16.x @@ -25,19 +39,13 @@ jobs: run: yarn install --frozen-lockfile - name: Build website run: yarn build - - # Popular action to deploy to GitHub Pages: - # Docs: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus - - name: Deploy to GitHub Pages - uses: peaceiris/actions-gh-pages@v3 + - name: Setup Pages + uses: actions/configure-pages@v2 + - name: Upload artifact + uses: actions/upload-pages-artifact@v1 with: - github_token: ${{ secrets.GITHUB_TOKEN }} - # Build output to publish to the `gh-pages` branch: - publish_dir: ./docs/build - # The following lines assign commit authorship to the official - # GH-Actions bot for deploys to `gh-pages` branch: - # https://github.com/actions/checkout/issues/13#issuecomment-724415212 - # The GH actions bot is used by default if you didn't specify the two fields. - # You can swap them out with your own user credentials. - user_name: github-actions[bot] - user_email: 41898282+github-actions[bot]@users.noreply.github.com + # Upload entire repository + path: './docs/build' + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v1 From 6a4f45deab368e420f9d272a8e94d0fc87b1d8d7 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sun, 4 Sep 2022 18:26:36 -0300 Subject: [PATCH 24/28] docs: Clean docs workflow (#164) --- .github/workflows/docs.yml | 52 ++++++++++++++++++++++---------------- 1 file changed, 30 insertions(+), 22 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 71f7f557..4e5a568b 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,4 +1,4 @@ -name: Documentation web +name: Docs Build & Deploy on: push: @@ -6,16 +6,30 @@ on: - master - docs paths: - - 'docs/**' - # Review gh actions docs if you want to further define triggers, paths, etc - # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on + - 'docs/**' + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read + pages: write + id-token: write + +# Allow one concurrent deployment +concurrency: + group: "pages" + cancel-in-progress: true jobs: deploy: - name: Deploy Docs to GitHub Pages - runs-on: ubuntu-latest + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - name: Checkout + uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: 16.x @@ -25,19 +39,13 @@ jobs: run: yarn install --frozen-lockfile - name: Build website run: yarn build - - # Popular action to deploy to GitHub Pages: - # Docs: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus - - name: Deploy to GitHub Pages - uses: peaceiris/actions-gh-pages@v3 + - name: Setup Pages + uses: actions/configure-pages@v2 + - name: Upload artifact + uses: actions/upload-pages-artifact@v1 with: - github_token: ${{ secrets.GITHUB_TOKEN }} - # Build output to publish to the `gh-pages` branch: - publish_dir: ./docs/build - # The following lines assign commit authorship to the official - # GH-Actions bot for deploys to `gh-pages` branch: - # https://github.com/actions/checkout/issues/13#issuecomment-724415212 - # The GH actions bot is used by default if you didn't specify the two fields. - # You can swap them out with your own user credentials. - user_name: github-actions[bot] - user_email: 41898282+github-actions[bot]@users.noreply.github.com + # Upload entire repository + path: './docs/build' + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v1 From 34c9110be04491720d71d550e1df15c068cacbcc Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sun, 4 Sep 2022 18:38:34 -0300 Subject: [PATCH 25/28] docs: Removed .NET Framework requirement from install instructions. --- docs/docs/install.md | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/docs/docs/install.md b/docs/docs/install.md index d25f44d7..13bd0883 100644 --- a/docs/docs/install.md +++ b/docs/docs/install.md @@ -30,7 +30,6 @@ Or: -- Download [.NET Framework 4.8](https://dotnet.microsoft.com/download/dotnet-framework) (4.6 should work but, since you are there...) - Download `gsudoSetup.msi` from the [latest release](https://github.com/gerardog/gsudo/releases/latest), and run. @@ -38,9 +37,7 @@ Or: -- Enable TLS 1.2 using [Microsoft "Easy Fix" -](https://support.microsoft.com/en-us/topic/update-to-enable-tls-1-1-and-tls-1-2-as-default-secure-protocols-in-winhttp-in-windows-c4bd73d2-31d7-761e-0178-11268bb10392#bkmk_easy) -- Download [.NET Framework 4.8](https://dotnet.microsoft.com/download/dotnet-framework) (4.6 should work but, since you are there...) +- Enable TLS 1.2 using [Microsoft "Easy Fix"](https://support.microsoft.com/en-us/topic/update-to-enable-tls-1-1-and-tls-1-2-as-default-secure-protocols-in-winhttp-in-windows-c4bd73d2-31d7-761e-0178-11268bb10392#bkmk_easy) - Download `gsudoSetup.msi` from the [latest release](https://github.com/gerardog/gsudo/releases/latest), and run. - You probably want to update PowerShell up to 5.1 From 130902b723d80d8b877626542358e2d5ac6baee3 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sun, 4 Sep 2022 19:35:55 -0300 Subject: [PATCH 26/28] docs: updated Readme.md --- README.md | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 96a50794..8351f625 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,13 @@ # gsudo - a sudo for Windows [![Join the chat at https://gitter.im/gsudo/community](https://badges.gitter.im/gsudo/community.svg)](https://gitter.im/gsudo/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) -[![Build status](https://ci.appveyor.com/api/projects/status/nkd11bifhnqaxay9/branch/master?svg=true)](https://ci.appveyor.com/project/gerardog/gsudo) -[![Tests](https://img.shields.io/appveyor/tests/gerardog/gsudo/master)](https://ci.appveyor.com/project/gerardog/gsudo/build/tests) + +[![CI Build](https://github.com/gerardog/gsudo/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/gerardog/gsudo/actions/workflows/ci.yml) +[![Release](https://github.com/gerardog/gsudo/actions/workflows/release.yml/badge.svg?branch=master)](https://github.com/gerardog/gsudo/actions/workflows/release.yml) + +[![CI Build](actions/workflows/ci.yml/badge.svg?branch=master)](actions/workflows/ci.yml) +[![Release](actions/workflows/release.yml/badge.svg?branch=master)](/actions/workflows/release.yml) + [![Chocolatey Downloads](https://img.shields.io/chocolatey/dt/gsudo?label=Chocolatey%20Downloads)](https://community.chocolatey.org/packages/gsudo) [![GitHub Downloads](https://img.shields.io/github/downloads/gerardog/gsudo/total?label=GitHub%20Downloads)](https://github.com/gerardog/gsudo/releases/latest) @@ -236,9 +241,9 @@ The `Credentials Cache` allows to elevate several times from a parent process wi When I created `gsudo`, there were other `sudo` packages on most Windows popular package managers such as `Chocolatey` and `Scoop`, so I had no other choice to pick another name. `gsudo` installers create an alias for `sudo`, so feel free to use `sudo` on your command line to invoke `gsudo`. -- Why `.Net Framework 4.6`? +- Why did you migrated from `.Net Framework 4.6` to `.Net Core 7.0`? - Because 4.6 is included in every Windows 10/11 installation. `.Net Core` requires additional installation steps and provides no substantial benefit since `gsudo` is Windows-specific. (Other platforms can use the standard *nix sudo.) + Starting from v1.4.0, it is built using `.Net 7.0` NativaAOT. It loads faster and uses less memory, and runs on machines without any .Net runtime installed. Prior versions ` Date: Sun, 4 Sep 2022 19:42:25 -0300 Subject: [PATCH 27/28] docs: updated Readme.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8351f625..9e49f4a4 100644 --- a/README.md +++ b/README.md @@ -5,8 +5,8 @@ [![CI Build](https://github.com/gerardog/gsudo/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/gerardog/gsudo/actions/workflows/ci.yml) [![Release](https://github.com/gerardog/gsudo/actions/workflows/release.yml/badge.svg?branch=master)](https://github.com/gerardog/gsudo/actions/workflows/release.yml) -[![CI Build](actions/workflows/ci.yml/badge.svg?branch=master)](actions/workflows/ci.yml) -[![Release](actions/workflows/release.yml/badge.svg?branch=master)](/actions/workflows/release.yml) +[![CI Build](../../actions/workflows/ci.yml/badge.svg?branch=master)](../../actions/workflows/ci.yml) +[![Release](../../actions/workflows/release.yml/badge.svg?branch=master)](../../actions/workflows/release.yml) [![Chocolatey Downloads](https://img.shields.io/chocolatey/dt/gsudo?label=Chocolatey%20Downloads)](https://community.chocolatey.org/packages/gsudo) [![GitHub Downloads](https://img.shields.io/github/downloads/gerardog/gsudo/total?label=GitHub%20Downloads)](https://github.com/gerardog/gsudo/releases/latest) From 446183930b71d1ea61fa2d19b286befc07aa4a49 Mon Sep 17 00:00:00 2001 From: Gerardo Grignoli Date: Sun, 4 Sep 2022 20:14:21 -0300 Subject: [PATCH 28/28] Updated README.MD --- README.md | 46 ++++++++++++++++------------------------------ 1 file changed, 16 insertions(+), 30 deletions(-) diff --git a/README.md b/README.md index 9e49f4a4..4e8106b5 100644 --- a/README.md +++ b/README.md @@ -1,13 +1,8 @@ # gsudo - a sudo for Windows [![Join the chat at https://gitter.im/gsudo/community](https://badges.gitter.im/gsudo/community.svg)](https://gitter.im/gsudo/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) - -[![CI Build](https://github.com/gerardog/gsudo/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/gerardog/gsudo/actions/workflows/ci.yml) -[![Release](https://github.com/gerardog/gsudo/actions/workflows/release.yml/badge.svg?branch=master)](https://github.com/gerardog/gsudo/actions/workflows/release.yml) - [![CI Build](../../actions/workflows/ci.yml/badge.svg?branch=master)](../../actions/workflows/ci.yml) -[![Release](../../actions/workflows/release.yml/badge.svg?branch=master)](../../actions/workflows/release.yml) - +[![Release](../../actions/workflows/release.yml/badge.svg)](../../actions/workflows/release.yml) [![Chocolatey Downloads](https://img.shields.io/chocolatey/dt/gsudo?label=Chocolatey%20Downloads)](https://community.chocolatey.org/packages/gsudo) [![GitHub Downloads](https://img.shields.io/github/downloads/gerardog/gsudo/total?label=GitHub%20Downloads)](https://github.com/gerardog/gsudo/releases/latest) @@ -24,10 +19,10 @@ Just prepend `gsudo` (or the `sudo` alias) to your command and it will run eleva **NEW!** Extended documentation available at: https://gerardog.github.io/gsudo/ -## 💵 Please support gsudo 💵 +## Please support gsudo! 💵 -> Please consider [sponsoring gsudo](https://github.com/gerardog/gsudo/wiki/Sponsor-gsudo). -> It also helps support the costs of the yearly renewal for the code-signing certificate. +- Please consider [sponsoring gsudo](https://gerardog.github.io/gsudo/sponsor). It helps to cover the yearly renewal of the code-signing certificate. +- No money? No problem! Please give us a star! ⭐ ## Features @@ -38,6 +33,7 @@ Just prepend `gsudo` (or the `sudo` alias) to your command and it will run eleva - Supports being used on scripts: - Outputs of the elevated commands can be interpreted: E.g. StdOut/StdErr can be piped or captured (e.g. `gsudo dir | findstr /c:"bytes free" > FreeSpace.txt`) and exit codes too (`%errorlevel%`). If `gsudo` fails to elevate, the exit code will be 999. - If `gsudo` is invoked from an already elevated console, it will just run the command (it won't fail). So, you don't have to worry if you run `gsudo` or a script that uses `gsudo` from an already elevated console. (The UAC popup will not appear, as no elevation is required) + - `gsudo !!` elevates the last executed command. Works on CMD, Git-Bash, MinGW, Cygwin (and PowerShell with [gsudo module](#gsudomodule) only) ## Installation @@ -85,36 +81,26 @@ Show status information about current user, security, integrity level or other g **Examples:** ``` powershell -# elevate the current shell in the current console window (Cmd/PowerShell/Pwsh Core/Yori/Take Command/git-bash/cygwin) -gsudo +gsudo # elevates the current shell in the current console window (Supports Cmd/PowerShell/Pwsh Core/Yori/Take Command/git-bash/cygwin) -# launch the current shell elevated in a new console window -gsudo -n +gsudo -n # launch the current shell elevated in a new console window -# launch in new window and wait for exit -gsudo -n -w powershell ./Do-Something.ps1 +gsudo -n -w powershell ./Do-Something.ps1 # launch in new window and wait for exit -# launch windows app -gsudo notepad %windir%\system32\drivers\etc\hosts +gsudo notepad %windir%\system32\drivers\etc\hosts # launch windows app -# sudo alias built-in with choco/scoop/manual installers: -sudo notepad %windir%\system32\drivers\etc\hosts +sudo notepad # sudo alias built-in -# Cmd Commands: -gsudo type MySecretFile.txt -gsudo md "C:\Program Files\MyApp" - -# redirect/pipe input/output/error +# redirect/pipe input/output/error example gsudo dir | findstr /c:"bytes free" > FreeSpace.txt -# Configure Reduced logging -gsudo config LogLevel "Error" -# Configure a custom Elevated Prompt -gsudo config Prompt "$P [elevated]$G " -# Reset Elevated Prompt config to default value -gsudo config Prompt --reset +gsudo config LogLevel "Error" # Configure Reduced logging +gsudo config Prompt "$P [elevated]$G " # Configure a custom Elevated Prompt +gsudo config Prompt --reset # Reset to default value + # Enable credentials cache (less UAC popups): gsudo config CacheMode Auto + # Elevate last command (sudo bang bang) gsudo !! ```