Skip to content

Commit

Permalink
Use nuget from vcpkg
Browse files Browse the repository at this point in the history
  • Loading branch information
daschuer committed Nov 13, 2023
1 parent 4893f32 commit c39c103
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ jobs:
- os: windows-2019
vcpkg_path: C:\mixxx-vcpkg
exe_suffix: .exe
nuget: $(vcpkg fetch nuget | tail -n 1)
vcpkg_bootstrap: .\bootstrap-vcpkg.bat
vcpkg_triplet: x64-windows
vcpkg_host_triplet: x64-windows
Expand All @@ -23,6 +24,7 @@ jobs:
check_disk_space: Get-PSDrive
- os: macos-11
vcpkg_path: /Users/runner/mixxx-vcpkg
nuget: nuget
vcpkg_bootstrap: ./bootstrap-vcpkg.sh
vcpkg_triplet: x64-osx-min1015
vcpkg_host_triplet: x64-osx-min1015
Expand Down Expand Up @@ -62,16 +64,18 @@ jobs:
if: runner.os != 'Linux' && github.event_name == 'push'
shell: bash
run: |
nuget sources add -Name "mixxx-github-packages" -Source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json" -UserName "${{ github.repository_owner }}" -Password "${{ secrets.GITHUB_TOKEN }}" -StorePasswordInClearText
nuget setapikey "${{ secrets.GITHUB_TOKEN }}" -Source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json"
nuget="${{ matrix.nuget }}"
"${nuget}" sources add -Name "mixxx-github-packages" -Source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json" -UserName "${{ github.repository_owner }}" -Password "${{ secrets.GITHUB_TOKEN }}" -StorePasswordInClearText
"${nuget}" setapikey "${{ secrets.GITHUB_TOKEN }}" -Source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json"
echo "VCPKG_BINARY_SOURCES=clear;nuget,mixxx-github-packages,readwrite;" >> "${GITHUB_ENV}"
- name: "Authenticate to GitHub Packages (read only)"
if: runner.os != 'Linux' && github.event_name == 'pull_request'
shell: bash
run: |
nuget sources add -Name "mixxx-github-packages" -Source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json" -UserName "${{ github.repository_owner }}" -Password "${{ secrets.GITHUB_TOKEN }}" -StorePasswordInClearText
nuget setapikey "${{ secrets.GITHUB_TOKEN }}" -Source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json"
nuget="${{ matrix.nuget }}"
"${nuget}" sources add -Name "mixxx-github-packages" -Source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json" -UserName "${{ github.repository_owner }}" -Password "${{ secrets.GITHUB_TOKEN }}" -StorePasswordInClearText
"${nuget}" setapikey "${{ secrets.GITHUB_TOKEN }}" -Source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json"
echo "VCPKG_BINARY_SOURCES=clear;nuget,mixxx-github-packages,read;" >> "${GITHUB_ENV}"
- name: Read sha_short
Expand Down Expand Up @@ -105,7 +109,7 @@ jobs:
run: ${{ matrix.check_disk_space }}

- name: Build packages
run: ./vcpkg install --vcpkg-root=${{ matrix.vcpkg_path }} --clean-after-build --recurse --feature-flags="-compilertracking,manifests,registries,versions" --x-abi-tools-use-exact-versions
run: ./vcpkg install --vcpkg-root=${{ matrix.vcpkg_path }} --clean-after-build --recurse --feature-flags="-compilertracking,manifests,registries,versions" --x-abi-tools-use-exact-versions --debug
working-directory: ${{ matrix.vcpkg_path }}

- name: Upload GitHub Actions artifacts of build logs
Expand Down

0 comments on commit c39c103

Please sign in to comment.