mirror of
https://github.com/cookiengineer/audacity
synced 2025-10-20 09:31:15 +02:00
Modify Nuget Cache to Github Packages
Modify `cmake_build.yml` to populate Github Packages Nuget cache via CI builds Modify `CMakeLists.txt` to read from Github Packages Nuget cache during builds Add `nuget.config` to enable nuget cache for contributors without configuration Signed-off-by: Emily Mabrey <emabrey@tenacityaudio.org>
This commit is contained in:
23
.github/workflows/cmake_build.yml
vendored
23
.github/workflows/cmake_build.yml
vendored
@@ -87,12 +87,7 @@ jobs:
|
||||
# vcpkg settings
|
||||
VCPKG_DISABLE_METRICS: true
|
||||
VCPKG_DEFAULT_TRIPLET: ${{ matrix.config.vcpkg_triplet }}
|
||||
VCPKG_BINARY_SOURCES: "clear;default,readwrite;nuget,https://tenacityteam.jfrog.io/artifactory/api/nuget/tenacity-nuget,readwrite"
|
||||
|
||||
# Artifactory cache settings
|
||||
JFROG_ARTIFACTORY_NUGET_USER: ${{secrets.JFROG_ARTIFACTORY_NUGET_USER}}
|
||||
JFROG_ARTIFACTORY_NUGET_PASS: ${{secrets.JFROG_ARTIFACTORY_NUGET_PASS}}
|
||||
JFROG_ARTIFACTORY_NUGET_TOKEN: ${{secrets.JFROG_ARTIFACTORY_NUGET_TOKEN}}
|
||||
NUGET_PACKAGES: ${{ github.workspace }}/vcpkg/packages/
|
||||
|
||||
# Apple codesigning
|
||||
APPLE_CODESIGN_IDENTITY: ${{ secrets.APPLE_CODESIGN_IDENTITY }}
|
||||
@@ -166,11 +161,17 @@ jobs:
|
||||
with:
|
||||
nuget-version: 5.10.0
|
||||
|
||||
- name: "[On Push] Authenticate CI to Artifactory"
|
||||
if: github.event_name == 'push' && github.repository_owner == 'tenacityteam'
|
||||
- name: "Authenticate CI to Github Packages"
|
||||
if: github.repository_owner == 'tenacityteam'
|
||||
run: |
|
||||
nuget sources Add -Name Artifactory -Source https://tenacityteam.jfrog.io/artifactory/api/nuget/tenacity-nuget -username ${JFROG_ARTIFACTORY_NUGET_USER} -password ${JFROG_ARTIFACTORY_NUGET_PASS} -ForceEnglishOutput -NonInteractive
|
||||
nuget setapikey ${JFROG_ARTIFACTORY_NUGET_USER}:${JFROG_ARTIFACTORY_NUGET_TOKEN} -Source Artifactory -ForceEnglishOutput -NonInteractive
|
||||
rm ./nuget.config
|
||||
nuget sources add -Name tenacityteam_github_auto -Source https://nuget.pkg.github.com/tenacityteam/index.json -Username tenacityteam -Password ${{ secrets.GITHUB_TOKEN }} -StorePasswordInClearText -ForceEnglishOutput -NonInteractive
|
||||
nuget setapikey ${{ secrets.GITHUB_TOKEN }} -Source tenacityteam_github_auto -ForceEnglishOutput -NonInteractive
|
||||
if [[ ${{ github.event_name }} == 'push' ]]; then
|
||||
echo "VCPKG_BINARY_SOURCES=clear;nuget,tenacityteam_github_auto,readwrite;" >> ${GITHUB_ENV}
|
||||
else
|
||||
echo "VCPKG_BINARY_SOURCES=clear;nuget,tenacityteam_github_auto,read;" >> ${GITHUB_ENV}
|
||||
fi
|
||||
|
||||
- name: "[Linux] Install dependencies"
|
||||
if: runner.os == 'Linux'
|
||||
@@ -192,6 +193,7 @@ jobs:
|
||||
libgtk-3-dev
|
||||
libsuil-dev
|
||||
gettext
|
||||
|
||||
- name: "[MacOS] Install dependencies"
|
||||
if: runner.os == 'macOS'
|
||||
run: >-
|
||||
@@ -200,6 +202,7 @@ jobs:
|
||||
ccache
|
||||
ninja
|
||||
nasm
|
||||
|
||||
- name: "[Windows] Install dependencies"
|
||||
if: runner.os == 'Windows'
|
||||
shell: pwsh
|
||||
|
Reference in New Issue
Block a user