$FilePath = 'Z:\next\ResourcesConfiguration.config'
$oldString = 'Z:\next\Core\Resources\'
$NewString = 'G:\PublishDir\next\Core\Resources\'
どんなアイデアでも、サインインしている文字列をどのように置き換えることができますか。設定ファイルのパスを変更したい。単純なコードはこれには機能しません。フォローしてみました
(Get-Content $original_file) | Foreach-Object {
$_ -replace $oldString, $NewString
} | Set-Content $destination_file