fix: remove regex search from Select-String
This commit is contained in:
@@ -103,7 +103,7 @@ ${templatefile("${path.module}/devolutions-patch.js", {
|
|||||||
'@ | Set-Content "$root\coder.js"
|
'@ | Set-Content "$root\coder.js"
|
||||||
|
|
||||||
# Only inject the src if we have not before.
|
# Only inject the src if we have not before.
|
||||||
$isPatched = Select-String -Path "$devolutionsHtml" -Pattern "$patch"
|
$isPatched = Select-String -Path "$devolutionsHtml" -Pattern "$patch" -SimpleMatch
|
||||||
if ($isPatched -eq $null) {
|
if ($isPatched -eq $null) {
|
||||||
(Get-Content $devolutionsHtml).Replace('</app-root>', "</app-root>$patch") | Set-Content $devolutionsHtml
|
(Get-Content $devolutionsHtml).Replace('</app-root>', "</app-root>$patch") | Set-Content $devolutionsHtml
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user