Skip to content

Commit

Permalink
🩹 [Patch]: Swap out Utilities with Hashtable (#109)
Browse files Browse the repository at this point in the history
## Description

This pull request includes changes a dependency in
`Build-PSModuleRootModule.ps1` to use `Hashtable` instead of Utilities`.

Updates to module dependencies:

*
[`scripts/helpers/Build/Build-PSModuleRootModule.ps1`](diffhunk://#diff-1d337ff39f37506a54fda1c5d0487f1b2c2ef318f216a4d9a56c3e7248b69879L2-R2):
Changed the required module from `Utilities` version `0.3.0` to
`Hashtable` version `1.1.1`.

Improvements to export process:

*
[`scripts/helpers/Build/Build-PSModuleRootModule.ps1`](diffhunk://#diff-1d337ff39f37506a54fda1c5d0487f1b2c2ef318f216a4d9a56c3e7248b69879L225-R225):
Replaced the `Convert-HashtableToString` function with the
`Format-Hashtable` function to format hashtable exports.

## Type of change

<!-- Use the check-boxes [x] on the options that are relevant. -->

- [ ] 📖 [Docs]
- [ ] 🪲 [Fix]
- [x] 🩹 [Patch]
- [ ] ⚠️ [Security fix]
- [ ] 🚀 [Feature]
- [ ] 🌟 [Breaking change]

## Checklist

<!-- Use the check-boxes [x] on the options that are relevant. -->

- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
  • Loading branch information
MariusStorhaug authored Feb 20, 2025
1 parent 8819705 commit d454e3a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/helpers/Build/Build-PSModuleRootModule.ps1
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#Requires -Modules @{ ModuleName = 'GitHub'; ModuleVersion = '0.13.2' }
#Requires -Modules @{ ModuleName = 'Utilities'; ModuleVersion = '0.3.0' }
#Requires -Modules @{ ModuleName = 'Hashtable'; ModuleVersion = '1.1.1' }

function Build-PSModuleRootModule {
<#
Expand Down Expand Up @@ -222,7 +222,7 @@ Write-Debug "[`$scriptName] - $relativePath - Done"
#region - Export-ModuleMember
Add-Content -Path $rootModuleFile -Force -Value $classExports

$exportsString = Convert-HashtableToString -Hashtable $exports
$exportsString = $exports | Format-Hashtable

Write-Host ($exportsString | Out-String)

Expand Down

0 comments on commit d454e3a

Please sign in to comment.