Skip to content

Conversation

@kormic911
Copy link
Contributor

Merging to main to release 1.0.10
feat/self-updater
feat/explain command
feat/dry run functionality
fix/test cases to achieve close to100% coverage
fix/display issues

kormic911 and others added 29 commits September 7, 2025 21:31
…ed behind base64 for security reasons, also updating test cases and changing the way some of the code works to support better test cases.
…de duplication and refactored some code to be less complex by splitting them into their own files.
…for psscriptanalyzer, standardizing on write-statusmessage as well
…ile so it conforms to the format expected, more test cases and some refactoring and elimination of duplicate code.
…run functionality across the various write operations
1.0.10 features
expanded unit tests
added dryrun functionality, around 80% done
added -explain command to devsetup
added environment file validation
removed a decent amount of code duplication
Automated Release Tagging for 1.0.10 in DevSetup.psd1
….0.100 because it lacked multiple number parsing i.e. [0-9]+
…version-numbers

Fixing an issue with parsing of version numbers where 1.0.10 became 1…
…at use the new structure

Added parity code to ensure dryrun works properly with powershell modules
Refactored code to be more in line with our guidelines and removed code that is no longer being used, making the functions simpler in general
Updated test cases to maintain 100% test coverage
…for-parity

Updated powershell provider to be in parity with the other modules that use the new structure
Refactored code to be in line with the other providers
Refactored the test cases to cover this new or removed functionality
Ensured DryRun compatibilityAdded a new helper function to Find-Chocolatey rather then relying on Get-Command
Removed all references to Invoke-Expression and replaced with Invoke-Command
The Linux and macOS test cases had some issues with lack of TestDrive and Join-Path
Corrected issue with blank paths on the test cases for linux
…parity

setting up parity with other providers
adjusted multiple test cases for chocolatey
refactored code chocolatey code to be more efficient with less duplication
added a helper function to find the choco binary rather then relying on just Get-Command or hard coding 'choco.exe' for those times when its not in the path
feat/self updater - Allows for easy upgrade to newer versions of devsetup.
Copy link

@github-advanced-security github-advanced-security bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PSScriptAnalyzer found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.

@github-actions
Copy link

Pester test (On macOS) Results

1 634 tests   1 633 ✅  54s ⏱️
1 085 suites      1 💤
    1 files        0 ❌

Results for commit 3dc1668.

@github-actions
Copy link

github-actions bot commented Sep 15, 2025

Summary - Pester Test Coverage Report

Summary
Generated on: 09/15/2025 - 05:41:25
Coverage date: 09/15/2025 - 05:39:54
Parser: JaCoCo
Assemblies: 14
Classes: 115
Files: 115
Line coverage: 99.2% (3487 of 3513)
Covered lines: 3487
Uncovered lines: 26
Coverable lines: 3513
Total lines: 10285
Covered branches: 0
Total branches: 0
Method coverage: Feature is only available for sponsors
Tag: 38_17723244033

Coverage

