Skip to content

Commit affde54

Browse files
committed
Fix issue with ExportUnityPackage GUID regex
1 parent afb9ea3 commit affde54

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Scripts/ExportUnityPackage.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ function global:Export-UnityPackage
109109
$MetaFilePath = "$FilePath.meta"
110110
if (-not (Test-Path $MetaFilePath -PathType Leaf)) { Write-Error "Meta file not found: $MetaFilePath"; $AnyErrors = $true; return }
111111

112-
$MatchSuccess = $(Get-Content $MetaFilePath -Raw) -match 'guid:\s*([0-9A-Fa-f]{32})\s'
112+
$MatchSuccess = $(Get-Content $MetaFilePath -Raw) -match 'guid:\s*([0-9A-Fa-f]{32})(?:\s|$)'
113113
if (-not $MatchSuccess) { Write-Error "Meta file does not contain GUID or GUID is malformed: $MetaFilePath"; $AnyErrors = $true; return}
114114
$guid = $Matches[1]
115115
New-Item -Path "$tmpdir/$guid" -ItemType Directory -Force | Out-Null

0 commit comments

Comments
 (0)