mirror of
https://github.com/actions/setup-dotnet.git
synced 2025-08-20 07:35:10 +00:00
Generate and verify nuget.config
This commit is contained in:
parent
164b130537
commit
36048ec573
3
.github/workflows/workflow.yml
vendored
3
.github/workflows/workflow.yml
vendored
@ -42,6 +42,7 @@ jobs:
|
|||||||
uses: ./
|
uses: ./
|
||||||
with:
|
with:
|
||||||
dotnet-version: 3.0.100
|
dotnet-version: 3.0.100
|
||||||
|
source-url: https://api.nuget.org/v3/index.json
|
||||||
- name: Verify dotnet
|
- name: Verify dotnet
|
||||||
if: runner.os != 'windows'
|
if: runner.os != 'windows'
|
||||||
run: __tests__/verify-dotnet.sh 3.0.100
|
run: __tests__/verify-dotnet.sh 3.0.100
|
||||||
@ -70,6 +71,7 @@ jobs:
|
|||||||
uses: ./
|
uses: ./
|
||||||
with:
|
with:
|
||||||
dotnet-version: 3.0.100
|
dotnet-version: 3.0.100
|
||||||
|
source-url: https://api.nuget.org/v3/index.json
|
||||||
- name: Verify dotnet
|
- name: Verify dotnet
|
||||||
run: __tests__/verify-dotnet.sh 3.0.100
|
run: __tests__/verify-dotnet.sh 3.0.100
|
||||||
|
|
||||||
@ -87,5 +89,6 @@ jobs:
|
|||||||
uses: ./
|
uses: ./
|
||||||
with:
|
with:
|
||||||
dotnet-version: 3.0.100
|
dotnet-version: 3.0.100
|
||||||
|
source-url: https://api.nuget.org/v3/index.json
|
||||||
- name: Verify dotnet
|
- name: Verify dotnet
|
||||||
run: __tests__/verify-dotnet.sh 3.0.100
|
run: __tests__/verify-dotnet.sh 3.0.100
|
||||||
|
@ -3,6 +3,11 @@ if (!$args[0])
|
|||||||
throw "Must supply dotnet version argument"
|
throw "Must supply dotnet version argument"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!Test-Path "../nuget.config")
|
||||||
|
{
|
||||||
|
throw "nuget file not generated correctly"
|
||||||
|
}
|
||||||
|
|
||||||
$dotnet = Get-Command dotnet | Select-Object -First 1 | ForEach-Object { $_.Path }
|
$dotnet = Get-Command dotnet | Select-Object -First 1 | ForEach-Object { $_.Path }
|
||||||
Write-Host "Found '$dotnet'"
|
Write-Host "Found '$dotnet'"
|
||||||
|
|
||||||
|
@ -3,6 +3,11 @@ if [ -z "$1" ]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ ! -f "../nuget.config" ] then
|
||||||
|
echo "nuget file not generated correctly"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
dotnet_version="$(dotnet --version)"
|
dotnet_version="$(dotnet --version)"
|
||||||
echo "Found dotnet version '$dotnet_version'"
|
echo "Found dotnet version '$dotnet_version'"
|
||||||
if [ -z "$(echo $dotnet_version | grep $1)" ]; then
|
if [ -z "$(echo $dotnet_version | grep $1)" ]; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user