DevSetup - 0%
Name Line Branch
DevSetup 0% ****
DevSetup/DevSetup 0%
DevSetup/Private/3rdParty - 100%
Name Line Branch
DevSetup/Private/3rdParty 100% ****
DevSetup/Private/3rdParty/ConvertFrom-3rdPartyInstall 100%
DevSetup/Private/3rdParty/VisualStudio - 100%
Name Line Branch
DevSetup/Private/3rdParty/VisualStudio 100% ****
DevSetup/Private/3rdParty/VisualStudio/Add-VsToPackageManager 100%
DevSetup/Private/3rdParty/VisualStudio/ConvertFrom-VisualStudioInstall 100%
DevSetup/Private/3rdParty/VisualStudio/Invoke-VsConfigExport 100%
DevSetup/Private/3rdParty/VisualStudio/Invoke-VsConfigImport 100%
DevSetup/Private/3rdParty/VisualStudio/Wait-ForVisualStudioConfigFile 100%
DevSetup/Private/3rdParty/VisualStudioCode - 100%
Name Line Branch
DevSetup/Private/3rdParty/VisualStudioCode 100% ****
DevSetup/Private/3rdParty/VisualStudioCode/Add-VsCodeToPackageManager 100%
DevSetup/Private/3rdParty/VisualStudioCode/ConvertFrom-VisualStudioCodeInst
all
100%
DevSetup/Private/3rdParty/VisualStudioCode/Find-VsCode 100%
DevSetup/Private/3rdParty/VisualStudioCode/Invoke-VsCodeExtensionsExport 100%
DevSetup/Private/3rdParty/VisualStudioCode/Invoke-VsCodeExtensionsImport 100%
DevSetup/Private/Commands - 100%
Name Line Branch
DevSetup/Private/Commands 100% ****
DevSetup/Private/Commands/Export-DevSetupEnv 100%
DevSetup/Private/Commands/Initialize-DevSetup 100%
DevSetup/Private/Commands/Install-DevSetupEnv 100%
DevSetup/Private/Commands/Show-DevSetupEnvList 100%
DevSetup/Private/Commands/Show-ExplainDevSetupEnv 100%
DevSetup/Private/Commands/Uninstall-DevSetupEnv 100%
DevSetup/Private/Commands/Update-DevSetup 100%
DevSetup/Private/Enums - 100%
Name Line Branch
DevSetup/Private/Enums 100% ****
DevSetup/Private/Enums/InstalledState 100%
DevSetup/Private/Providers/Chocolatey - 100%
Name Line Branch
DevSetup/Private/Providers/Chocolatey 100% ****
DevSetup/Private/Providers/Chocolatey/Find-Chocolatey 100%
DevSetup/Private/Providers/Chocolatey/Get-ChocolateyCacheFile 100%
DevSetup/Private/Providers/Chocolatey/Get-ChocolateyPackageDependencyMap 100%
DevSetup/Private/Providers/Chocolatey/Get-ChocolateyVersion 100%
DevSetup/Private/Providers/Chocolatey/Install-Chocolatey 100%
DevSetup/Private/Providers/Chocolatey/Install-ChocolateyPackage 100%
DevSetup/Private/Providers/Chocolatey/Invoke-ChocolateyPackageExport 100%
DevSetup/Private/Providers/Chocolatey/Invoke-ChocolateyPackageInstall 100%
DevSetup/Private/Providers/Chocolatey/Invoke-ChocolateyPackageUninstall 100%
DevSetup/Private/Providers/Chocolatey/Read-ChocolateyCache 100%
DevSetup/Private/Providers/Chocolatey/Test-ChocolateyInstalled 100%
DevSetup/Private/Providers/Chocolatey/Test-ChocolateyPackageInstalled 100%
DevSetup/Private/Providers/Chocolatey/Uninstall-ChocolateyPackage 100%
DevSetup/Private/Providers/Chocolatey/Write-ChocolateyCache 100%
DevSetup/Private/Providers/Core - 100%
Name Line Branch
DevSetup/Private/Providers/Core 100% ****
DevSetup/Private/Providers/Core/Install-CoreDependencies 100%
DevSetup/Private/Providers/Core/Install-GitRepository 100%
DevSetup/Private/Providers/Core/Install-Nuget 100%
DevSetup/Private/Providers/Homebrew - 100%
Name Line Branch
DevSetup/Private/Providers/Homebrew 100% ****
DevSetup/Private/Providers/Homebrew/Find-Homebrew 100%
DevSetup/Private/Providers/Homebrew/Get-HomebrewCacheFile 100%
DevSetup/Private/Providers/Homebrew/Get-HomebrewVersion 100%
DevSetup/Private/Providers/Homebrew/Install-Homebrew 100%
DevSetup/Private/Providers/Homebrew/Install-HomebrewPackage 100%
DevSetup/Private/Providers/Homebrew/Invoke-HomebrewComponentsExport 100%
DevSetup/Private/Providers/Homebrew/Invoke-HomebrewComponentsInstall 100%
DevSetup/Private/Providers/Homebrew/Invoke-HomebrewComponentsUninstall 100%
DevSetup/Private/Providers/Homebrew/Read-HomebrewCache 100%
DevSetup/Private/Providers/Homebrew/Test-HomebrewInstalled 100%
DevSetup/Private/Providers/Homebrew/Test-HomebrewPackageInstalled 100%
DevSetup/Private/Providers/Homebrew/Uninstall-HomebrewPackage 100%
DevSetup/Private/Providers/Homebrew/Write-HomebrewCache 100%
DevSetup/Private/Providers/Powershell - 100%
Name Line Branch
DevSetup/Private/Providers/Powershell 100% ****
DevSetup/Private/Providers/Powershell/Get-PowershellModuleScopeMap 100%
DevSetup/Private/Providers/Powershell/Install-PowershellModule 100%
DevSetup/Private/Providers/Powershell/Invoke-PowershellModulesExport 100%
DevSetup/Private/Providers/Powershell/Invoke-PowershellModulesInstall 100%
DevSetup/Private/Providers/Powershell/Invoke-PowershellModulesUninstall 100%
DevSetup/Private/Providers/Powershell/Test-PowershellModuleInstalled 100%
DevSetup/Private/Providers/Powershell/Uninstall-PowershellModule 100%
DevSetup/Private/Providers/Scoop - 100%
Name Line Branch
DevSetup/Private/Providers/Scoop 100% ****
DevSetup/Private/Providers/Scoop/Find-Scoop 100%
DevSetup/Private/Providers/Scoop/Get-ScoopCacheFile 100%
DevSetup/Private/Providers/Scoop/Get-ScoopComponentsInstalled 100%
DevSetup/Private/Providers/Scoop/Get-ScoopPackagesAvailable 100%
DevSetup/Private/Providers/Scoop/Get-ScoopVersion 100%
DevSetup/Private/Providers/Scoop/Install-Scoop 100%
DevSetup/Private/Providers/Scoop/Install-ScoopBucket 100%
DevSetup/Private/Providers/Scoop/Install-ScoopPackage 100%
DevSetup/Private/Providers/Scoop/Invoke-ScoopComponentExport 100%
DevSetup/Private/Providers/Scoop/Invoke-ScoopComponentInstall 100%
DevSetup/Private/Providers/Scoop/Invoke-ScoopComponentUninstall 100%
DevSetup/Private/Providers/Scoop/Read-ScoopCache 100%
DevSetup/Private/Providers/Scoop/Test-ScoopComponentInstalled 100%
DevSetup/Private/Providers/Scoop/Test-ScoopInstalled 100%
DevSetup/Private/Providers/Scoop/Uninstall-ScoopBucket 100%
DevSetup/Private/Providers/Scoop/Uninstall-ScoopPackage 100%
DevSetup/Private/Providers/Scoop/Write-ScoopCache 100%
DevSetup/Private/Updater - 100%
Name Line Branch
DevSetup/Private/Updater 100% ****
DevSetup/Private/Updater/Expand-DevSetupUpdateArchive 100%
DevSetup/Private/Updater/Get-DevSetupModuleInstallPath 100%
DevSetup/Private/Updater/Get-DevSetupUpdateUri 100%
DevSetup/Private/Updater/Get-DownloadedDevSetupManifest 100%
DevSetup/Private/Updater/Install-DevSetupModule 100%
DevSetup/Private/Updater/Install-RequiredDevSetupModules 100%
DevSetup/Private/Updater/Invoke-DevSetupDownloadUpdate 100%
DevSetup/Private/Updater/Start-DevSetupSelfUpdate 100%
DevSetup/Private/Updater/Uninstall-DevSetupModule 100%
DevSetup/Private/Utils - 100%
Name Line Branch
DevSetup/Private/Utils 100% ****
DevSetup/Private/Utils/Assert-DevSetupEnvValid 100%
DevSetup/Private/Utils/ConvertFrom-Base64 100%
DevSetup/Private/Utils/ConvertTo-Base64 100%
DevSetup/Private/Utils/Format-CenterText 100%
DevSetup/Private/Utils/Format-LeftText 100%
DevSetup/Private/Utils/Format-PrettyTable 100%
DevSetup/Private/Utils/Format-RightText 100%
DevSetup/Private/Utils/Get-DevSetupCachePath 100%
DevSetup/Private/Utils/Get-DevSetupCommunityEnvPath 100%
DevSetup/Private/Utils/Get-DevSetupEnvPath 100%
DevSetup/Private/Utils/Get-DevSetupLocalEnvPath 100%
DevSetup/Private/Utils/Get-DevSetupLogPath 100%
DevSetup/Private/Utils/Get-DevSetupManifest 100%
DevSetup/Private/Utils/Get-DevSetupPath 100%
DevSetup/Private/Utils/Get-DevSetupVersion 100%
DevSetup/Private/Utils/Get-EnvironmentVariable 100%
DevSetup/Private/Utils/Get-HostArchitecture 100%
DevSetup/Private/Utils/Get-HostOperatingSystem 100%
DevSetup/Private/Utils/Get-HostOperatingSystemVersion 100%
DevSetup/Private/Utils/Get-PwshVersion 100%
DevSetup/Private/Utils/Initialize-DevSetupEnvs 100%
DevSetup/Private/Utils/Invoke-ExternalCommand 100%
DevSetup/Private/Utils/New-DevSetupEnvFile 100%
DevSetup/Private/Utils/Optimize-DevSetupEnvs 100%
DevSetup/Private/Utils/Read-DevSetupEnvFile 100%
DevSetup/Private/Utils/Test-HasSudoAccess 100%
DevSetup/Private/Utils/Test-OperatingSystem 100%
DevSetup/Private/Utils/Test-RunningAsAdmin 100%
DevSetup/Private/Utils/Update-DevSetupEnvFile 100%
DevSetup/Private/Utils/Write-NewConfig 100%
DevSetup/Private/Utils/Write-StatusMessage 100%
DevSetup/Public - 100%
Name Line Branch
DevSetup/Public 100% ****
DevSetup/Public/Use-DevSetup 100%

@kormic911 kormic911 linked an issue Sep 15, 2025 that may be closed by this pull request
@kormic911 kormic911 self-assigned this Sep 15, 2025
@github-actions
Copy link

Pester test (On Windows) Results

1 634 tests   1 633 ✅  54s ⏱️
1 085 suites      1 💤
    1 files        0 ❌

Results for commit 3dc1668.

@kormic911 kormic911 added this to the 1.0.10 milestone Sep 15, 2025
@kormic911 kormic911 merged commit f694118 into main Sep 15, 2025
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Give a description of a particular environment via list

2 participants