File tree Expand file tree Collapse file tree 1 file changed +10
-16
lines changed
Expand file tree Collapse file tree 1 file changed +10
-16
lines changed Original file line number Diff line number Diff line change @@ -76,22 +76,16 @@ jobs:
7676 if : runner.os == 'Windows'
7777 shell : pwsh
7878 run : |
79- $filePath = "pyproject.toml"
80- $newContent = 'cmake.args = [
81- "-DPYTHON_BUILD_SETUP=ON",
82- "-DHIPO=ON",
83- "-DBUILD_OPENBLAS=ON"
84- ]'
85-
86- # Read file, replace the block, and write back
87- $fileContent = Get-Content $filePath -Raw
88- $regex = "(?s)cmake\.args = \[\s*?\"-DPYTHON_BUILD_SETUP=ON\".*?\]"
89- $updatedContent = $fileContent -replace $regex, $newContent
90-
91- $updatedContent | Set-Content $filePath
92-
93- echo "--- pyproject.toml content after Windows edit ---"
94- Get-Content $filePath
79+ $content = Get-Content pyproject.toml -Raw
80+ $newContent = $content -replace 'cmake\.args = \[\s*"-DPYTHON_BUILD_SETUP=ON"\s*\]', @"
81+ cmake.args = [
82+ "-DPYTHON_BUILD_SETUP=ON",
83+ "-DHIPO=ON",
84+ "-DBUILD_OPENBLAS=ON"
85+ ]
86+ "@
87+ $newContent | Set-Content pyproject.toml
88+ cat pyproject.toml
9589
9690 - name : Build wheels
9791
You can’t perform that action at this time.
0 commit comments