Skip to content
This repository has been archived by the owner on Feb 19, 2019. It is now read-only.

Dynamically export module members #278

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 3 additions & 26 deletions src/helpers/chocolateyInstaller.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,7 @@
$DebugPreference = "SilentlyContinue"
if ($env:ChocolateyEnvironmentDebug -eq 'true') {$DebugPreference = "Continue";}


# grab functions from files
Resolve-Path $helpersPath\functions\*.ps1 |
? { -not ($_.ProviderPath.Contains(".Tests.")) } |
% { . $_.ProviderPath }

Export-ModuleMember -Function `
Get-ChocolateyWebFile,`
Get-ChocolateyUnzip,`
Get-ProcessorBits,`
Install-ChocolateyInstallPackage,`
Install-ChocolateyPackage,`
Install-ChocolateyZipPackage,`
Install-ChocolateyPowershellCommand,`
Install-ChocolateyPath,`
Install-ChocolateyDesktopLink,`
Install-ChocolateyPinnedTaskBarItem,`
Install-ChocolateyExplorerMenuItem,`
Install-ChocolateyFileAssociation,`
Install-ChocolateyEnvironmentVariable,`
Install-ChocolateyVsixPackage,`
Write-ChocolateySuccess,`
Write-ChocolateyFailure,`
Write-Host,`Write-Debug,`Write-Error,`
Start-ChocolateyProcessAsAdmin,`
Uninstall-ChocolateyPackage,`
Update-SessionEnvironment
Get-Item $helpersPath\functions\*.ps1 |
? { -not ($_.Name.Contains(".Tests.")) } |
% { . $_.FullName; if ( -not ($_.Name.Contains(".Internal."))) { Export-ModuleMember -Function $_.BaseName } }