Skip to content

Commit

Permalink
Create direactories (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
mwestphal authored Apr 24, 2024
1 parent 1824e37 commit fd2fbbb
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ will then just work out of the box.

Note that this action will define `GALLIUM_DRIVER` environnement variable that is needed for mesa to work as expected.

The path can contain wildcards, which means the mesa files can be copied to multiple directories in a single action use.
If the directories do not exists, they will be created.

## Defining mesa version

Which mesa version to use can be set like this:
Expand Down
2 changes: 2 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ runs:
cd install_mesa_local_dir
curl.exe -L --output install_mesa_local_archive.7z --url https://github.com/pal1000/mesa-dist-win/releases/download/${{inputs.version}}/mesa3d-${{inputs.version}}-release-msvc.7z
C:\'Program Files'\7-Zip\7z.exe x install_mesa_local_archive.7z
# Create the directories if they do not exist
Get-ChildItem -Directory ${{inputs.path}}* | ForEach-Object { New-Item -ItemType Directory -Force -Path $_ }
# A * is added next line to force Get-ChildItem to look for directory within the path
Get-ChildItem -Directory ${{inputs.path}}* | ForEach-Object { Copy-Item -Path .\x64\opengl32.dll, .\x64\libglapi.dll, .\x64\libgallium_wgl.dll -Destination $_ }
echo "GALLIUM_DRIVER=llvmpipe"| Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
Expand Down

0 comments on commit fd2fbbb

Please sign in to comment.