Skip to content

Commit 6a499e5

Browse files
author
Friedrich Weinmann
committed
fixed indents
1 parent a0e03e4 commit 6a499e5

File tree

1 file changed

+24
-24
lines changed

1 file changed

+24
-24
lines changed

PSModuleDevelopment/functions/utility/New-PSMDModuleNugetPackage.ps1

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -2,29 +2,29 @@
22
{
33
<#
44
.SYNOPSIS
5-
Creates a nuget package from a PowerShell module.
5+
Creates a nuget package from a PowerShell module.
66
77
.DESCRIPTION
88
This function will take a module and wrap it into a nuget package.
99
This is accomplished by creating a temporary local filesystem repository and using the PowerShellGet module to do the actual writing.
10-
10+
1111
Note:
1212
- Requires PowerShellGet module
1313
- Dependencies must be built first to the same folder
14-
14+
1515
.PARAMETER ModulePath
16-
Path to the PowerShell module you are creating a Nuget package from
16+
Path to the PowerShell module you are creating a Nuget package from
1717
1818
.PARAMETER PackagePath
19-
Path where the package file will be copied.
19+
Path where the package file will be copied.
2020
2121
.PARAMETER EnableException
22-
Replaces user friendly yellow warnings with bloody red exceptions of doom!
23-
Use this if you want the function to throw terminating errors you want to catch.
24-
25-
.EXAMPLE
26-
New-PSMDModuleNugetPackage -PackagePath 'c:\temp\package' -ModulePath .\DBOps
22+
Replaces user friendly yellow warnings with bloody red exceptions of doom!
23+
Use this if you want the function to throw terminating errors you want to catch.
2724
25+
.EXAMPLE
26+
New-PSMDModuleNugetPackage -PackagePath 'c:\temp\package' -ModulePath .\DBOps
27+
2828
Packages the module stored in .\DBOps and stores the nuget file in 'c:\temp\package'
2929
3030
.NOTES
@@ -60,12 +60,12 @@
6060
catch
6161
{
6262
$paramStopPSFFunction = @{
63-
Message = "Failed to detect the PowerShellGet module! The module is required in order to execute this function."
64-
EnableException = $EnableException
65-
Category = 'NotInstalled'
66-
ErrorRecord = $_
67-
OverrideExceptionMessage = $true
68-
Tag = 'fail', 'validation', 'prerequisites', 'module'
63+
Message = "Failed to detect the PowerShellGet module! The module is required in order to execute this function."
64+
EnableException = $EnableException
65+
Category = 'NotInstalled'
66+
ErrorRecord = $_
67+
OverrideExceptionMessage = $true
68+
Tag = 'fail', 'validation', 'prerequisites', 'module'
6969
}
7070
Stop-PSFFunction @paramStopPSFFunction
7171
return
@@ -87,11 +87,11 @@
8787
try
8888
{
8989
$paramRegisterPSRepository = @{
90-
Name = 'PSModuleDevelopment_TempLocalRepository'
91-
PublishLocation = $PackagePath
92-
SourceLocation = $PackagePath
93-
InstallationPolicy = 'Trusted'
94-
ErrorAction = 'Stop'
90+
Name = 'PSModuleDevelopment_TempLocalRepository'
91+
PublishLocation = $PackagePath
92+
SourceLocation = $PackagePath
93+
InstallationPolicy = 'Trusted'
94+
ErrorAction = 'Stop'
9595
}
9696

9797
Register-PSRepository @paramRegisterPSRepository
@@ -109,11 +109,11 @@
109109
#region Process Paths
110110
foreach ($Path in $ModulePath)
111111
{
112-
Write-PSFMessage -Level VeryVerbose -Message "Starting to package: $Path" -Tag 'progress','developer' -Target $Path
112+
Write-PSFMessage -Level VeryVerbose -Message "Starting to package: $Path" -Tag 'progress', 'developer' -Target $Path
113113

114114
if (-not (Test-Path $Path))
115115
{
116-
Stop-PSFFunction -Message "Path not found: $Path" -EnableException $EnableException -Category InvalidArgument -Tag 'progress','developer','fail' -Target $Path -Continue
116+
Stop-PSFFunction -Message "Path not found: $Path" -EnableException $EnableException -Category InvalidArgument -Tag 'progress', 'developer', 'fail' -Target $Path -Continue
117117
}
118118

119119
try { Publish-Module -Path $Path -Repository 'PSModuleDevelopment_TempLocalRepository' -ErrorAction Stop -Force }
@@ -122,7 +122,7 @@
122122
Stop-PSFFunction -Message "Failed to publish module: $Path" -EnableException $EnableException -ErrorRecord $_ -Tag 'progress', 'developer', 'fail' -Target $Path -Continue
123123
}
124124

125-
Write-PSFMessage -Level Verbose -Message "Finished processing: $Path" -Tag 'progress','developer' -Target $Path
125+
Write-PSFMessage -Level Verbose -Message "Finished processing: $Path" -Tag 'progress', 'developer' -Target $Path
126126
}
127127
#endregion Process Paths
128128
}

0 commit comments

Comments
 (0)