Skip to content

Commit fa69a03

Browse files
committed
handle resource folder
1 parent bffb4f2 commit fa69a03

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

project.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"ProjectName": "ModuleTools",
33
"Description": "ModuleTools is a versatile, standalone PowerShell module builder. Create anything from simple to robust modules with ease. Built for CICD and Automation.",
4-
"Version": "1.2.4-preview",
4+
"Version": "1.2.5-preview",
55
"copyResourcesToModuleRoot": false,
66
"Manifest": {
77
"Author": "Manjunath Beli",

src/private/Build.Manifest.ps1

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,11 @@ function Build-Manifest {
1515
## Import Formatting (if any)
1616
$FormatsToProcess = @()
1717
Get-ChildItem -Path $data.ResourcesDir -File -Filter '*.ps1xml' -ErrorAction SilentlyContinue | ForEach-Object {
18-
$FormatsToProcess += $_.Name
18+
if ($data.copyResourcesToModuleRoot) {
19+
$FormatsToProcess += $_.Name
20+
} else {
21+
$FormatsToProcess += Join-Path -Path 'resources' -ChildPath $_.Name
22+
}
1923
}
2024

2125
$ManfiestAllowedParams = (Get-Command New-ModuleManifest).Parameters.Keys

0 commit comments

Comments
 (0)