You've already forked setup-dotnet
							
							
				mirror of
				https://github.com/actions/setup-dotnet.git
				synced 2025-11-04 08:56:35 +07:00 
			
		
		
		
	Compare commits
	
		
			84 Commits
		
	
	
		
			v1.7.0
			...
			v-malob/up
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 4f71fcfa81 | |||
| 6803d4b94d | |||
| 3c80e97cbd | |||
| 8d30c127da | |||
| 2d101adc9f | |||
| c8b60fb6bf | |||
| bea420f2fd | |||
| 3a3dbe976e | |||
| ce38f90a9a | |||
| c32ed2108b | |||
| d99c06115d | |||
| f311b6d978 | |||
| 9427b17c42 | |||
| f39691d155 | |||
| 19e6ad3fe0 | |||
| efeb86e5ce | |||
| 8e5c71c8f8 | |||
| c0d7255256 | |||
| c1ca14bb7b | |||
| e1655545c1 | |||
| 2a58294d0c | |||
| 92ffa484b1 | |||
| 3698118d95 | |||
| cfb7e25be1 | |||
| 5865234247 | |||
| 0cb99b2a12 | |||
| 4a01d86a5b | |||
| 1c7be1087d | |||
| ac1baccba4 | |||
| 92451e3d46 | |||
| a841c568fd | |||
| 5d1a72cb19 | |||
| 8889c6748f | |||
| f4159a6d20 | |||
| 7164f75e01 | |||
| 44b8627225 | |||
| 054db1cac2 | |||
| 1317beb53a | |||
| fabe7d52fe | |||
| 993f819e3d | |||
| 831e0d4070 | |||
| bb2233aaa5 | |||
| 24ed2d0102 | |||
| 059f1aa99b | |||
| 5c5ac76dc6 | |||
| a0f70ab98c | |||
| 5dcd27b0bc | |||
| 79735df611 | |||
| a1105722ad | |||
| 131ac602dc | |||
| c8cb48ba8b | |||
| 7bbfec324f | |||
| 6b7d951977 | |||
| c7eaa2ec00 | |||
| 8807004b20 | |||
| 2d640ec739 | |||
| 53b5bae1f6 | |||
| 45c0959fcd | |||
| d33a835564 | |||
| 347456b934 | |||
| 76a91b1af8 | |||
| 9d49fb8e98 | |||
| 10ad86dc12 | |||
| 71f0d4bd07 | |||
| 7669e56997 | |||
| c8cf369c29 | |||
| 6ade6c061b | |||
| 843b5197ce | |||
| a3d47e556c | |||
| 7261940ea5 | |||
| 8ada5b5558 | |||
| 62230c5409 | |||
| 51b6fb2610 | |||
| c47b497cff | |||
| 975b958e4c | |||
| 13bccd131e | |||
| daad66578a | |||
| 29c0c6cee8 | |||
| 5551aab1c3 | |||
| 9a46dbb681 | |||
| 8336fd394b | |||
| 51f68377c1 | |||
| 7a98346f51 | |||
| 8aad93f856 | 
							
								
								
									
										1
									
								
								.github/CODEOWNERS
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								.github/CODEOWNERS
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@ -0,0 +1 @@
 | 
				
			|||||||
 | 
					* @actions/virtual-environments-owners
 | 
				
			||||||
							
								
								
									
										33
									
								
								.github/ISSUE_TEMPLATE/bug_report.md
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										33
									
								
								.github/ISSUE_TEMPLATE/bug_report.md
									
									
									
									
										vendored
									
									
								
							@ -2,22 +2,31 @@
 | 
				
			|||||||
name: Bug report
 | 
					name: Bug report
 | 
				
			||||||
about: Create a bug report
 | 
					about: Create a bug report
 | 
				
			||||||
title: ''
 | 
					title: ''
 | 
				
			||||||
labels: ''
 | 
					labels: bug, needs triage
 | 
				
			||||||
assignees: ''
 | 
					assignees: ''
 | 
				
			||||||
 | 
					
 | 
				
			||||||
---
 | 
					---
 | 
				
			||||||
 | 
					
 | 
				
			||||||
### Description
 | 
					**Description:**
 | 
				
			||||||
 | 
					A clear and concise description of what the bug is.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<!--
 | 
					**Task version:**
 | 
				
			||||||
* Please share short description of the problem
 | 
					Specify the task version
 | 
				
			||||||
  -->
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
### Details
 | 
					**Platform:**
 | 
				
			||||||
 | 
					- [ ] Ubuntu
 | 
				
			||||||
 | 
					- [ ] macOS
 | 
				
			||||||
 | 
					- [ ] Windows
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<!--
 | 
					**Runner type:**
 | 
				
			||||||
* Include the relevant yaml, platform, and dotnet versions in use
 | 
					- [ ] Hosted
 | 
				
			||||||
* If an error occurred on a public action, please share a link
 | 
					- [ ] Self-hosted
 | 
				
			||||||
* Include any error messages received in text (search does not work for images)
 | 
					
 | 
				
			||||||
* Was this a regression from previous behavior?
 | 
					**Repro steps:**  
 | 
				
			||||||
  -->
 | 
					A description with steps to reproduce the issue. If your have a public example or repo to share, please provide the link.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					**Expected behavior:**
 | 
				
			||||||
 | 
					A description of what you expected to happen.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					**Actual behavior:**
 | 
				
			||||||
 | 
					A description of what is actually happening.
 | 
				
			||||||
							
								
								
									
										2
									
								
								.github/ISSUE_TEMPLATE/config.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.github/ISSUE_TEMPLATE/config.yml
									
									
									
									
										vendored
									
									
								
							@ -1,4 +1,4 @@
 | 
				
			|||||||
blank_issues_enabled: true
 | 
					blank_issues_enabled: false
 | 
				
			||||||
contact_links:
 | 
					contact_links:
 | 
				
			||||||
  - name: .NET issues
 | 
					  - name: .NET issues
 | 
				
			||||||
    url: https://github.com/dotnet/runtime#filing-issues
 | 
					    url: https://github.com/dotnet/runtime#filing-issues
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										16
									
								
								.github/ISSUE_TEMPLATE/feature_request.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								.github/ISSUE_TEMPLATE/feature_request.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@ -0,0 +1,16 @@
 | 
				
			|||||||
 | 
					---
 | 
				
			||||||
 | 
					name: Feature request
 | 
				
			||||||
 | 
					about: Suggest an idea for this project
 | 
				
			||||||
 | 
					title: ''
 | 
				
			||||||
 | 
					labels: feature request, needs triage
 | 
				
			||||||
 | 
					assignees: ''
 | 
				
			||||||
 | 
					---
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					**Description:**
 | 
				
			||||||
 | 
					Describe your proposal.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					**Justification:**
 | 
				
			||||||
 | 
					Justification or a use case for your proposal.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					**Are you willing to submit a PR?**
 | 
				
			||||||
 | 
					<!--- We accept contributions! -->
 | 
				
			||||||
							
								
								
									
										9
									
								
								.github/pull_request_template.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								.github/pull_request_template.md
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@ -0,0 +1,9 @@
 | 
				
			|||||||
 | 
					**Description:**
 | 
				
			||||||
 | 
					Describe your changes.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					**Related issue:**
 | 
				
			||||||
 | 
					Add link to the related issue.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					**Check list:**
 | 
				
			||||||
 | 
					- [ ] Mark if documentation changes are required.
 | 
				
			||||||
 | 
					- [ ] Mark if tests were added or updated to cover the changes.
 | 
				
			||||||
							
								
								
									
										37
									
								
								.github/workflows/test-dotnet.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										37
									
								
								.github/workflows/test-dotnet.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@ -0,0 +1,37 @@
 | 
				
			|||||||
 | 
					name: Validate dotnet
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					on:
 | 
				
			||||||
 | 
					  pull_request:
 | 
				
			||||||
 | 
					    paths-ignore:
 | 
				
			||||||
 | 
					      - '**.md'
 | 
				
			||||||
 | 
					  push:
 | 
				
			||||||
 | 
					    branches:
 | 
				
			||||||
 | 
					      - main
 | 
				
			||||||
 | 
					      - releases/*
 | 
				
			||||||
 | 
					    paths-ignore:
 | 
				
			||||||
 | 
					      - '**.md'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					jobs:
 | 
				
			||||||
 | 
					  setup-version:
 | 
				
			||||||
 | 
					    runs-on: ${{ matrix.operating-system }}
 | 
				
			||||||
 | 
					    strategy:
 | 
				
			||||||
 | 
					      fail-fast: false
 | 
				
			||||||
 | 
					      matrix:
 | 
				
			||||||
 | 
					        operating-system: [ubuntu-latest, windows-latest, macOS-latest]
 | 
				
			||||||
 | 
					        dotnet-version: ['2.1', '2.2', '3.0', '3.1', '5.0']
 | 
				
			||||||
 | 
					    steps:
 | 
				
			||||||
 | 
					      - name: Checkout
 | 
				
			||||||
 | 
					        uses: actions/checkout@v2
 | 
				
			||||||
 | 
					      - name: Clear toolcache
 | 
				
			||||||
 | 
					        shell: pwsh
 | 
				
			||||||
 | 
					        run: __tests__/clear-toolcache.ps1 ${{ runner.os }}
 | 
				
			||||||
 | 
					      - name: Setup dotnet ${{ matrix.dotnet-version }}
 | 
				
			||||||
 | 
					        uses: ./
 | 
				
			||||||
 | 
					        with:
 | 
				
			||||||
 | 
					          dotnet-version: ${{ matrix.dotnet-version }}
 | 
				
			||||||
 | 
					      - name: Check installed version
 | 
				
			||||||
 | 
					        shell: pwsh
 | 
				
			||||||
 | 
					        run: |
 | 
				
			||||||
 | 
					          $version = & dotnet --version
 | 
				
			||||||
 | 
					          Write-Host "Installed version: $version"
 | 
				
			||||||
 | 
					          if (-not $version.StartsWith("${{ matrix.dotnet-version }}")) { throw "Unexpected version" }
 | 
				
			||||||
							
								
								
									
										112
									
								
								.github/workflows/workflow.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										112
									
								
								.github/workflows/workflow.yml
									
									
									
									
										vendored
									
									
								
							@ -2,10 +2,14 @@ name: Main workflow
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
on:
 | 
					on:
 | 
				
			||||||
  pull_request:
 | 
					  pull_request:
 | 
				
			||||||
 | 
					    paths-ignore:
 | 
				
			||||||
 | 
					      - '**.md'
 | 
				
			||||||
  push:
 | 
					  push:
 | 
				
			||||||
    branches:
 | 
					    branches:
 | 
				
			||||||
      - main
 | 
					      - main
 | 
				
			||||||
      - releases/*
 | 
					      - releases/*
 | 
				
			||||||
 | 
					    paths-ignore:
 | 
				
			||||||
 | 
					      - '**.md'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
jobs:
 | 
					jobs:
 | 
				
			||||||
  build:
 | 
					  build:
 | 
				
			||||||
@ -29,7 +33,7 @@ jobs:
 | 
				
			|||||||
      if: runner.os != 'windows'
 | 
					      if: runner.os != 'windows'
 | 
				
			||||||
      run: __tests__/verify-no-unstaged-changes.sh
 | 
					      run: __tests__/verify-no-unstaged-changes.sh
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  test:
 | 
					  test-setup-full-version:
 | 
				
			||||||
    runs-on: ${{ matrix.operating-system }}
 | 
					    runs-on: ${{ matrix.operating-system }}
 | 
				
			||||||
    strategy:
 | 
					    strategy:
 | 
				
			||||||
      fail-fast: false
 | 
					      fail-fast: false
 | 
				
			||||||
@ -38,25 +42,9 @@ jobs:
 | 
				
			|||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
      - name: Checkout
 | 
					      - name: Checkout
 | 
				
			||||||
        uses: actions/checkout@v2
 | 
					        uses: actions/checkout@v2
 | 
				
			||||||
      - name: Clear tool cache (macOS)
 | 
					      - name: Clear toolcache
 | 
				
			||||||
        if: runner.os == 'macos'
 | 
					        shell: pwsh
 | 
				
			||||||
        run: |
 | 
					        run: __tests__/clear-toolcache.ps1 ${{ runner.os }}
 | 
				
			||||||
          echo $PATH
 | 
					 | 
				
			||||||
          dotnet --info
 | 
					 | 
				
			||||||
          rm -rf "/Users/runner/.dotnet"
 | 
					 | 
				
			||||||
      - name: Clear tool cache (Ubuntu)
 | 
					 | 
				
			||||||
        if: runner.os == 'linux'
 | 
					 | 
				
			||||||
        run: |
 | 
					 | 
				
			||||||
          echo $PATH
 | 
					 | 
				
			||||||
          dotnet --info
 | 
					 | 
				
			||||||
          rm -rf "/usr/share/dotnet"
 | 
					 | 
				
			||||||
      - name: Clear tool cache (Windows)
 | 
					 | 
				
			||||||
        if: runner.os == 'windows'
 | 
					 | 
				
			||||||
        run: |
 | 
					 | 
				
			||||||
          echo $env:PATH
 | 
					 | 
				
			||||||
          dotnet --info
 | 
					 | 
				
			||||||
          Remove-Item $env:LocalAppData\Microsoft\dotnet/*  -Recurse -Force -ErrorAction SilentlyContinue
 | 
					 | 
				
			||||||
          Remove-Item "$env:ProgramFiles\dotnet/*"  -Recurse -Force -ErrorAction SilentlyContinue
 | 
					 | 
				
			||||||
      # Side-by-side install of 2.2 and 3.1 used for the test project
 | 
					      # Side-by-side install of 2.2 and 3.1 used for the test project
 | 
				
			||||||
      - name: Setup dotnet 2.2.402
 | 
					      - name: Setup dotnet 2.2.402
 | 
				
			||||||
        uses: ./
 | 
					        uses: ./
 | 
				
			||||||
@ -70,12 +58,86 @@ jobs:
 | 
				
			|||||||
          source-url: https://api.nuget.org/v3/index.json
 | 
					          source-url: https://api.nuget.org/v3/index.json
 | 
				
			||||||
        env:
 | 
					        env:
 | 
				
			||||||
          NUGET_AUTH_TOKEN: NOTATOKEN
 | 
					          NUGET_AUTH_TOKEN: NOTATOKEN
 | 
				
			||||||
 | 
					      - name: Verify nuget config file
 | 
				
			||||||
 | 
					        shell: pwsh
 | 
				
			||||||
 | 
					        run: |
 | 
				
			||||||
 | 
					          if (-Not (Test-Path "../nuget.config")) { throw "nuget file not generated correctly" }
 | 
				
			||||||
      - name: Verify dotnet
 | 
					      - name: Verify dotnet
 | 
				
			||||||
        if: runner.os != 'windows'
 | 
					        shell: pwsh
 | 
				
			||||||
        run: __tests__/verify-dotnet.sh 3.1.201 2.2.402
 | 
					        run: __tests__/verify-dotnet.ps1 3.1.201 2.2.402
 | 
				
			||||||
      - name: Verify dotnet (Windows)
 | 
					
 | 
				
			||||||
        if: runner.os == 'windows'
 | 
					  test-setup-without-patch-version:
 | 
				
			||||||
        run: __tests__/verify-dotnet.ps1 3.1.201
 | 
					    runs-on: ${{ matrix.operating-system }}
 | 
				
			||||||
 | 
					    strategy:
 | 
				
			||||||
 | 
					      fail-fast: false
 | 
				
			||||||
 | 
					      matrix:
 | 
				
			||||||
 | 
					        operating-system: [ubuntu-latest, windows-latest, macOS-latest]
 | 
				
			||||||
 | 
					    steps:
 | 
				
			||||||
 | 
					      - name: Checkout
 | 
				
			||||||
 | 
					        uses: actions/checkout@v2
 | 
				
			||||||
 | 
					      - name: Clear toolcache
 | 
				
			||||||
 | 
					        shell: pwsh
 | 
				
			||||||
 | 
					        run: __tests__/clear-toolcache.ps1 ${{ runner.os }}
 | 
				
			||||||
 | 
					      # 2.0, 3.0, 5.0 needs to be in single quotes to interpret as a string instead of as an integer
 | 
				
			||||||
 | 
					      - name: Setup dotnet '3.1'
 | 
				
			||||||
 | 
					        uses: ./
 | 
				
			||||||
 | 
					        with:
 | 
				
			||||||
 | 
					          dotnet-version: '3.1'
 | 
				
			||||||
 | 
					      - name: Setup dotnet '2.2'
 | 
				
			||||||
 | 
					        uses: ./
 | 
				
			||||||
 | 
					        with:
 | 
				
			||||||
 | 
					          dotnet-version: '2.2'
 | 
				
			||||||
 | 
					      - name: Verify dotnet
 | 
				
			||||||
 | 
					        shell: pwsh
 | 
				
			||||||
 | 
					        run: __tests__/verify-dotnet.ps1 3.1 2.2
 | 
				
			||||||
 | 
					  
 | 
				
			||||||
 | 
					  test-setup-latest-patch-version:
 | 
				
			||||||
 | 
					    runs-on: ${{ matrix.operating-system }}
 | 
				
			||||||
 | 
					    strategy:
 | 
				
			||||||
 | 
					      fail-fast: false
 | 
				
			||||||
 | 
					      matrix:
 | 
				
			||||||
 | 
					        operating-system: [ubuntu-latest, windows-latest, macOS-latest]
 | 
				
			||||||
 | 
					    steps:
 | 
				
			||||||
 | 
					      - name: Checkout
 | 
				
			||||||
 | 
					        uses: actions/checkout@v2
 | 
				
			||||||
 | 
					      - name: Clear toolcache
 | 
				
			||||||
 | 
					        shell: pwsh
 | 
				
			||||||
 | 
					        run: __tests__/clear-toolcache.ps1 ${{ runner.os }}
 | 
				
			||||||
 | 
					      - name: Setup dotnet 3.1.x
 | 
				
			||||||
 | 
					        uses: ./
 | 
				
			||||||
 | 
					        with:
 | 
				
			||||||
 | 
					          dotnet-version: 3.1.x
 | 
				
			||||||
 | 
					      - name: Setup dotnet 2.2.x
 | 
				
			||||||
 | 
					        uses: ./
 | 
				
			||||||
 | 
					        with:
 | 
				
			||||||
 | 
					          dotnet-version: 2.2.x
 | 
				
			||||||
 | 
					      - name: Verify dotnet
 | 
				
			||||||
 | 
					        shell: pwsh
 | 
				
			||||||
 | 
					        run: __tests__/verify-dotnet.ps1 3.1 2.2
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  test-setup-with-wildcard:
 | 
				
			||||||
 | 
					    runs-on: ${{ matrix.operating-system }}
 | 
				
			||||||
 | 
					    strategy:
 | 
				
			||||||
 | 
					      fail-fast: false
 | 
				
			||||||
 | 
					      matrix:
 | 
				
			||||||
 | 
					        operating-system: [ubuntu-latest, windows-latest, macOS-latest]
 | 
				
			||||||
 | 
					    steps:
 | 
				
			||||||
 | 
					      - name: Checkout
 | 
				
			||||||
 | 
					        uses: actions/checkout@v2
 | 
				
			||||||
 | 
					      - name: Clear toolcache
 | 
				
			||||||
 | 
					        shell: pwsh
 | 
				
			||||||
 | 
					        run: __tests__/clear-toolcache.ps1 ${{ runner.os }}
 | 
				
			||||||
 | 
					      - name: Setup dotnet 3.1.*
 | 
				
			||||||
 | 
					        uses: ./
 | 
				
			||||||
 | 
					        with:
 | 
				
			||||||
 | 
					          dotnet-version: 3.1.*
 | 
				
			||||||
 | 
					      - name: Setup dotnet 2.2.*
 | 
				
			||||||
 | 
					        uses: ./
 | 
				
			||||||
 | 
					        with:
 | 
				
			||||||
 | 
					          dotnet-version: 2.2.*
 | 
				
			||||||
 | 
					      - name: Verify dotnet
 | 
				
			||||||
 | 
					        shell: pwsh
 | 
				
			||||||
 | 
					        run: __tests__/verify-dotnet.ps1 3.1 2.2
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  test-proxy:
 | 
					  test-proxy:
 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										2
									
								
								.licenses/npm/@actions/core.dep.yml
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										2
									
								
								.licenses/npm/@actions/core.dep.yml
									
									
									
										generated
									
									
									
								
							@ -1,6 +1,6 @@
 | 
				
			|||||||
---
 | 
					---
 | 
				
			||||||
name: "@actions/core"
 | 
					name: "@actions/core"
 | 
				
			||||||
version: 1.2.5
 | 
					version: 1.2.6
 | 
				
			||||||
type: npm
 | 
					type: npm
 | 
				
			||||||
summary: Actions core lib
 | 
					summary: Actions core lib
 | 
				
			||||||
homepage: https://github.com/actions/toolkit/tree/main/packages/core
 | 
					homepage: https://github.com/actions/toolkit/tree/main/packages/core
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										13
									
								
								__tests__/clear-toolcache.ps1
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								__tests__/clear-toolcache.ps1
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,13 @@
 | 
				
			|||||||
 | 
					$dotnetPaths = @{
 | 
				
			||||||
 | 
					    Linux = @("/usr/share/dotnet")
 | 
				
			||||||
 | 
					    macOS = @("$env:HOME/.dotnet")
 | 
				
			||||||
 | 
					    Windows = @("$env:ProgramFiles\dotnet/*",
 | 
				
			||||||
 | 
					                  "$env:LocalAppData\Microsoft\dotnet/*")
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					foreach ($path in $dotnetPaths[$args[0]]) {
 | 
				
			||||||
 | 
					    if (Test-Path $path) {
 | 
				
			||||||
 | 
					        Write-Host "Clear $path path"
 | 
				
			||||||
 | 
					        Remove-Item $path -Recurse -Force
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
@ -4,79 +4,21 @@ import os = require('os');
 | 
				
			|||||||
import path = require('path');
 | 
					import path = require('path');
 | 
				
			||||||
import hc = require('@actions/http-client');
 | 
					import hc = require('@actions/http-client');
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import each from 'jest-each';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
const toolDir = path.join(__dirname, 'runner', 'tools');
 | 
					const toolDir = path.join(__dirname, 'runner', 'tools');
 | 
				
			||||||
const tempDir = path.join(__dirname, 'runner', 'temp');
 | 
					const tempDir = path.join(__dirname, 'runner', 'temp');
 | 
				
			||||||
 | 
					
 | 
				
			||||||
process.env['RUNNER_TOOL_CACHE'] = toolDir;
 | 
					process.env['RUNNER_TOOL_CACHE'] = toolDir;
 | 
				
			||||||
process.env['RUNNER_TEMP'] = tempDir;
 | 
					process.env['RUNNER_TEMP'] = tempDir;
 | 
				
			||||||
import * as setup from '../src/setup-dotnet';
 | 
					 | 
				
			||||||
import * as installer from '../src/installer';
 | 
					import * as installer from '../src/installer';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const IS_WINDOWS = process.platform === 'win32';
 | 
					const IS_WINDOWS = process.platform === 'win32';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
describe('version tests', () => {
 | 
					 | 
				
			||||||
  each(['3.1.999', '3.1.101-preview.3']).test(
 | 
					 | 
				
			||||||
    "Exact version '%s' should be the same",
 | 
					 | 
				
			||||||
    vers => {
 | 
					 | 
				
			||||||
      let versInfo = new installer.DotNetVersionInfo(vers);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      expect(versInfo.isExactVersion()).toBe(true);
 | 
					 | 
				
			||||||
      expect(versInfo.version()).toBe(vers);
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
  );
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  each([
 | 
					 | 
				
			||||||
    ['3.1.x', '3.1'],
 | 
					 | 
				
			||||||
    ['1.1.*', '1.1'],
 | 
					 | 
				
			||||||
    ['2.0', '2.0']
 | 
					 | 
				
			||||||
  ]).test("Generic version '%s' should be '%s'", (vers, resVers) => {
 | 
					 | 
				
			||||||
    let versInfo = new installer.DotNetVersionInfo(vers);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    expect(versInfo.isExactVersion()).toBe(false);
 | 
					 | 
				
			||||||
    expect(versInfo.version()).toBe(resVers);
 | 
					 | 
				
			||||||
  });
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  each([
 | 
					 | 
				
			||||||
    '',
 | 
					 | 
				
			||||||
    '.',
 | 
					 | 
				
			||||||
    '..',
 | 
					 | 
				
			||||||
    ' . ',
 | 
					 | 
				
			||||||
    '. ',
 | 
					 | 
				
			||||||
    ' .',
 | 
					 | 
				
			||||||
    ' . . ',
 | 
					 | 
				
			||||||
    ' .. ',
 | 
					 | 
				
			||||||
    ' .  ',
 | 
					 | 
				
			||||||
    '-1.-1',
 | 
					 | 
				
			||||||
    '-1',
 | 
					 | 
				
			||||||
    '-1.-1.-1',
 | 
					 | 
				
			||||||
    '..3',
 | 
					 | 
				
			||||||
    '1..3',
 | 
					 | 
				
			||||||
    '1..',
 | 
					 | 
				
			||||||
    '.2.3',
 | 
					 | 
				
			||||||
    '.2.x',
 | 
					 | 
				
			||||||
    '1',
 | 
					 | 
				
			||||||
    '2.x',
 | 
					 | 
				
			||||||
    '*.*.1',
 | 
					 | 
				
			||||||
    '*.1',
 | 
					 | 
				
			||||||
    '*.',
 | 
					 | 
				
			||||||
    '1.2.',
 | 
					 | 
				
			||||||
    '1.2.-abc',
 | 
					 | 
				
			||||||
    'a.b',
 | 
					 | 
				
			||||||
    'a.b.c',
 | 
					 | 
				
			||||||
    'a.b.c-preview',
 | 
					 | 
				
			||||||
    ' 0 . 1 . 2 '
 | 
					 | 
				
			||||||
  ]).test("Malformed version '%s' should throw", vers => {
 | 
					 | 
				
			||||||
    expect(() => new installer.DotNetVersionInfo(vers)).toThrow();
 | 
					 | 
				
			||||||
  });
 | 
					 | 
				
			||||||
});
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
describe('installer tests', () => {
 | 
					describe('installer tests', () => {
 | 
				
			||||||
  beforeAll(async () => {
 | 
					  beforeAll(async () => {
 | 
				
			||||||
    process.env.RUNNER_TOOL_CACHE = toolDir;
 | 
					    process.env.RUNNER_TOOL_CACHE = toolDir;
 | 
				
			||||||
    process.env.DOTNET_INSTALL_DIR = toolDir;
 | 
					    process.env.DOTNET_INSTALL_DIR = toolDir;
 | 
				
			||||||
    process.env.RUNNER_TEMP = tempDir;
 | 
					    process.env.RUNNER_TEMP = tempDir;
 | 
				
			||||||
 | 
					    process.env.DOTNET_ROOT = '';
 | 
				
			||||||
    await io.rmRF(toolDir);
 | 
					    await io.rmRF(toolDir);
 | 
				
			||||||
    await io.rmRF(tempDir);
 | 
					    await io.rmRF(tempDir);
 | 
				
			||||||
  });
 | 
					  });
 | 
				
			||||||
@ -90,47 +32,6 @@ describe('installer tests', () => {
 | 
				
			|||||||
    }
 | 
					    }
 | 
				
			||||||
  }, 30000);
 | 
					  }, 30000);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  it('Resolving a normal generic version works', async () => {
 | 
					 | 
				
			||||||
    const dotnetInstaller = new installer.DotnetCoreInstaller('3.1.x');
 | 
					 | 
				
			||||||
    let versInfo = await dotnetInstaller.resolveVersion(
 | 
					 | 
				
			||||||
      new installer.DotNetVersionInfo('3.1.x')
 | 
					 | 
				
			||||||
    );
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    expect(versInfo.startsWith('3.1.'));
 | 
					 | 
				
			||||||
  }, 100000);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  it('Resolving a nonexistent generic version fails', async () => {
 | 
					 | 
				
			||||||
    const dotnetInstaller = new installer.DotnetCoreInstaller('999.1.x');
 | 
					 | 
				
			||||||
    try {
 | 
					 | 
				
			||||||
      await dotnetInstaller.resolveVersion(
 | 
					 | 
				
			||||||
        new installer.DotNetVersionInfo('999.1.x')
 | 
					 | 
				
			||||||
      );
 | 
					 | 
				
			||||||
      fail();
 | 
					 | 
				
			||||||
    } catch {
 | 
					 | 
				
			||||||
      expect(true);
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
  }, 100000);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  it('Resolving a exact stable version works', async () => {
 | 
					 | 
				
			||||||
    const dotnetInstaller = new installer.DotnetCoreInstaller('3.1.201');
 | 
					 | 
				
			||||||
    let versInfo = await dotnetInstaller.resolveVersion(
 | 
					 | 
				
			||||||
      new installer.DotNetVersionInfo('3.1.201')
 | 
					 | 
				
			||||||
    );
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    expect(versInfo).toBe('3.1.201');
 | 
					 | 
				
			||||||
  }, 100000);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  it('Resolving a exact preview version works', async () => {
 | 
					 | 
				
			||||||
    const dotnetInstaller = new installer.DotnetCoreInstaller(
 | 
					 | 
				
			||||||
      '5.0.0-preview.6'
 | 
					 | 
				
			||||||
    );
 | 
					 | 
				
			||||||
    let versInfo = await dotnetInstaller.resolveVersion(
 | 
					 | 
				
			||||||
      new installer.DotNetVersionInfo('5.0.0-preview.6')
 | 
					 | 
				
			||||||
    );
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    expect(versInfo).toBe('5.0.0-preview.6');
 | 
					 | 
				
			||||||
  }, 100000);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  it('Acquires version of dotnet if no matching version is installed', async () => {
 | 
					  it('Acquires version of dotnet if no matching version is installed', async () => {
 | 
				
			||||||
    await getDotnet('3.1.201');
 | 
					    await getDotnet('3.1.201');
 | 
				
			||||||
    expect(fs.existsSync(path.join(toolDir, 'sdk', '3.1.201'))).toBe(true);
 | 
					    expect(fs.existsSync(path.join(toolDir, 'sdk', '3.1.201'))).toBe(true);
 | 
				
			||||||
@ -139,24 +40,30 @@ describe('installer tests', () => {
 | 
				
			|||||||
    } else {
 | 
					    } else {
 | 
				
			||||||
      expect(fs.existsSync(path.join(toolDir, 'dotnet'))).toBe(true);
 | 
					      expect(fs.existsSync(path.join(toolDir, 'dotnet'))).toBe(true);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  }, 400000); //This needs some time to download on "slower" internet connections
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
  it('Acquires version of dotnet from global.json if no matching version is installed', async () => {
 | 
					    expect(process.env.DOTNET_ROOT).toBeDefined;
 | 
				
			||||||
    const globalJsonPath = path.join(process.cwd(), 'global.json');
 | 
					    expect(process.env.PATH).toBeDefined;
 | 
				
			||||||
    const jsonContents = `{${os.EOL}"sdk": {${os.EOL}"version": "3.1.201"${os.EOL}}${os.EOL}}`;
 | 
					    expect(process.env.DOTNET_ROOT).toBe(toolDir);
 | 
				
			||||||
    if (!fs.existsSync(globalJsonPath)) {
 | 
					    expect(process.env.PATH?.startsWith(toolDir)).toBe(true);
 | 
				
			||||||
      fs.writeFileSync(globalJsonPath, jsonContents);
 | 
					  }, 600000); //This needs some time to download on "slower" internet connections
 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
    await setup.run();
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    expect(fs.existsSync(path.join(toolDir, 'sdk', '3.1.201'))).toBe(true);
 | 
					  it('Acquires generic version of dotnet if no matching version is installed', async () => {
 | 
				
			||||||
 | 
					    await getDotnet('3.1');
 | 
				
			||||||
 | 
					    var directory = fs
 | 
				
			||||||
 | 
					      .readdirSync(path.join(toolDir, 'sdk'))
 | 
				
			||||||
 | 
					      .filter(fn => fn.startsWith('3.1.'));
 | 
				
			||||||
 | 
					    expect(directory.length > 0).toBe(true);
 | 
				
			||||||
    if (IS_WINDOWS) {
 | 
					    if (IS_WINDOWS) {
 | 
				
			||||||
      expect(fs.existsSync(path.join(toolDir, 'dotnet.exe'))).toBe(true);
 | 
					      expect(fs.existsSync(path.join(toolDir, 'dotnet.exe'))).toBe(true);
 | 
				
			||||||
    } else {
 | 
					    } else {
 | 
				
			||||||
      expect(fs.existsSync(path.join(toolDir, 'dotnet'))).toBe(true);
 | 
					      expect(fs.existsSync(path.join(toolDir, 'dotnet'))).toBe(true);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    fs.unlinkSync(globalJsonPath);
 | 
					
 | 
				
			||||||
  }, 100000);
 | 
					    expect(process.env.DOTNET_ROOT).toBeDefined;
 | 
				
			||||||
 | 
					    expect(process.env.PATH).toBeDefined;
 | 
				
			||||||
 | 
					    expect(process.env.DOTNET_ROOT).toBe(toolDir);
 | 
				
			||||||
 | 
					    expect(process.env.PATH?.startsWith(toolDir)).toBe(true);
 | 
				
			||||||
 | 
					  }, 600000); //This needs some time to download on "slower" internet connections
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  it('Throws if no location contains correct dotnet version', async () => {
 | 
					  it('Throws if no location contains correct dotnet version', async () => {
 | 
				
			||||||
    let thrown = false;
 | 
					    let thrown = false;
 | 
				
			||||||
 | 
				
			|||||||
@ -29,7 +29,7 @@ describe('setup-dotnet tests', () => {
 | 
				
			|||||||
    }
 | 
					    }
 | 
				
			||||||
  }, 30000);
 | 
					  }, 30000);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  it('Acquires version of dotnet if no matching version is installed', async () => {
 | 
					  it('Acquires version of dotnet from global.json if no matching version is installed', async () => {
 | 
				
			||||||
    const globalJsonPath = path.join(process.cwd(), 'global.json');
 | 
					    const globalJsonPath = path.join(process.cwd(), 'global.json');
 | 
				
			||||||
    const jsonContents = `{${os.EOL}"sdk": {${os.EOL}"version": "3.1.201"${os.EOL}}${os.EOL}}`;
 | 
					    const jsonContents = `{${os.EOL}"sdk": {${os.EOL}"version": "3.1.201"${os.EOL}}${os.EOL}}`;
 | 
				
			||||||
    if (!fs.existsSync(globalJsonPath)) {
 | 
					    if (!fs.existsSync(globalJsonPath)) {
 | 
				
			||||||
@ -43,6 +43,5 @@ describe('setup-dotnet tests', () => {
 | 
				
			|||||||
    } else {
 | 
					    } else {
 | 
				
			||||||
      expect(fs.existsSync(path.join(toolDir, 'dotnet'))).toBe(true);
 | 
					      expect(fs.existsSync(path.join(toolDir, 'dotnet'))).toBe(true);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    fs.unlinkSync(globalJsonPath);
 | 
					  }, 400000);
 | 
				
			||||||
  }, 100000);
 | 
					 | 
				
			||||||
});
 | 
					});
 | 
				
			||||||
 | 
				
			|||||||
@ -3,30 +3,34 @@ if (!$args[0])
 | 
				
			|||||||
  throw "Must supply dotnet version argument"
 | 
					  throw "Must supply dotnet version argument"
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
if (-Not (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'"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
$version = & $dotnet --version | Out-String | ForEach-Object { $_.Trim() }
 | 
					$version = & $dotnet --version | Out-String | ForEach-Object { $_.Trim() }
 | 
				
			||||||
Write-Host "Version $version"
 | 
					Write-Host "Version $version"
 | 
				
			||||||
if ($version -ne $args[0])
 | 
					if (-not ($version.StartsWith($args[0].ToString())))
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
  Write-Host "PATH='$env:path'"
 | 
					  Write-Host "PATH='$env:PATH'"
 | 
				
			||||||
  throw "Unexpected version"
 | 
					  throw "Unexpected version"
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
if ($args[1])
 | 
					if ($args[1])
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
  # SDKs are listed on multiple lines with the path afterwards in square brackets
 | 
					  # SDKs are listed on multiple lines with the path afterwards in square brackets
 | 
				
			||||||
  $version = & $dotnet --list-sdks | ForEach-Object { $_.SubString(0, $_.IndexOf('[')).Trim() }
 | 
					  $versions = & $dotnet --list-sdks | ForEach-Object { $_.SubString(0, $_.IndexOf('[')).Trim() }
 | 
				
			||||||
  Write-Host "Version $version"
 | 
					  Write-Host "Installed versions: $versions"
 | 
				
			||||||
  if (-not ($version -contains $args[1]))
 | 
					  $isInstalledVersion = $false
 | 
				
			||||||
 | 
					  foreach ($version in $versions)
 | 
				
			||||||
  {
 | 
					  {
 | 
				
			||||||
    Write-Host "PATH='$env:path'"
 | 
					    if ($version.StartsWith($args[1].ToString())) 
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					      $isInstalledVersion = $true
 | 
				
			||||||
 | 
					      break
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					  if (-not $isInstalledVersion)
 | 
				
			||||||
 | 
					  {
 | 
				
			||||||
 | 
					    Write-Host "PATH='$env:PATH'"
 | 
				
			||||||
    throw "Unexpected version"
 | 
					    throw "Unexpected version"
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										90
									
								
								__tests__/versionutil.test.ts
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										90
									
								
								__tests__/versionutil.test.ts
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,90 @@
 | 
				
			|||||||
 | 
					import each from 'jest-each';
 | 
				
			||||||
 | 
					import * as installer from '../src/installer';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					describe('version tests', () => {
 | 
				
			||||||
 | 
					  each(['3.1.999', '3.1.101-preview.3']).test(
 | 
				
			||||||
 | 
					    "Exact version '%s' should be the same",
 | 
				
			||||||
 | 
					    vers => {
 | 
				
			||||||
 | 
					      let versInfo = new installer.DotNetVersionInfo(vers);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      expect(versInfo.isExactVersion()).toBe(true);
 | 
				
			||||||
 | 
					      expect(versInfo.version()).toBe(vers);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					  );
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  each([
 | 
				
			||||||
 | 
					    ['3.1.x', '3.1'],
 | 
				
			||||||
 | 
					    ['1.1.*', '1.1'],
 | 
				
			||||||
 | 
					    ['2.0', '2.0']
 | 
				
			||||||
 | 
					  ]).test("Generic version '%s' should be '%s'", (vers, resVers) => {
 | 
				
			||||||
 | 
					    let versInfo = new installer.DotNetVersionInfo(vers);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    expect(versInfo.isExactVersion()).toBe(false);
 | 
				
			||||||
 | 
					    expect(versInfo.version()).toBe(resVers);
 | 
				
			||||||
 | 
					  });
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  each([
 | 
				
			||||||
 | 
					    '',
 | 
				
			||||||
 | 
					    '.',
 | 
				
			||||||
 | 
					    '..',
 | 
				
			||||||
 | 
					    ' . ',
 | 
				
			||||||
 | 
					    '. ',
 | 
				
			||||||
 | 
					    ' .',
 | 
				
			||||||
 | 
					    ' . . ',
 | 
				
			||||||
 | 
					    ' .. ',
 | 
				
			||||||
 | 
					    ' .  ',
 | 
				
			||||||
 | 
					    '-1.-1',
 | 
				
			||||||
 | 
					    '-1',
 | 
				
			||||||
 | 
					    '-1.-1.-1',
 | 
				
			||||||
 | 
					    '..3',
 | 
				
			||||||
 | 
					    '1..3',
 | 
				
			||||||
 | 
					    '1..',
 | 
				
			||||||
 | 
					    '.2.3',
 | 
				
			||||||
 | 
					    '.2.x',
 | 
				
			||||||
 | 
					    '1',
 | 
				
			||||||
 | 
					    '2.x',
 | 
				
			||||||
 | 
					    '*.*.1',
 | 
				
			||||||
 | 
					    '*.1',
 | 
				
			||||||
 | 
					    '*.',
 | 
				
			||||||
 | 
					    '1.2.',
 | 
				
			||||||
 | 
					    '1.2.-abc',
 | 
				
			||||||
 | 
					    'a.b',
 | 
				
			||||||
 | 
					    'a.b.c',
 | 
				
			||||||
 | 
					    'a.b.c-preview',
 | 
				
			||||||
 | 
					    ' 0 . 1 . 2 '
 | 
				
			||||||
 | 
					  ]).test("Malformed version '%s' should throw", vers => {
 | 
				
			||||||
 | 
					    expect(() => new installer.DotNetVersionInfo(vers)).toThrow();
 | 
				
			||||||
 | 
					  });
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  each([
 | 
				
			||||||
 | 
					    ['3.1.x', '3.1.'],
 | 
				
			||||||
 | 
					    ['3.1.*', '3.1.'],
 | 
				
			||||||
 | 
					    ['3.1', '3.1.'],
 | 
				
			||||||
 | 
					    ['5.0.0-preview.6', '5.0.0-preview.6'],
 | 
				
			||||||
 | 
					    ['3.1.201', '3.1.201']
 | 
				
			||||||
 | 
					  ]).test(
 | 
				
			||||||
 | 
					    "Resolving version '%s' as '%s'",
 | 
				
			||||||
 | 
					    async (input, expectedVersion) => {
 | 
				
			||||||
 | 
					      const dotnetInstaller = new installer.DotnetCoreInstaller(input);
 | 
				
			||||||
 | 
					      let versInfo = await dotnetInstaller.resolveVersion(
 | 
				
			||||||
 | 
					        new installer.DotNetVersionInfo(input)
 | 
				
			||||||
 | 
					      );
 | 
				
			||||||
 | 
					      console.log(versInfo);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      expect(versInfo.startsWith(expectedVersion));
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    100000
 | 
				
			||||||
 | 
					  );
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  it('Resolving a nonexistent generic version fails', async () => {
 | 
				
			||||||
 | 
					    const dotnetInstaller = new installer.DotnetCoreInstaller('999.1.x');
 | 
				
			||||||
 | 
					    try {
 | 
				
			||||||
 | 
					      await dotnetInstaller.resolveVersion(
 | 
				
			||||||
 | 
					        new installer.DotNetVersionInfo('999.1.x')
 | 
				
			||||||
 | 
					      );
 | 
				
			||||||
 | 
					      fail();
 | 
				
			||||||
 | 
					    } catch {
 | 
				
			||||||
 | 
					      expect(true);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					  }, 100000);
 | 
				
			||||||
 | 
					});
 | 
				
			||||||
@ -6,7 +6,7 @@ branding:
 | 
				
			|||||||
  color: green
 | 
					  color: green
 | 
				
			||||||
inputs:
 | 
					inputs:
 | 
				
			||||||
  dotnet-version:
 | 
					  dotnet-version:
 | 
				
			||||||
    description: 'SDK version to use. Examples: 2.2.104, 3.1, 3.1.x'
 | 
					    description: 'Optional SDK version to use. If not provided, will install global.json version when available. Examples: 2.2.104, 3.1, 3.1.x'
 | 
				
			||||||
  source-url:
 | 
					  source-url:
 | 
				
			||||||
    description: 'Optional package source for which to set up authentication. Will consult any existing NuGet.config in the root of the repo and provide a temporary NuGet.config using the NUGET_AUTH_TOKEN environment variable as a ClearTextPassword'
 | 
					    description: 'Optional package source for which to set up authentication. Will consult any existing NuGet.config in the root of the repo and provide a temporary NuGet.config using the NUGET_AUTH_TOKEN environment variable as a ClearTextPassword'
 | 
				
			||||||
  owner:
 | 
					  owner:
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										108
									
								
								dist/index.js
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										108
									
								
								dist/index.js
									
									
									
									
										vendored
									
									
								
							@ -2932,6 +2932,32 @@ module.exports = function(tagname, parent, val) {
 | 
				
			|||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					/***/ }),
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					/***/ 82:
 | 
				
			||||||
 | 
					/***/ (function(__unusedmodule, exports) {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					"use strict";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					// We use any as a valid input type
 | 
				
			||||||
 | 
					/* eslint-disable @typescript-eslint/no-explicit-any */
 | 
				
			||||||
 | 
					Object.defineProperty(exports, "__esModule", { value: true });
 | 
				
			||||||
 | 
					/**
 | 
				
			||||||
 | 
					 * Sanitizes an input into a string so it can be passed into issueCommand safely
 | 
				
			||||||
 | 
					 * @param input input to sanitize into a string
 | 
				
			||||||
 | 
					 */
 | 
				
			||||||
 | 
					function toCommandValue(input) {
 | 
				
			||||||
 | 
					    if (input === null || input === undefined) {
 | 
				
			||||||
 | 
					        return '';
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    else if (typeof input === 'string' || input instanceof String) {
 | 
				
			||||||
 | 
					        return input;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    return JSON.stringify(input);
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					exports.toCommandValue = toCommandValue;
 | 
				
			||||||
 | 
					//# sourceMappingURL=utils.js.map
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/***/ }),
 | 
					/***/ }),
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/***/ 87:
 | 
					/***/ 87:
 | 
				
			||||||
@ -2941,6 +2967,42 @@ module.exports = require("os");
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
/***/ }),
 | 
					/***/ }),
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					/***/ 102:
 | 
				
			||||||
 | 
					/***/ (function(__unusedmodule, exports, __webpack_require__) {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					"use strict";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					// For internal use, subject to change.
 | 
				
			||||||
 | 
					var __importStar = (this && this.__importStar) || function (mod) {
 | 
				
			||||||
 | 
					    if (mod && mod.__esModule) return mod;
 | 
				
			||||||
 | 
					    var result = {};
 | 
				
			||||||
 | 
					    if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
 | 
				
			||||||
 | 
					    result["default"] = mod;
 | 
				
			||||||
 | 
					    return result;
 | 
				
			||||||
 | 
					};
 | 
				
			||||||
 | 
					Object.defineProperty(exports, "__esModule", { value: true });
 | 
				
			||||||
 | 
					// We use any as a valid input type
 | 
				
			||||||
 | 
					/* eslint-disable @typescript-eslint/no-explicit-any */
 | 
				
			||||||
 | 
					const fs = __importStar(__webpack_require__(747));
 | 
				
			||||||
 | 
					const os = __importStar(__webpack_require__(87));
 | 
				
			||||||
 | 
					const utils_1 = __webpack_require__(82);
 | 
				
			||||||
 | 
					function issueCommand(command, message) {
 | 
				
			||||||
 | 
					    const filePath = process.env[`GITHUB_${command}`];
 | 
				
			||||||
 | 
					    if (!filePath) {
 | 
				
			||||||
 | 
					        throw new Error(`Unable to find environment variable for file command ${command}`);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    if (!fs.existsSync(filePath)) {
 | 
				
			||||||
 | 
					        throw new Error(`Missing file at path: ${filePath}`);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    fs.appendFileSync(filePath, `${utils_1.toCommandValue(message)}${os.EOL}`, {
 | 
				
			||||||
 | 
					        encoding: 'utf8'
 | 
				
			||||||
 | 
					    });
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					exports.issueCommand = issueCommand;
 | 
				
			||||||
 | 
					//# sourceMappingURL=file-command.js.map
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					/***/ }),
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/***/ 118:
 | 
					/***/ 118:
 | 
				
			||||||
/***/ (function(module, __unusedexports, __webpack_require__) {
 | 
					/***/ (function(module, __unusedexports, __webpack_require__) {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -8936,6 +8998,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
 | 
				
			|||||||
};
 | 
					};
 | 
				
			||||||
Object.defineProperty(exports, "__esModule", { value: true });
 | 
					Object.defineProperty(exports, "__esModule", { value: true });
 | 
				
			||||||
const os = __importStar(__webpack_require__(87));
 | 
					const os = __importStar(__webpack_require__(87));
 | 
				
			||||||
 | 
					const utils_1 = __webpack_require__(82);
 | 
				
			||||||
/**
 | 
					/**
 | 
				
			||||||
 * Commands
 | 
					 * Commands
 | 
				
			||||||
 *
 | 
					 *
 | 
				
			||||||
@ -8989,28 +9052,14 @@ class Command {
 | 
				
			|||||||
        return cmdStr;
 | 
					        return cmdStr;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
/**
 | 
					 | 
				
			||||||
 * Sanitizes an input into a string so it can be passed into issueCommand safely
 | 
					 | 
				
			||||||
 * @param input input to sanitize into a string
 | 
					 | 
				
			||||||
 */
 | 
					 | 
				
			||||||
function toCommandValue(input) {
 | 
					 | 
				
			||||||
    if (input === null || input === undefined) {
 | 
					 | 
				
			||||||
        return '';
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
    else if (typeof input === 'string' || input instanceof String) {
 | 
					 | 
				
			||||||
        return input;
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
    return JSON.stringify(input);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
exports.toCommandValue = toCommandValue;
 | 
					 | 
				
			||||||
function escapeData(s) {
 | 
					function escapeData(s) {
 | 
				
			||||||
    return toCommandValue(s)
 | 
					    return utils_1.toCommandValue(s)
 | 
				
			||||||
        .replace(/%/g, '%25')
 | 
					        .replace(/%/g, '%25')
 | 
				
			||||||
        .replace(/\r/g, '%0D')
 | 
					        .replace(/\r/g, '%0D')
 | 
				
			||||||
        .replace(/\n/g, '%0A');
 | 
					        .replace(/\n/g, '%0A');
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
function escapeProperty(s) {
 | 
					function escapeProperty(s) {
 | 
				
			||||||
    return toCommandValue(s)
 | 
					    return utils_1.toCommandValue(s)
 | 
				
			||||||
        .replace(/%/g, '%25')
 | 
					        .replace(/%/g, '%25')
 | 
				
			||||||
        .replace(/\r/g, '%0D')
 | 
					        .replace(/\r/g, '%0D')
 | 
				
			||||||
        .replace(/\n/g, '%0A')
 | 
					        .replace(/\n/g, '%0A')
 | 
				
			||||||
@ -11241,6 +11290,8 @@ var __importStar = (this && this.__importStar) || function (mod) {
 | 
				
			|||||||
};
 | 
					};
 | 
				
			||||||
Object.defineProperty(exports, "__esModule", { value: true });
 | 
					Object.defineProperty(exports, "__esModule", { value: true });
 | 
				
			||||||
const command_1 = __webpack_require__(431);
 | 
					const command_1 = __webpack_require__(431);
 | 
				
			||||||
 | 
					const file_command_1 = __webpack_require__(102);
 | 
				
			||||||
 | 
					const utils_1 = __webpack_require__(82);
 | 
				
			||||||
const os = __importStar(__webpack_require__(87));
 | 
					const os = __importStar(__webpack_require__(87));
 | 
				
			||||||
const path = __importStar(__webpack_require__(622));
 | 
					const path = __importStar(__webpack_require__(622));
 | 
				
			||||||
/**
 | 
					/**
 | 
				
			||||||
@ -11267,10 +11318,18 @@ var ExitCode;
 | 
				
			|||||||
 */
 | 
					 */
 | 
				
			||||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
 | 
					// eslint-disable-next-line @typescript-eslint/no-explicit-any
 | 
				
			||||||
function exportVariable(name, val) {
 | 
					function exportVariable(name, val) {
 | 
				
			||||||
    const convertedVal = command_1.toCommandValue(val);
 | 
					    const convertedVal = utils_1.toCommandValue(val);
 | 
				
			||||||
    process.env[name] = convertedVal;
 | 
					    process.env[name] = convertedVal;
 | 
				
			||||||
 | 
					    const filePath = process.env['GITHUB_ENV'] || '';
 | 
				
			||||||
 | 
					    if (filePath) {
 | 
				
			||||||
 | 
					        const delimiter = '_GitHubActionsFileCommandDelimeter_';
 | 
				
			||||||
 | 
					        const commandValue = `${name}<<${delimiter}${os.EOL}${convertedVal}${os.EOL}${delimiter}`;
 | 
				
			||||||
 | 
					        file_command_1.issueCommand('ENV', commandValue);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    else {
 | 
				
			||||||
        command_1.issueCommand('set-env', { name }, convertedVal);
 | 
					        command_1.issueCommand('set-env', { name }, convertedVal);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
exports.exportVariable = exportVariable;
 | 
					exports.exportVariable = exportVariable;
 | 
				
			||||||
/**
 | 
					/**
 | 
				
			||||||
 * Registers a secret which will get masked from logs
 | 
					 * Registers a secret which will get masked from logs
 | 
				
			||||||
@ -11285,7 +11344,13 @@ exports.setSecret = setSecret;
 | 
				
			|||||||
 * @param inputPath
 | 
					 * @param inputPath
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
function addPath(inputPath) {
 | 
					function addPath(inputPath) {
 | 
				
			||||||
 | 
					    const filePath = process.env['GITHUB_PATH'] || '';
 | 
				
			||||||
 | 
					    if (filePath) {
 | 
				
			||||||
 | 
					        file_command_1.issueCommand('PATH', inputPath);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    else {
 | 
				
			||||||
        command_1.issueCommand('add-path', {}, inputPath);
 | 
					        command_1.issueCommand('add-path', {}, inputPath);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    process.env['PATH'] = `${inputPath}${path.delimiter}${process.env['PATH']}`;
 | 
					    process.env['PATH'] = `${inputPath}${path.delimiter}${process.env['PATH']}`;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
exports.addPath = addPath;
 | 
					exports.addPath = addPath;
 | 
				
			||||||
@ -16901,8 +16966,8 @@ class DotnetCoreInstaller {
 | 
				
			|||||||
                fs_1.chmodSync(escapedScript, '777');
 | 
					                fs_1.chmodSync(escapedScript, '777');
 | 
				
			||||||
                const scriptPath = yield io.which(escapedScript, true);
 | 
					                const scriptPath = yield io.which(escapedScript, true);
 | 
				
			||||||
                let scriptArguments = [];
 | 
					                let scriptArguments = [];
 | 
				
			||||||
                if (this.version) {
 | 
					                if (calculatedVersion) {
 | 
				
			||||||
                    scriptArguments.push('--version', this.version);
 | 
					                    scriptArguments.push('--version', calculatedVersion);
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
                // process.env must be explicitly passed in for DOTNET_INSTALL_DIR to be used
 | 
					                // process.env must be explicitly passed in for DOTNET_INSTALL_DIR to be used
 | 
				
			||||||
                resultCode = yield exec.exec(`"${scriptPath}"`, scriptArguments, {
 | 
					                resultCode = yield exec.exec(`"${scriptPath}"`, scriptArguments, {
 | 
				
			||||||
@ -16916,6 +16981,7 @@ class DotnetCoreInstaller {
 | 
				
			|||||||
            }
 | 
					            }
 | 
				
			||||||
            if (process.env['DOTNET_INSTALL_DIR']) {
 | 
					            if (process.env['DOTNET_INSTALL_DIR']) {
 | 
				
			||||||
                core.addPath(process.env['DOTNET_INSTALL_DIR']);
 | 
					                core.addPath(process.env['DOTNET_INSTALL_DIR']);
 | 
				
			||||||
 | 
					                core.exportVariable('DOTNET_ROOT', process.env['DOTNET_INSTALL_DIR']);
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
            else {
 | 
					            else {
 | 
				
			||||||
                if (IS_WINDOWS) {
 | 
					                if (IS_WINDOWS) {
 | 
				
			||||||
@ -16926,6 +16992,7 @@ class DotnetCoreInstaller {
 | 
				
			|||||||
                else {
 | 
					                else {
 | 
				
			||||||
                    // This is the default set in install-dotnet.sh
 | 
					                    // This is the default set in install-dotnet.sh
 | 
				
			||||||
                    core.addPath(path.join(process.env['HOME'] + '', '.dotnet'));
 | 
					                    core.addPath(path.join(process.env['HOME'] + '', '.dotnet'));
 | 
				
			||||||
 | 
					                    core.exportVariable('DOTNET_ROOT', path.join(process.env['HOME'] + '', '.dotnet'));
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
            console.log(process.env['PATH']);
 | 
					            console.log(process.env['PATH']);
 | 
				
			||||||
@ -16972,7 +17039,8 @@ class DotnetCoreInstaller {
 | 
				
			|||||||
            releasesInfo = releasesInfo.filter((info) => {
 | 
					            releasesInfo = releasesInfo.filter((info) => {
 | 
				
			||||||
                // channel-version is the first 2 elements of the version (e.g. 2.1), filter out versions that don't match 2.1.x.
 | 
					                // channel-version is the first 2 elements of the version (e.g. 2.1), filter out versions that don't match 2.1.x.
 | 
				
			||||||
                const sdkParts = info['channel-version'].split('.');
 | 
					                const sdkParts = info['channel-version'].split('.');
 | 
				
			||||||
                if (versionParts.length >= 2 && versionParts[1] != 'x') {
 | 
					                if (versionParts.length >= 2 &&
 | 
				
			||||||
 | 
					                    !(versionParts[1] == 'x' || versionParts[1] == '*')) {
 | 
				
			||||||
                    return versionParts[0] == sdkParts[0] && versionParts[1] == sdkParts[1];
 | 
					                    return versionParts[0] == sdkParts[0] && versionParts[1] == sdkParts[1];
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
                return versionParts[0] == sdkParts[0];
 | 
					                return versionParts[0] == sdkParts[0];
 | 
				
			||||||
 | 
				
			|||||||
@ -22,3 +22,13 @@ If you would like to contribute there are a few things to consider:
 | 
				
			|||||||
## Writing tests
 | 
					## Writing tests
 | 
				
			||||||
 | 
					
 | 
				
			||||||
With any contribution please take time to consider how this can be tested to maintain high quality. Current tests can be found in the folder __tests__ for examples.
 | 
					With any contribution please take time to consider how this can be tested to maintain high quality. Current tests can be found in the folder __tests__ for examples.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					## Creating new version
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Details on versioning can be found here: https://github.com/actions/toolkit/blob/main/docs/action-versioning.md
 | 
				
			||||||
 | 
					Create a new release using the UI. Version format should be `v1.x.x`. Creating a new major version requires reaction from users and should be done only with breaking changes.
 | 
				
			||||||
 | 
					Once the new release is created, the v1 tag needs to be updated as well.
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
 | 
					git tag -fa v1 -m "Update v1 tag"
 | 
				
			||||||
 | 
					git push origin v1 --force
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										660
									
								
								externals/install-dotnet.ps1
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										660
									
								
								externals/install-dotnet.ps1
									
									
									
									
										vendored
									
									
								
							@ -23,8 +23,6 @@
 | 
				
			|||||||
    Default: latest
 | 
					    Default: latest
 | 
				
			||||||
    Represents a build version on specific channel. Possible values:
 | 
					    Represents a build version on specific channel. Possible values:
 | 
				
			||||||
    - latest - most latest build on specific channel
 | 
					    - latest - most latest build on specific channel
 | 
				
			||||||
    - coherent - most latest coherent build on specific channel
 | 
					 | 
				
			||||||
          coherent applies only to SDK downloads
 | 
					 | 
				
			||||||
    - 3-part version in a format A.B.C - represents specific version of build
 | 
					    - 3-part version in a format A.B.C - represents specific version of build
 | 
				
			||||||
          examples: 2.0.0-preview2-006120, 1.1.0
 | 
					          examples: 2.0.0-preview2-006120, 1.1.0
 | 
				
			||||||
.PARAMETER InstallDir
 | 
					.PARAMETER InstallDir
 | 
				
			||||||
@ -122,24 +120,42 @@ $VersionRegEx="/\d+\.\d+[^/]+/"
 | 
				
			|||||||
$OverrideNonVersionedFiles = !$SkipNonVersionedFiles
 | 
					$OverrideNonVersionedFiles = !$SkipNonVersionedFiles
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function Say($str) {
 | 
					function Say($str) {
 | 
				
			||||||
    try
 | 
					    try {
 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
        Write-Host "dotnet-install: $str"
 | 
					        Write-Host "dotnet-install: $str"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    catch
 | 
					    catch {
 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
        # Some platforms cannot utilize Write-Host (Azure Functions, for instance). Fall back to Write-Output
 | 
					        # Some platforms cannot utilize Write-Host (Azure Functions, for instance). Fall back to Write-Output
 | 
				
			||||||
        Write-Output "dotnet-install: $str"
 | 
					        Write-Output "dotnet-install: $str"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					function Say-Warning($str) {
 | 
				
			||||||
 | 
					    try {
 | 
				
			||||||
 | 
					        Write-Warning "dotnet-install: $str"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    catch {
 | 
				
			||||||
 | 
					        # Some platforms cannot utilize Write-Warning (Azure Functions, for instance). Fall back to Write-Output
 | 
				
			||||||
 | 
					        Write-Output "dotnet-install: Warning: $str"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Writes a line with error style settings.
 | 
				
			||||||
 | 
					# Use this function to show a human-readable comment along with an exception.
 | 
				
			||||||
 | 
					function Say-Error($str) {
 | 
				
			||||||
 | 
					    try {
 | 
				
			||||||
 | 
					        # Write-Error is quite oververbose for the purpose of the function, let's write one line with error style settings.
 | 
				
			||||||
 | 
					        $Host.UI.WriteErrorLine("dotnet-install: $str")
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    catch {
 | 
				
			||||||
 | 
					        Write-Output "dotnet-install: Error: $str"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function Say-Verbose($str) {
 | 
					function Say-Verbose($str) {
 | 
				
			||||||
    try
 | 
					    try {
 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
        Write-Verbose "dotnet-install: $str"
 | 
					        Write-Verbose "dotnet-install: $str"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    catch
 | 
					    catch {
 | 
				
			||||||
    {
 | 
					 | 
				
			||||||
        # Some platforms cannot utilize Write-Verbose (Azure Functions, for instance). Fall back to Write-Output
 | 
					        # Some platforms cannot utilize Write-Verbose (Azure Functions, for instance). Fall back to Write-Output
 | 
				
			||||||
        Write-Output "dotnet-install: $str"
 | 
					        Write-Output "dotnet-install: $str"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
@ -156,7 +172,7 @@ function Invoke-With-Retry([ScriptBlock]$ScriptBlock, [int]$MaxAttempts = 3, [in
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    while ($true) {
 | 
					    while ($true) {
 | 
				
			||||||
        try {
 | 
					        try {
 | 
				
			||||||
            return $ScriptBlock.Invoke()
 | 
					            return & $ScriptBlock
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        catch {
 | 
					        catch {
 | 
				
			||||||
            $Attempts++
 | 
					            $Attempts++
 | 
				
			||||||
@ -195,7 +211,7 @@ function Get-CLIArchitecture-From-Architecture([string]$Architecture) {
 | 
				
			|||||||
        { $_ -eq "x86" } { return "x86" }
 | 
					        { $_ -eq "x86" } { return "x86" }
 | 
				
			||||||
        { $_ -eq "arm" } { return "arm" }
 | 
					        { $_ -eq "arm" } { return "arm" }
 | 
				
			||||||
        { $_ -eq "arm64" } { return "arm64" }
 | 
					        { $_ -eq "arm64" } { return "arm64" }
 | 
				
			||||||
        default { throw "Architecture not supported. If you think this is a bug, report it at https://github.com/dotnet/sdk/issues" }
 | 
					        default { throw "Architecture '$Architecture' not supported. If you think this is a bug, report it at https://github.com/dotnet/install-scripts/issues" }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -270,19 +286,42 @@ function GetHTTPResponse([Uri] $Uri)
 | 
				
			|||||||
            # Default timeout for HttpClient is 100s.  For a 50 MB download this assumes 500 KB/s average, any less will time out
 | 
					            # Default timeout for HttpClient is 100s.  For a 50 MB download this assumes 500 KB/s average, any less will time out
 | 
				
			||||||
            # 20 minutes allows it to work over much slower connections.
 | 
					            # 20 minutes allows it to work over much slower connections.
 | 
				
			||||||
            $HttpClient.Timeout = New-TimeSpan -Minutes 20
 | 
					            $HttpClient.Timeout = New-TimeSpan -Minutes 20
 | 
				
			||||||
            $Response = $HttpClient.GetAsync("${Uri}${FeedCredential}").Result
 | 
					            $Task = $HttpClient.GetAsync("${Uri}${FeedCredential}").ConfigureAwait("false");
 | 
				
			||||||
            if (($Response -eq $null) -or (-not ($Response.IsSuccessStatusCode))) {
 | 
					            $Response = $Task.GetAwaiter().GetResult();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            if (($null -eq $Response) -or (-not ($Response.IsSuccessStatusCode))) {
 | 
				
			||||||
                # The feed credential is potentially sensitive info. Do not log FeedCredential to console output.
 | 
					                # The feed credential is potentially sensitive info. Do not log FeedCredential to console output.
 | 
				
			||||||
                $ErrorMsg = "Failed to download $Uri."
 | 
					                $DownloadException = [System.Exception] "Unable to download $Uri."
 | 
				
			||||||
                if ($Response -ne $null) {
 | 
					
 | 
				
			||||||
                    $ErrorMsg += "  $Response"
 | 
					                if ($null -ne $Response) {
 | 
				
			||||||
 | 
					                    $DownloadException.Data["StatusCode"] = [int] $Response.StatusCode
 | 
				
			||||||
 | 
					                    $DownloadException.Data["ErrorMessage"] = "Unable to download $Uri. Returned HTTP status code: " + $DownloadException.Data["StatusCode"]
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                throw $ErrorMsg
 | 
					                throw $DownloadException
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            return $Response
 | 
					            return $Response
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					        catch [System.Net.Http.HttpRequestException] {
 | 
				
			||||||
 | 
					            $DownloadException = [System.Exception] "Unable to download $Uri."
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            # Pick up the exception message and inner exceptions' messages if they exist
 | 
				
			||||||
 | 
					            $CurrentException = $PSItem.Exception
 | 
				
			||||||
 | 
					            $ErrorMsg = $CurrentException.Message + "`r`n"
 | 
				
			||||||
 | 
					            while ($CurrentException.InnerException) {
 | 
				
			||||||
 | 
					              $CurrentException = $CurrentException.InnerException
 | 
				
			||||||
 | 
					              $ErrorMsg += $CurrentException.Message + "`r`n"
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            # Check if there is an issue concerning TLS.
 | 
				
			||||||
 | 
					            if ($ErrorMsg -like "*SSL/TLS*") {
 | 
				
			||||||
 | 
					                $ErrorMsg += "Ensure that TLS 1.2 or higher is enabled to use this script.`r`n"
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            $DownloadException.Data["ErrorMessage"] = $ErrorMsg
 | 
				
			||||||
 | 
					            throw $DownloadException
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
        finally {
 | 
					        finally {
 | 
				
			||||||
             if ($HttpClient -ne $null) {
 | 
					             if ($HttpClient -ne $null) {
 | 
				
			||||||
                $HttpClient.Dispose()
 | 
					                $HttpClient.Dispose()
 | 
				
			||||||
@ -291,7 +330,7 @@ function GetHTTPResponse([Uri] $Uri)
 | 
				
			|||||||
    })
 | 
					    })
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function Get-Latest-Version-Info([string]$AzureFeed, [string]$Channel, [bool]$Coherent) {
 | 
					function Get-Latest-Version-Info([string]$AzureFeed, [string]$Channel) {
 | 
				
			||||||
    Say-Invocation $MyInvocation
 | 
					    Say-Invocation $MyInvocation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    $VersionFileUrl = $null
 | 
					    $VersionFileUrl = $null
 | 
				
			||||||
@ -301,18 +340,12 @@ function Get-Latest-Version-Info([string]$AzureFeed, [string]$Channel, [bool]$Co
 | 
				
			|||||||
    elseif ($Runtime -eq "aspnetcore") {
 | 
					    elseif ($Runtime -eq "aspnetcore") {
 | 
				
			||||||
        $VersionFileUrl = "$UncachedFeed/aspnetcore/Runtime/$Channel/latest.version"
 | 
					        $VersionFileUrl = "$UncachedFeed/aspnetcore/Runtime/$Channel/latest.version"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    # Currently, the WindowsDesktop runtime is manufactured with the .Net core runtime
 | 
					 | 
				
			||||||
    elseif ($Runtime -eq "windowsdesktop") {
 | 
					    elseif ($Runtime -eq "windowsdesktop") {
 | 
				
			||||||
        $VersionFileUrl = "$UncachedFeed/Runtime/$Channel/latest.version"
 | 
					        $VersionFileUrl = "$UncachedFeed/WindowsDesktop/$Channel/latest.version"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    elseif (-not $Runtime) {
 | 
					    elseif (-not $Runtime) {
 | 
				
			||||||
        if ($Coherent) {
 | 
					 | 
				
			||||||
            $VersionFileUrl = "$UncachedFeed/Sdk/$Channel/latest.coherent.version"
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
        else {
 | 
					 | 
				
			||||||
        $VersionFileUrl = "$UncachedFeed/Sdk/$Channel/latest.version"
 | 
					        $VersionFileUrl = "$UncachedFeed/Sdk/$Channel/latest.version"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
    else {
 | 
					    else {
 | 
				
			||||||
        throw "Invalid value for `$Runtime"
 | 
					        throw "Invalid value for `$Runtime"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
@ -320,7 +353,8 @@ function Get-Latest-Version-Info([string]$AzureFeed, [string]$Channel, [bool]$Co
 | 
				
			|||||||
        $Response = GetHTTPResponse -Uri $VersionFileUrl
 | 
					        $Response = GetHTTPResponse -Uri $VersionFileUrl
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    catch {
 | 
					    catch {
 | 
				
			||||||
        throw "Could not resolve version information."
 | 
					        Say-Error "Could not resolve version information."
 | 
				
			||||||
 | 
					        throw
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    $StringContent = $Response.Content.ReadAsStringAsync().Result
 | 
					    $StringContent = $Response.Content.ReadAsStringAsync().Result
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -346,7 +380,8 @@ function Parse-Jsonfile-For-Version([string]$JSonFile) {
 | 
				
			|||||||
        $JSonContent = Get-Content($JSonFile) -Raw | ConvertFrom-Json | Select-Object -expand "sdk" -ErrorAction SilentlyContinue
 | 
					        $JSonContent = Get-Content($JSonFile) -Raw | ConvertFrom-Json | Select-Object -expand "sdk" -ErrorAction SilentlyContinue
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    catch {
 | 
					    catch {
 | 
				
			||||||
        throw "Json file unreadable: '$JSonFile'"
 | 
					        Say-Error "Json file unreadable: '$JSonFile'"
 | 
				
			||||||
 | 
					        throw
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    if ($JSonContent) {
 | 
					    if ($JSonContent) {
 | 
				
			||||||
        try {
 | 
					        try {
 | 
				
			||||||
@ -359,7 +394,8 @@ function Parse-Jsonfile-For-Version([string]$JSonFile) {
 | 
				
			|||||||
            }
 | 
					            }
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        catch {
 | 
					        catch {
 | 
				
			||||||
            throw "Unable to parse the SDK node in '$JSonFile'"
 | 
					            Say-Error "Unable to parse the SDK node in '$JSonFile'"
 | 
				
			||||||
 | 
					            throw
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    else {
 | 
					    else {
 | 
				
			||||||
@ -375,16 +411,12 @@ function Get-Specific-Version-From-Version([string]$AzureFeed, [string]$Channel,
 | 
				
			|||||||
    Say-Invocation $MyInvocation
 | 
					    Say-Invocation $MyInvocation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if (-not $JSonFile) {
 | 
					    if (-not $JSonFile) {
 | 
				
			||||||
        switch ($Version.ToLower()) {
 | 
					        if ($Version.ToLower() -eq "latest") {
 | 
				
			||||||
            { $_ -eq "latest" } {
 | 
					            $LatestVersionInfo = Get-Latest-Version-Info -AzureFeed $AzureFeed -Channel $Channel
 | 
				
			||||||
                $LatestVersionInfo = Get-Latest-Version-Info -AzureFeed $AzureFeed -Channel $Channel -Coherent $False
 | 
					 | 
				
			||||||
            return $LatestVersionInfo.Version
 | 
					            return $LatestVersionInfo.Version
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
            { $_ -eq "coherent" } {
 | 
					        else {
 | 
				
			||||||
                $LatestVersionInfo = Get-Latest-Version-Info -AzureFeed $AzureFeed -Channel $Channel -Coherent $True
 | 
					            return $Version 
 | 
				
			||||||
                return $LatestVersionInfo.Version
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
            default { return $Version }
 | 
					 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    else {
 | 
					    else {
 | 
				
			||||||
@ -395,17 +427,29 @@ function Get-Specific-Version-From-Version([string]$AzureFeed, [string]$Channel,
 | 
				
			|||||||
function Get-Download-Link([string]$AzureFeed, [string]$SpecificVersion, [string]$CLIArchitecture) {
 | 
					function Get-Download-Link([string]$AzureFeed, [string]$SpecificVersion, [string]$CLIArchitecture) {
 | 
				
			||||||
    Say-Invocation $MyInvocation
 | 
					    Say-Invocation $MyInvocation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    # If anything fails in this lookup it will default to $SpecificVersion
 | 
				
			||||||
 | 
					    $SpecificProductVersion = Get-Product-Version -AzureFeed $AzureFeed -SpecificVersion $SpecificVersion
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if ($Runtime -eq "dotnet") {
 | 
					    if ($Runtime -eq "dotnet") {
 | 
				
			||||||
        $PayloadURL = "$AzureFeed/Runtime/$SpecificVersion/dotnet-runtime-$SpecificVersion-win-$CLIArchitecture.zip"
 | 
					        $PayloadURL = "$AzureFeed/Runtime/$SpecificVersion/dotnet-runtime-$SpecificProductVersion-win-$CLIArchitecture.zip"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    elseif ($Runtime -eq "aspnetcore") {
 | 
					    elseif ($Runtime -eq "aspnetcore") {
 | 
				
			||||||
        $PayloadURL = "$AzureFeed/aspnetcore/Runtime/$SpecificVersion/aspnetcore-runtime-$SpecificVersion-win-$CLIArchitecture.zip"
 | 
					        $PayloadURL = "$AzureFeed/aspnetcore/Runtime/$SpecificVersion/aspnetcore-runtime-$SpecificProductVersion-win-$CLIArchitecture.zip"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    elseif ($Runtime -eq "windowsdesktop") {
 | 
					    elseif ($Runtime -eq "windowsdesktop") {
 | 
				
			||||||
        $PayloadURL = "$AzureFeed/Runtime/$SpecificVersion/windowsdesktop-runtime-$SpecificVersion-win-$CLIArchitecture.zip"
 | 
					        # The windows desktop runtime is part of the core runtime layout prior to 5.0
 | 
				
			||||||
 | 
					        $PayloadURL = "$AzureFeed/Runtime/$SpecificVersion/windowsdesktop-runtime-$SpecificProductVersion-win-$CLIArchitecture.zip"
 | 
				
			||||||
 | 
					        if ($SpecificVersion -match '^(\d+)\.(.*)$')
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					            $majorVersion = [int]$Matches[1]
 | 
				
			||||||
 | 
					            if ($majorVersion -ge 5)
 | 
				
			||||||
 | 
					            {
 | 
				
			||||||
 | 
					                $PayloadURL = "$AzureFeed/WindowsDesktop/$SpecificVersion/windowsdesktop-runtime-$SpecificProductVersion-win-$CLIArchitecture.zip"
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    elseif (-not $Runtime) {
 | 
					    elseif (-not $Runtime) {
 | 
				
			||||||
        $PayloadURL = "$AzureFeed/Sdk/$SpecificVersion/dotnet-sdk-$SpecificVersion-win-$CLIArchitecture.zip"
 | 
					        $PayloadURL = "$AzureFeed/Sdk/$SpecificVersion/dotnet-sdk-$SpecificProductVersion-win-$CLIArchitecture.zip"
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    else {
 | 
					    else {
 | 
				
			||||||
        throw "Invalid value for `$Runtime"
 | 
					        throw "Invalid value for `$Runtime"
 | 
				
			||||||
@ -413,7 +457,7 @@ function Get-Download-Link([string]$AzureFeed, [string]$SpecificVersion, [string
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    Say-Verbose "Constructed primary named payload URL: $PayloadURL"
 | 
					    Say-Verbose "Constructed primary named payload URL: $PayloadURL"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    return $PayloadURL
 | 
					    return $PayloadURL, $SpecificProductVersion
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function Get-LegacyDownload-Link([string]$AzureFeed, [string]$SpecificVersion, [string]$CLIArchitecture) {
 | 
					function Get-LegacyDownload-Link([string]$AzureFeed, [string]$SpecificVersion, [string]$CLIArchitecture) {
 | 
				
			||||||
@ -434,6 +478,60 @@ function Get-LegacyDownload-Link([string]$AzureFeed, [string]$SpecificVersion, [
 | 
				
			|||||||
    return $PayloadURL
 | 
					    return $PayloadURL
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					function Get-Product-Version([string]$AzureFeed, [string]$SpecificVersion) {
 | 
				
			||||||
 | 
					    Say-Invocation $MyInvocation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    if ($Runtime -eq "dotnet") {
 | 
				
			||||||
 | 
					        $ProductVersionTxtURL = "$AzureFeed/Runtime/$SpecificVersion/productVersion.txt"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    elseif ($Runtime -eq "aspnetcore") {
 | 
				
			||||||
 | 
					        $ProductVersionTxtURL = "$AzureFeed/aspnetcore/Runtime/$SpecificVersion/productVersion.txt"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    elseif ($Runtime -eq "windowsdesktop") {
 | 
				
			||||||
 | 
					        # The windows desktop runtime is part of the core runtime layout prior to 5.0
 | 
				
			||||||
 | 
					        $ProductVersionTxtURL = "$AzureFeed/Runtime/$SpecificVersion/productVersion.txt"
 | 
				
			||||||
 | 
					        if ($SpecificVersion -match '^(\d+)\.(.*)')
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					            $majorVersion = [int]$Matches[1]
 | 
				
			||||||
 | 
					            if ($majorVersion -ge 5)
 | 
				
			||||||
 | 
					            {
 | 
				
			||||||
 | 
					                $ProductVersionTxtURL = "$AzureFeed/WindowsDesktop/$SpecificVersion/productVersion.txt"
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    elseif (-not $Runtime) {
 | 
				
			||||||
 | 
					        $ProductVersionTxtURL = "$AzureFeed/Sdk/$SpecificVersion/productVersion.txt"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    else {
 | 
				
			||||||
 | 
					        throw "Invalid value '$Runtime' specified for `$Runtime"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    Say-Verbose "Checking for existence of $ProductVersionTxtURL"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    try {
 | 
				
			||||||
 | 
					        $productVersionResponse = GetHTTPResponse($productVersionTxtUrl)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        if ($productVersionResponse.StatusCode -eq 200) {
 | 
				
			||||||
 | 
					            $productVersion = $productVersionResponse.Content.ReadAsStringAsync().Result.Trim()
 | 
				
			||||||
 | 
					            if ($productVersion -ne $SpecificVersion)
 | 
				
			||||||
 | 
					            {
 | 
				
			||||||
 | 
					                Say "Using alternate version $productVersion found in $ProductVersionTxtURL"
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            return $productVersion
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					        else {
 | 
				
			||||||
 | 
					            Say-Verbose "Got StatusCode $($productVersionResponse.StatusCode) trying to get productVersion.txt at $productVersionTxtUrl, so using default value of $SpecificVersion"
 | 
				
			||||||
 | 
					            $productVersion = $SpecificVersion
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					    } catch {
 | 
				
			||||||
 | 
					        Say-Verbose "Could not read productVersion.txt at $productVersionTxtUrl, so using default value of $SpecificVersion (Exception: '$($_.Exception.Message)' )"
 | 
				
			||||||
 | 
					        $productVersion = $SpecificVersion
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    return $productVersion
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function Get-User-Share-Path() {
 | 
					function Get-User-Share-Path() {
 | 
				
			||||||
    Say-Invocation $MyInvocation
 | 
					    Say-Invocation $MyInvocation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -571,6 +669,23 @@ function DownloadFile($Source, [string]$OutPath) {
 | 
				
			|||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					function SafeRemoveFile($Path) {
 | 
				
			||||||
 | 
					    try {
 | 
				
			||||||
 | 
					        if (Test-Path $Path) {
 | 
				
			||||||
 | 
					            Remove-Item $Path
 | 
				
			||||||
 | 
					            Say-Verbose "The temporary file `"$Path`" was removed."
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					        else
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					            Say-Verbose "The temporary file `"$Path`" does not exist, therefore is not removed."
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    catch
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        Say-Warning "Failed to remove the temporary file: `"$Path`", remove it manually."
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function Prepend-Sdk-InstallRoot-To-Path([string]$InstallRoot, [string]$BinFolderRelativePath) {
 | 
					function Prepend-Sdk-InstallRoot-To-Path([string]$InstallRoot, [string]$BinFolderRelativePath) {
 | 
				
			||||||
    $BinPath = Get-Absolute-Path $(Join-Path -Path $InstallRoot -ChildPath $BinFolderRelativePath)
 | 
					    $BinPath = Get-Absolute-Path $(Join-Path -Path $InstallRoot -ChildPath $BinFolderRelativePath)
 | 
				
			||||||
    if (-Not $NoPath) {
 | 
					    if (-Not $NoPath) {
 | 
				
			||||||
@ -587,9 +702,14 @@ function Prepend-Sdk-InstallRoot-To-Path([string]$InstallRoot, [string]$BinFolde
 | 
				
			|||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Say "Note that the intended use of this script is for Continuous Integration (CI) scenarios, where:"
 | 
				
			||||||
 | 
					Say "- The SDK needs to be installed without user interaction and without admin rights."
 | 
				
			||||||
 | 
					Say "- The SDK installation doesn't need to persist across multiple CI runs."
 | 
				
			||||||
 | 
					Say "To set up a development environment or to run apps, use installers rather than this script. Visit https://dotnet.microsoft.com/download to get the installer.`r`n"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
$CLIArchitecture = Get-CLIArchitecture-From-Architecture $Architecture
 | 
					$CLIArchitecture = Get-CLIArchitecture-From-Architecture $Architecture
 | 
				
			||||||
$SpecificVersion = Get-Specific-Version-From-Version -AzureFeed $AzureFeed -Channel $Channel -Version $Version -JSonFile $JSonFile
 | 
					$SpecificVersion = Get-Specific-Version-From-Version -AzureFeed $AzureFeed -Channel $Channel -Version $Version -JSonFile $JSonFile
 | 
				
			||||||
$DownloadLink = Get-Download-Link -AzureFeed $AzureFeed -SpecificVersion $SpecificVersion -CLIArchitecture $CLIArchitecture
 | 
					$DownloadLink, $EffectiveVersion = Get-Download-Link -AzureFeed $AzureFeed -SpecificVersion $SpecificVersion -CLIArchitecture $CLIArchitecture
 | 
				
			||||||
$LegacyDownloadLink = Get-LegacyDownload-Link -AzureFeed $AzureFeed -SpecificVersion $SpecificVersion -CLIArchitecture $CLIArchitecture
 | 
					$LegacyDownloadLink = Get-LegacyDownload-Link -AzureFeed $AzureFeed -SpecificVersion $SpecificVersion -CLIArchitecture $CLIArchitecture
 | 
				
			||||||
 | 
					
 | 
				
			||||||
$InstallRoot = Resolve-Installation-Path $InstallDir
 | 
					$InstallRoot = Resolve-Installation-Path $InstallDir
 | 
				
			||||||
@ -615,7 +735,12 @@ if ($DryRun) {
 | 
				
			|||||||
        }
 | 
					        }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    Say "Repeatable invocation: $RepeatableCommand"
 | 
					    Say "Repeatable invocation: $RepeatableCommand"
 | 
				
			||||||
    exit 0
 | 
					    if ($SpecificVersion -ne $EffectiveVersion)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        Say "NOTE: Due to finding a version manifest with this runtime, it would actually install with version '$EffectiveVersion'"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    return
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
if ($Runtime -eq "dotnet") {
 | 
					if ($Runtime -eq "dotnet") {
 | 
				
			||||||
@ -638,12 +763,18 @@ else {
 | 
				
			|||||||
    throw "Invalid value for `$Runtime"
 | 
					    throw "Invalid value for `$Runtime"
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					if ($SpecificVersion -ne $EffectiveVersion)
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
					   Say "Performing installation checks for effective version: $EffectiveVersion"
 | 
				
			||||||
 | 
					   $SpecificVersion = $EffectiveVersion
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#  Check if the SDK version is already installed.
 | 
					#  Check if the SDK version is already installed.
 | 
				
			||||||
$isAssetInstalled = Is-Dotnet-Package-Installed -InstallRoot $InstallRoot -RelativePathToPackage $dotnetPackageRelativePath -SpecificVersion $SpecificVersion
 | 
					$isAssetInstalled = Is-Dotnet-Package-Installed -InstallRoot $InstallRoot -RelativePathToPackage $dotnetPackageRelativePath -SpecificVersion $SpecificVersion
 | 
				
			||||||
if ($isAssetInstalled) {
 | 
					if ($isAssetInstalled) {
 | 
				
			||||||
    Say "$assetName version $SpecificVersion is already installed."
 | 
					    Say "$assetName version $SpecificVersion is already installed."
 | 
				
			||||||
    Prepend-Sdk-InstallRoot-To-Path -InstallRoot $InstallRoot -BinFolderRelativePath $BinFolderRelativePath
 | 
					    Prepend-Sdk-InstallRoot-To-Path -InstallRoot $InstallRoot -BinFolderRelativePath $BinFolderRelativePath
 | 
				
			||||||
    exit 0
 | 
					    return
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
New-Item -ItemType Directory -Force -Path $InstallRoot | Out-Null
 | 
					New-Item -ItemType Directory -Force -Path $InstallRoot | Out-Null
 | 
				
			||||||
@ -651,30 +782,69 @@ New-Item -ItemType Directory -Force -Path $InstallRoot | Out-Null
 | 
				
			|||||||
$installDrive = $((Get-Item $InstallRoot).PSDrive.Name);
 | 
					$installDrive = $((Get-Item $InstallRoot).PSDrive.Name);
 | 
				
			||||||
$diskInfo = Get-PSDrive -Name $installDrive
 | 
					$diskInfo = Get-PSDrive -Name $installDrive
 | 
				
			||||||
if ($diskInfo.Free / 1MB -le 100) {
 | 
					if ($diskInfo.Free / 1MB -le 100) {
 | 
				
			||||||
    Say "There is not enough disk space on drive ${installDrive}:"
 | 
					    throw "There is not enough disk space on drive ${installDrive}:"
 | 
				
			||||||
    exit 0
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
$ZipPath = [System.IO.Path]::combine([System.IO.Path]::GetTempPath(), [System.IO.Path]::GetRandomFileName())
 | 
					$ZipPath = [System.IO.Path]::combine([System.IO.Path]::GetTempPath(), [System.IO.Path]::GetRandomFileName())
 | 
				
			||||||
Say-Verbose "Zip path: $ZipPath"
 | 
					Say-Verbose "Zip path: $ZipPath"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
$DownloadFailed = $false
 | 
					$DownloadFailed = $false
 | 
				
			||||||
Say "Downloading link: $DownloadLink"
 | 
					
 | 
				
			||||||
 | 
					$PrimaryDownloadStatusCode = 0
 | 
				
			||||||
 | 
					$LegacyDownloadStatusCode = 0
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					$PrimaryDownloadFailedMsg = ""
 | 
				
			||||||
 | 
					$LegacyDownloadFailedMsg = ""
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Say "Downloading primary link $DownloadLink"
 | 
				
			||||||
try {
 | 
					try {
 | 
				
			||||||
    DownloadFile -Source $DownloadLink -OutPath $ZipPath
 | 
					    DownloadFile -Source $DownloadLink -OutPath $ZipPath
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
catch {
 | 
					catch {
 | 
				
			||||||
    Say "Cannot download: $DownloadLink"
 | 
					    if ($PSItem.Exception.Data.Contains("StatusCode")) {
 | 
				
			||||||
 | 
					        $PrimaryDownloadStatusCode = $PSItem.Exception.Data["StatusCode"]
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    if ($PSItem.Exception.Data.Contains("ErrorMessage")) {
 | 
				
			||||||
 | 
					        $PrimaryDownloadFailedMsg = $PSItem.Exception.Data["ErrorMessage"]
 | 
				
			||||||
 | 
					    } else {
 | 
				
			||||||
 | 
					        $PrimaryDownloadFailedMsg = $PSItem.Exception.Message
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    if ($PrimaryDownloadStatusCode -eq 404) {
 | 
				
			||||||
 | 
					        Say "The resource at $DownloadLink is not available."
 | 
				
			||||||
 | 
					    } else {
 | 
				
			||||||
 | 
					        Say $PSItem.Exception.Message
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    SafeRemoveFile -Path $ZipPath
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if ($LegacyDownloadLink) {
 | 
					    if ($LegacyDownloadLink) {
 | 
				
			||||||
        $DownloadLink = $LegacyDownloadLink
 | 
					        $DownloadLink = $LegacyDownloadLink
 | 
				
			||||||
        $ZipPath = [System.IO.Path]::combine([System.IO.Path]::GetTempPath(), [System.IO.Path]::GetRandomFileName())
 | 
					        $ZipPath = [System.IO.Path]::combine([System.IO.Path]::GetTempPath(), [System.IO.Path]::GetRandomFileName())
 | 
				
			||||||
        Say-Verbose "Legacy zip path: $ZipPath"
 | 
					        Say-Verbose "Legacy zip path: $ZipPath"
 | 
				
			||||||
        Say "Downloading legacy link: $DownloadLink"
 | 
					        Say "Downloading legacy link $DownloadLink"
 | 
				
			||||||
        try {
 | 
					        try {
 | 
				
			||||||
            DownloadFile -Source $DownloadLink -OutPath $ZipPath
 | 
					            DownloadFile -Source $DownloadLink -OutPath $ZipPath
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        catch {
 | 
					        catch {
 | 
				
			||||||
            Say "Cannot download: $DownloadLink"
 | 
					            if ($PSItem.Exception.Data.Contains("StatusCode")) {
 | 
				
			||||||
 | 
					                $LegacyDownloadStatusCode = $PSItem.Exception.Data["StatusCode"]
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            if ($PSItem.Exception.Data.Contains("ErrorMessage")) {
 | 
				
			||||||
 | 
					                $LegacyDownloadFailedMsg = $PSItem.Exception.Data["ErrorMessage"]
 | 
				
			||||||
 | 
					            } else {
 | 
				
			||||||
 | 
					                $LegacyDownloadFailedMsg = $PSItem.Exception.Message
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            if ($LegacyDownloadStatusCode -eq 404) {
 | 
				
			||||||
 | 
					                Say "The resource at $DownloadLink is not available."
 | 
				
			||||||
 | 
					            } else {
 | 
				
			||||||
 | 
					                Say $PSItem.Exception.Message
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            SafeRemoveFile -Path $ZipPath
 | 
				
			||||||
            $DownloadFailed = $true
 | 
					            $DownloadFailed = $true
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
@ -684,7 +854,19 @@ catch {
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
if ($DownloadFailed) {
 | 
					if ($DownloadFailed) {
 | 
				
			||||||
    throw "Could not find/download: `"$assetName`" with version = $SpecificVersion`nRefer to: https://aka.ms/dotnet-os-lifecycle for information on .NET Core support"
 | 
					    if (($PrimaryDownloadStatusCode -eq 404) -and ((-not $LegacyDownloadLink) -or ($LegacyDownloadStatusCode -eq 404))) {
 | 
				
			||||||
 | 
					        throw "Could not find `"$assetName`" with version = $SpecificVersion`nRefer to: https://aka.ms/dotnet-os-lifecycle for information on .NET Core support"
 | 
				
			||||||
 | 
					    } else {
 | 
				
			||||||
 | 
					        # 404-NotFound is an expected response if it goes from only one of the links, do not show that error.
 | 
				
			||||||
 | 
					        # If primary path is available (not 404-NotFound) then show the primary error else show the legacy error.
 | 
				
			||||||
 | 
					        if ($PrimaryDownloadStatusCode -ne 404) {
 | 
				
			||||||
 | 
					            throw "Could not download `"$assetName`" with version = $SpecificVersion`r`n$PrimaryDownloadFailedMsg"
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					        if (($LegacyDownloadLink) -and ($LegacyDownloadStatusCode -ne 404)) {
 | 
				
			||||||
 | 
					            throw "Could not download `"$assetName`" with version = $SpecificVersion`r`n$LegacyDownloadFailedMsg"
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					        throw "Could not download `"$assetName`" with version = $SpecificVersion"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Say "Extracting zip from $DownloadLink"
 | 
					Say "Extracting zip from $DownloadLink"
 | 
				
			||||||
@ -706,206 +888,208 @@ if (!$isAssetInstalled) {
 | 
				
			|||||||
    $isAssetInstalled = Is-Dotnet-Package-Installed -InstallRoot $InstallRoot -RelativePathToPackage $dotnetPackageRelativePath -SpecificVersion $SpecificVersion
 | 
					    $isAssetInstalled = Is-Dotnet-Package-Installed -InstallRoot $InstallRoot -RelativePathToPackage $dotnetPackageRelativePath -SpecificVersion $SpecificVersion
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Version verification failed. More likely something is wrong either with the downloaded content or with the verification algorithm.
 | 
				
			||||||
if (!$isAssetInstalled) {
 | 
					if (!$isAssetInstalled) {
 | 
				
			||||||
 | 
					    Say-Error "Failed to verify the version of installed `"$assetName`".`nInstallation source: $DownloadLink.`nInstallation location: $InstallRoot.`nReport the bug at https://github.com/dotnet/install-scripts/issues."
 | 
				
			||||||
    throw "`"$assetName`" with version = $SpecificVersion failed to install with an unknown error."
 | 
					    throw "`"$assetName`" with version = $SpecificVersion failed to install with an unknown error."
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Remove-Item $ZipPath
 | 
					SafeRemoveFile -Path $ZipPath
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Prepend-Sdk-InstallRoot-To-Path -InstallRoot $InstallRoot -BinFolderRelativePath $BinFolderRelativePath
 | 
					Prepend-Sdk-InstallRoot-To-Path -InstallRoot $InstallRoot -BinFolderRelativePath $BinFolderRelativePath
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Say "Note that the script does not resolve dependencies during installation."
 | 
				
			||||||
 | 
					Say "To check the list of dependencies, go to https://docs.microsoft.com/dotnet/core/install/windows#dependencies"
 | 
				
			||||||
Say "Installation finished"
 | 
					Say "Installation finished"
 | 
				
			||||||
exit 0
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# SIG # Begin signature block
 | 
					# SIG # Begin signature block
 | 
				
			||||||
# MIIjlgYJKoZIhvcNAQcCoIIjhzCCI4MCAQExDzANBglghkgBZQMEAgEFADB5Bgor
 | 
					# MIIjjwYJKoZIhvcNAQcCoIIjgDCCI3wCAQExDzANBglghkgBZQMEAgEFADB5Bgor
 | 
				
			||||||
# BgEEAYI3AgEEoGswaTA0BgorBgEEAYI3AgEeMCYCAwEAAAQQH8w7YFlLCE63JNLG
 | 
					# BgEEAYI3AgEEoGswaTA0BgorBgEEAYI3AgEeMCYCAwEAAAQQH8w7YFlLCE63JNLG
 | 
				
			||||||
# KX7zUQIBAAIBAAIBAAIBAAIBADAxMA0GCWCGSAFlAwQCAQUABCCXdb9pJ+MI1iFd
 | 
					# KX7zUQIBAAIBAAIBAAIBAAIBADAxMA0GCWCGSAFlAwQCAQUABCCNsnhcJvx/hXmM
 | 
				
			||||||
# 2hUVOaNmZYt6e48+bQNJm9/Rbj3u3qCCDYUwggYDMIID66ADAgECAhMzAAABiK9S
 | 
					# w8KjuvvIMDBFonhg9XJFc1QwfTyH4aCCDYEwggX/MIID56ADAgECAhMzAAABh3IX
 | 
				
			||||||
# 1rmSbej5AAAAAAGIMA0GCSqGSIb3DQEBCwUAMH4xCzAJBgNVBAYTAlVTMRMwEQYD
 | 
					# chVZQMcJAAAAAAGHMA0GCSqGSIb3DQEBCwUAMH4xCzAJBgNVBAYTAlVTMRMwEQYD
 | 
				
			||||||
# VQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRtb25kMR4wHAYDVQQKExVNaWNy
 | 
					# VQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRtb25kMR4wHAYDVQQKExVNaWNy
 | 
				
			||||||
# b3NvZnQgQ29ycG9yYXRpb24xKDAmBgNVBAMTH01pY3Jvc29mdCBDb2RlIFNpZ25p
 | 
					# b3NvZnQgQ29ycG9yYXRpb24xKDAmBgNVBAMTH01pY3Jvc29mdCBDb2RlIFNpZ25p
 | 
				
			||||||
# bmcgUENBIDIwMTEwHhcNMjAwMzA0MTgzOTQ4WhcNMjEwMzAzMTgzOTQ4WjB0MQsw
 | 
					# bmcgUENBIDIwMTEwHhcNMjAwMzA0MTgzOTQ3WhcNMjEwMzAzMTgzOTQ3WjB0MQsw
 | 
				
			||||||
# CQYDVQQGEwJVUzETMBEGA1UECBMKV2FzaGluZ3RvbjEQMA4GA1UEBxMHUmVkbW9u
 | 
					# CQYDVQQGEwJVUzETMBEGA1UECBMKV2FzaGluZ3RvbjEQMA4GA1UEBxMHUmVkbW9u
 | 
				
			||||||
# ZDEeMBwGA1UEChMVTWljcm9zb2Z0IENvcnBvcmF0aW9uMR4wHAYDVQQDExVNaWNy
 | 
					# ZDEeMBwGA1UEChMVTWljcm9zb2Z0IENvcnBvcmF0aW9uMR4wHAYDVQQDExVNaWNy
 | 
				
			||||||
# b3NvZnQgQ29ycG9yYXRpb24wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIB
 | 
					# b3NvZnQgQ29ycG9yYXRpb24wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIB
 | 
				
			||||||
# AQCSCNryE+Cewy2m4t/a74wZ7C9YTwv1PyC4BvM/kSWPNs8n0RTe+FvYfU+E9uf0
 | 
					# AQDOt8kLc7P3T7MKIhouYHewMFmnq8Ayu7FOhZCQabVwBp2VS4WyB2Qe4TQBT8aB
 | 
				
			||||||
# t7nYlAzHjK+plif2BhD+NgdhIUQ8sVwWO39tjvQRHjP2//vSvIfmmkRoML1Ihnjs
 | 
					# znANDEPjHKNdPT8Xz5cNali6XHefS8i/WXtF0vSsP8NEv6mBHuA2p1fw2wB/F0dH
 | 
				
			||||||
# 9kQiZQzYRDYYRp9xSQYmRwQjk5hl8/U7RgOiQDitVHaU7BT1MI92lfZRuIIDDYBd
 | 
					# sJ3GfZ5c0sPJjklsiYqPw59xJ54kM91IOgiO2OUzjNAljPibjCWfH7UzQ1TPHc4d
 | 
				
			||||||
# vXtbclYJMVOwqZtv0O9zQCret6R+fRSGaDNfEEpcILL+D7RV3M4uaJE4Ta6KAOdv
 | 
					# weils8GEIrbBRb7IWwiObL12jWT4Yh71NQgvJ9Fn6+UhD9x2uk3dLj84vwt1NuFQ
 | 
				
			||||||
# V+MVaJp1YXFTZPKtpjHO6d9pHQPZiG7NdC6QbnRGmsa48uNQrb6AfmLKDI1Lp31W
 | 
					# itKJxIV0fVsRNR3abQVOLqpDugbr0SzNL6o8xzOHL5OXiGGwg6ekiXA1/2XXY7yV
 | 
				
			||||||
# MogTaX5tZf+CZT9PSuvjOCLNAgMBAAGjggGCMIIBfjAfBgNVHSUEGDAWBgorBgEE
 | 
					# Fc39tledDtZjSjNbex1zzwSXAgMBAAGjggF+MIIBejAfBgNVHSUEGDAWBgorBgEE
 | 
				
			||||||
# AYI3TAgBBggrBgEFBQcDAzAdBgNVHQ4EFgQUj9RJL9zNrPcL10RZdMQIXZN7MG8w
 | 
					# AYI3TAgBBggrBgEFBQcDAzAdBgNVHQ4EFgQUhov4ZyO96axkJdMjpzu2zVXOJcsw
 | 
				
			||||||
# VAYDVR0RBE0wS6RJMEcxLTArBgNVBAsTJE1pY3Jvc29mdCBJcmVsYW5kIE9wZXJh
 | 
					# UAYDVR0RBEkwR6RFMEMxKTAnBgNVBAsTIE1pY3Jvc29mdCBPcGVyYXRpb25zIFB1
 | 
				
			||||||
# dGlvbnMgTGltaXRlZDEWMBQGA1UEBRMNMjMwMDEyKzQ1ODM4NjAfBgNVHSMEGDAW
 | 
					# ZXJ0byBSaWNvMRYwFAYDVQQFEw0yMzAwMTIrNDU4Mzg1MB8GA1UdIwQYMBaAFEhu
 | 
				
			||||||
# gBRIbmTlUAXTgqoXNzcitW2oynUClTBUBgNVHR8ETTBLMEmgR6BFhkNodHRwOi8v
 | 
					# ZOVQBdOCqhc3NyK1bajKdQKVMFQGA1UdHwRNMEswSaBHoEWGQ2h0dHA6Ly93d3cu
 | 
				
			||||||
# d3d3Lm1pY3Jvc29mdC5jb20vcGtpb3BzL2NybC9NaWNDb2RTaWdQQ0EyMDExXzIw
 | 
					# bWljcm9zb2Z0LmNvbS9wa2lvcHMvY3JsL01pY0NvZFNpZ1BDQTIwMTFfMjAxMS0w
 | 
				
			||||||
# MTEtMDctMDguY3JsMGEGCCsGAQUFBwEBBFUwUzBRBggrBgEFBQcwAoZFaHR0cDov
 | 
					# Ny0wOC5jcmwwYQYIKwYBBQUHAQEEVTBTMFEGCCsGAQUFBzAChkVodHRwOi8vd3d3
 | 
				
			||||||
# L3d3dy5taWNyb3NvZnQuY29tL3BraW9wcy9jZXJ0cy9NaWNDb2RTaWdQQ0EyMDEx
 | 
					# Lm1pY3Jvc29mdC5jb20vcGtpb3BzL2NlcnRzL01pY0NvZFNpZ1BDQTIwMTFfMjAx
 | 
				
			||||||
# XzIwMTEtMDctMDguY3J0MAwGA1UdEwEB/wQCMAAwDQYJKoZIhvcNAQELBQADggIB
 | 
					# MS0wNy0wOC5jcnQwDAYDVR0TAQH/BAIwADANBgkqhkiG9w0BAQsFAAOCAgEAixmy
 | 
				
			||||||
# ACnXo8hjp7FeT+H6iQlV3CcGnkSbFvIpKYafgzYCFo3UHY1VHYJVb5jHEO8oG26Q
 | 
					# S6E6vprWD9KFNIB9G5zyMuIjZAOuUJ1EK/Vlg6Fb3ZHXjjUwATKIcXbFuFC6Wr4K
 | 
				
			||||||
# qBELmak6MTI+ra3WKMTGhE1sEIlowTcp4IAs8a5wpCh6Vf4Z/bAtIppP3p3gXk2X
 | 
					# NrU4DY/sBVqmab5AC/je3bpUpjtxpEyqUqtPc30wEg/rO9vmKmqKoLPT37svc2NV
 | 
				
			||||||
# 8UXTc+WxjQYsDkFiSzo/OBa5hkdW1g4EpO43l9mjToBdqEPtIXsZ7Hi1/6y4gK0P
 | 
					# BmGNl+85qO4fV/w7Cx7J0Bbqk19KcRNdjt6eKoTnTPHBHlVHQIHZpMxacbFOAkJr
 | 
				
			||||||
# mMiwG8LMpSn0n/oSHGjrUNBgHJPxgs63Slf58QGBznuXiRaXmfTUDdrvhRocdxIM
 | 
					# qAVkYZdz7ikNXTxV+GRb36tC4ByMNxE2DF7vFdvaiZP0CVZ5ByJ2gAhXMdK9+usx
 | 
				
			||||||
# i8nXQwWACMiQzJSRzBP5S2wUq7nMAqjaTbeXhJqD2SFVHdUYlKruvtPSwbnqSRWT
 | 
					# zVk913qKde1OAuWdv+rndqkAIm8fUlRnr4saSCg7cIbUwCCf116wUJ7EuJDg0vHe
 | 
				
			||||||
# GI8s4FEXt+TL3w5JnwVZmZkUFoioQDMMjFyaKurdJ6pnzbr1h6QW0R97fWc8xEIz
 | 
					# yhnCeHnBbyH3RZkHEi2ofmfgnFISJZDdMAeVZGVOh20Jp50XBzqokpPzeZ6zc1/g
 | 
				
			||||||
# LIOiU2rjwWAtlQqFO8KNiykjYGyEf5LyAJKAO+rJd9fsYR+VBauIEQoYmjnUbTXM
 | 
					# yILNyiVgE+RPkjnUQshd1f1PMgn3tns2Cz7bJiVUaqEO3n9qRFgy5JuLae6UweGf
 | 
				
			||||||
# SY2Lf5KMluWlDOGVh8q6XjmBccpaT+8tCfxpaVYPi1ncnwTwaPQvVq8RjWDRB7Pa
 | 
					# AeOo3dgLZxikKzYs3hDMaEtJq8IP71cX7QXe6lnMmXU/Hdfz2p897Zd+kU+vZvKI
 | 
				
			||||||
# 8ruHgj2HJFi69+hcq7mWx5nTUtzzFa7RSZfE5a1a5AuBmGNRr7f8cNfa01+tiWjV
 | 
					# 3cwLfuVQgK2RZ2z+Kc3K3dRPz2rXycK5XCuRZmvGab/WbrZiC7wJQapgBodltMI5
 | 
				
			||||||
# Kk1a+gJUBSP0sIxecFbVSXTZ7bqeal45XSDIisZBkWb+83TbXdTGMDSUFKTAdtC+
 | 
					# GMdFrBg9IeF7/rP4EqVQXeKtevTlZXjpuNhhjuR+2DMt/dWufjXpiW91bo3aH6Ea
 | 
				
			||||||
# r35GfsN8QVy59Hb5ZYzAXczhgRmk7NyE6jD0Ym5TKiW5MIIHejCCBWKgAwIBAgIK
 | 
					# jOALXmoxgltCp1K7hrS6gmsvj94cLRf50QQ4U8Qwggd6MIIFYqADAgECAgphDpDS
 | 
				
			||||||
# YQ6Q0gAAAAAAAzANBgkqhkiG9w0BAQsFADCBiDELMAkGA1UEBhMCVVMxEzARBgNV
 | 
					# AAAAAAADMA0GCSqGSIb3DQEBCwUAMIGIMQswCQYDVQQGEwJVUzETMBEGA1UECBMK
 | 
				
			||||||
# BAgTCldhc2hpbmd0b24xEDAOBgNVBAcTB1JlZG1vbmQxHjAcBgNVBAoTFU1pY3Jv
 | 
					 | 
				
			||||||
# c29mdCBDb3Jwb3JhdGlvbjEyMDAGA1UEAxMpTWljcm9zb2Z0IFJvb3QgQ2VydGlm
 | 
					 | 
				
			||||||
# aWNhdGUgQXV0aG9yaXR5IDIwMTEwHhcNMTEwNzA4MjA1OTA5WhcNMjYwNzA4MjEw
 | 
					 | 
				
			||||||
# OTA5WjB+MQswCQYDVQQGEwJVUzETMBEGA1UECBMKV2FzaGluZ3RvbjEQMA4GA1UE
 | 
					 | 
				
			||||||
# BxMHUmVkbW9uZDEeMBwGA1UEChMVTWljcm9zb2Z0IENvcnBvcmF0aW9uMSgwJgYD
 | 
					 | 
				
			||||||
# VQQDEx9NaWNyb3NvZnQgQ29kZSBTaWduaW5nIFBDQSAyMDExMIICIjANBgkqhkiG
 | 
					 | 
				
			||||||
# 9w0BAQEFAAOCAg8AMIICCgKCAgEAq/D6chAcLq3YbqqCEE00uvK2WCGfQhsqa+la
 | 
					 | 
				
			||||||
# UKq4BjgaBEm6f8MMHt03a8YS2AvwOMKZBrDIOdUBFDFC04kNeWSHfpRgJGyvnkmc
 | 
					 | 
				
			||||||
# 6Whe0t+bU7IKLMOv2akrrnoJr9eWWcpgGgXpZnboMlImEi/nqwhQz7NEt13YxC4D
 | 
					 | 
				
			||||||
# dato88tt8zpcoRb0RrrgOGSsbmQ1eKagYw8t00CT+OPeBw3VXHmlSSnnDb6gE3e+
 | 
					 | 
				
			||||||
# lD3v++MrWhAfTVYoonpy4BI6t0le2O3tQ5GD2Xuye4Yb2T6xjF3oiU+EGvKhL1nk
 | 
					 | 
				
			||||||
# kDstrjNYxbc+/jLTswM9sbKvkjh+0p2ALPVOVpEhNSXDOW5kf1O6nA+tGSOEy/S6
 | 
					 | 
				
			||||||
# A4aN91/w0FK/jJSHvMAhdCVfGCi2zCcoOCWYOUo2z3yxkq4cI6epZuxhH2rhKEmd
 | 
					 | 
				
			||||||
# X4jiJV3TIUs+UsS1Vz8kA/DRelsv1SPjcF0PUUZ3s/gA4bysAoJf28AVs70b1FVL
 | 
					 | 
				
			||||||
# 5zmhD+kjSbwYuER8ReTBw3J64HLnJN+/RpnF78IcV9uDjexNSTCnq47f7Fufr/zd
 | 
					 | 
				
			||||||
# sGbiwZeBe+3W7UvnSSmnEyimp31ngOaKYnhfsi+E11ecXL93KCjx7W3DKI8sj0A3
 | 
					 | 
				
			||||||
# T8HhhUSJxAlMxdSlQy90lfdu+HggWCwTXWCVmj5PM4TasIgX3p5O9JawvEagbJjS
 | 
					 | 
				
			||||||
# 4NaIjAsCAwEAAaOCAe0wggHpMBAGCSsGAQQBgjcVAQQDAgEAMB0GA1UdDgQWBBRI
 | 
					 | 
				
			||||||
# bmTlUAXTgqoXNzcitW2oynUClTAZBgkrBgEEAYI3FAIEDB4KAFMAdQBiAEMAQTAL
 | 
					 | 
				
			||||||
# BgNVHQ8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAfBgNVHSMEGDAWgBRyLToCMZBD
 | 
					 | 
				
			||||||
# uRQFTuHqp8cx0SOJNDBaBgNVHR8EUzBRME+gTaBLhklodHRwOi8vY3JsLm1pY3Jv
 | 
					 | 
				
			||||||
# c29mdC5jb20vcGtpL2NybC9wcm9kdWN0cy9NaWNSb29DZXJBdXQyMDExXzIwMTFf
 | 
					 | 
				
			||||||
# MDNfMjIuY3JsMF4GCCsGAQUFBwEBBFIwUDBOBggrBgEFBQcwAoZCaHR0cDovL3d3
 | 
					 | 
				
			||||||
# dy5taWNyb3NvZnQuY29tL3BraS9jZXJ0cy9NaWNSb29DZXJBdXQyMDExXzIwMTFf
 | 
					 | 
				
			||||||
# MDNfMjIuY3J0MIGfBgNVHSAEgZcwgZQwgZEGCSsGAQQBgjcuAzCBgzA/BggrBgEF
 | 
					 | 
				
			||||||
# BQcCARYzaHR0cDovL3d3dy5taWNyb3NvZnQuY29tL3BraW9wcy9kb2NzL3ByaW1h
 | 
					 | 
				
			||||||
# cnljcHMuaHRtMEAGCCsGAQUFBwICMDQeMiAdAEwAZQBnAGEAbABfAHAAbwBsAGkA
 | 
					 | 
				
			||||||
# YwB5AF8AcwB0AGEAdABlAG0AZQBuAHQALiAdMA0GCSqGSIb3DQEBCwUAA4ICAQBn
 | 
					 | 
				
			||||||
# 8oalmOBUeRou09h0ZyKbC5YR4WOSmUKWfdJ5DJDBZV8uLD74w3LRbYP+vj/oCso7
 | 
					 | 
				
			||||||
# v0epo/Np22O/IjWll11lhJB9i0ZQVdgMknzSGksc8zxCi1LQsP1r4z4HLimb5j0b
 | 
					 | 
				
			||||||
# pdS1HXeUOeLpZMlEPXh6I/MTfaaQdION9MsmAkYqwooQu6SpBQyb7Wj6aC6VoCo/
 | 
					 | 
				
			||||||
# KmtYSWMfCWluWpiW5IP0wI/zRive/DvQvTXvbiWu5a8n7dDd8w6vmSiXmE0OPQvy
 | 
					 | 
				
			||||||
# CInWH8MyGOLwxS3OW560STkKxgrCxq2u5bLZ2xWIUUVYODJxJxp/sfQn+N4sOiBp
 | 
					 | 
				
			||||||
# mLJZiWhub6e3dMNABQamASooPoI/E01mC8CzTfXhj38cbxV9Rad25UAqZaPDXVJi
 | 
					 | 
				
			||||||
# hsMdYzaXht/a8/jyFqGaJ+HNpZfQ7l1jQeNbB5yHPgZ3BtEGsXUfFL5hYbXw3MYb
 | 
					 | 
				
			||||||
# BL7fQccOKO7eZS/sl/ahXJbYANahRr1Z85elCUtIEJmAH9AAKcWxm6U/RXceNcbS
 | 
					 | 
				
			||||||
# oqKfenoi+kiVH6v7RyOA9Z74v2u3S5fi63V4GuzqN5l5GEv/1rMjaHXmr/r8i+sL
 | 
					 | 
				
			||||||
# gOppO6/8MO0ETI7f33VtY5E90Z1WTk+/gFcioXgRMiF670EKsT/7qMykXcGhiJtX
 | 
					 | 
				
			||||||
# cVZOSEXAQsmbdlsKgEhr/Xmfwb1tbWrJUnMTDXpQzTGCFWcwghVjAgEBMIGVMH4x
 | 
					 | 
				
			||||||
# CzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRt
 | 
					 | 
				
			||||||
# b25kMR4wHAYDVQQKExVNaWNyb3NvZnQgQ29ycG9yYXRpb24xKDAmBgNVBAMTH01p
 | 
					 | 
				
			||||||
# Y3Jvc29mdCBDb2RlIFNpZ25pbmcgUENBIDIwMTECEzMAAAGIr1LWuZJt6PkAAAAA
 | 
					 | 
				
			||||||
# AYgwDQYJYIZIAWUDBAIBBQCgga4wGQYJKoZIhvcNAQkDMQwGCisGAQQBgjcCAQQw
 | 
					 | 
				
			||||||
# HAYKKwYBBAGCNwIBCzEOMAwGCisGAQQBgjcCARUwLwYJKoZIhvcNAQkEMSIEIM9C
 | 
					 | 
				
			||||||
# NU8DMdIjlVSldghA1uP8Jf60AlCYNoHBHHW3pscjMEIGCisGAQQBgjcCAQwxNDAy
 | 
					 | 
				
			||||||
# oBSAEgBNAGkAYwByAG8AcwBvAGYAdKEagBhodHRwOi8vd3d3Lm1pY3Jvc29mdC5j
 | 
					 | 
				
			||||||
# b20wDQYJKoZIhvcNAQEBBQAEggEAFwdPmnUSAnwqMM8b4QthX44z3UnhPYm1EtjC
 | 
					 | 
				
			||||||
# /PnpTA5xkFMaoOUhGdiR5tpGPWNgiNRqD5ZSL1JVUqUOpNfybZZqZPz/LnZdS1XB
 | 
					 | 
				
			||||||
# +aj4Orh1Lkbaqq74PQxgRrUR3eyOVHcNTcohPNIb/ZYHqr6cwhqZitGuNEHNtqCk
 | 
					 | 
				
			||||||
# lSRCrfiNlW8PNrpPvUWwIC1Fd+OpgRdGhKFIHTx31if1BH8omViGm4iFdlb5dGz3
 | 
					 | 
				
			||||||
# ibeOm6FfXWwmKJVqVb/vhhemMel8tYNONTl2e+UjPOCy4f7myLiD61irA5T1a0vn
 | 
					 | 
				
			||||||
# vcIV0dRSwh8U5h8JYOEJxn4nydVKlJ5UGMS8eQiKdd42CGs93KGCEvEwghLtBgor
 | 
					 | 
				
			||||||
# BgEEAYI3AwMBMYIS3TCCEtkGCSqGSIb3DQEHAqCCEsowghLGAgEDMQ8wDQYJYIZI
 | 
					 | 
				
			||||||
# AWUDBAIBBQAwggFVBgsqhkiG9w0BCRABBKCCAUQEggFAMIIBPAIBAQYKKwYBBAGE
 | 
					 | 
				
			||||||
# WQoDATAxMA0GCWCGSAFlAwQCAQUABCCVM7LRYercP7cfHmTrb7lPfKaZCdVbtga7
 | 
					 | 
				
			||||||
# UOM/oLAsHgIGXxb9UghEGBMyMDIwMDgxMzEyMjIwNS40NjZaMASAAgH0oIHUpIHR
 | 
					 | 
				
			||||||
# MIHOMQswCQYDVQQGEwJVUzETMBEGA1UECBMKV2FzaGluZ3RvbjEQMA4GA1UEBxMH
 | 
					 | 
				
			||||||
# UmVkbW9uZDEeMBwGA1UEChMVTWljcm9zb2Z0IENvcnBvcmF0aW9uMSkwJwYDVQQL
 | 
					 | 
				
			||||||
# EyBNaWNyb3NvZnQgT3BlcmF0aW9ucyBQdWVydG8gUmljbzEmMCQGA1UECxMdVGhh
 | 
					 | 
				
			||||||
# bGVzIFRTUyBFU046RjdBNi1FMjUxLTE1MEExJTAjBgNVBAMTHE1pY3Jvc29mdCBU
 | 
					 | 
				
			||||||
# aW1lLVN0YW1wIFNlcnZpY2Wggg5EMIIE9TCCA92gAwIBAgITMwAAASWL3otsciYx
 | 
					 | 
				
			||||||
# 3QAAAAABJTANBgkqhkiG9w0BAQsFADB8MQswCQYDVQQGEwJVUzETMBEGA1UECBMK
 | 
					 | 
				
			||||||
# V2FzaGluZ3RvbjEQMA4GA1UEBxMHUmVkbW9uZDEeMBwGA1UEChMVTWljcm9zb2Z0
 | 
					# V2FzaGluZ3RvbjEQMA4GA1UEBxMHUmVkbW9uZDEeMBwGA1UEChMVTWljcm9zb2Z0
 | 
				
			||||||
# IENvcnBvcmF0aW9uMSYwJAYDVQQDEx1NaWNyb3NvZnQgVGltZS1TdGFtcCBQQ0Eg
 | 
					# IENvcnBvcmF0aW9uMTIwMAYDVQQDEylNaWNyb3NvZnQgUm9vdCBDZXJ0aWZpY2F0
 | 
				
			||||||
# MjAxMDAeFw0xOTEyMTkwMTE0NThaFw0yMTAzMTcwMTE0NThaMIHOMQswCQYDVQQG
 | 
					# ZSBBdXRob3JpdHkgMjAxMTAeFw0xMTA3MDgyMDU5MDlaFw0yNjA3MDgyMTA5MDla
 | 
				
			||||||
# EwJVUzETMBEGA1UECBMKV2FzaGluZ3RvbjEQMA4GA1UEBxMHUmVkbW9uZDEeMBwG
 | 
					# MH4xCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdS
 | 
				
			||||||
# A1UEChMVTWljcm9zb2Z0IENvcnBvcmF0aW9uMSkwJwYDVQQLEyBNaWNyb3NvZnQg
 | 
					# ZWRtb25kMR4wHAYDVQQKExVNaWNyb3NvZnQgQ29ycG9yYXRpb24xKDAmBgNVBAMT
 | 
				
			||||||
# T3BlcmF0aW9ucyBQdWVydG8gUmljbzEmMCQGA1UECxMdVGhhbGVzIFRTUyBFU046
 | 
					# H01pY3Jvc29mdCBDb2RlIFNpZ25pbmcgUENBIDIwMTEwggIiMA0GCSqGSIb3DQEB
 | 
				
			||||||
# RjdBNi1FMjUxLTE1MEExJTAjBgNVBAMTHE1pY3Jvc29mdCBUaW1lLVN0YW1wIFNl
 | 
					# AQUAA4ICDwAwggIKAoICAQCr8PpyEBwurdhuqoIQTTS68rZYIZ9CGypr6VpQqrgG
 | 
				
			||||||
# cnZpY2UwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDQex9jdmBb7OHJ
 | 
					# OBoESbp/wwwe3TdrxhLYC/A4wpkGsMg51QEUMULTiQ15ZId+lGAkbK+eSZzpaF7S
 | 
				
			||||||
# wSYmMUorZNwAcv8Vy36TlJuzcVx7G+lFqt2zjWOMlSOMkm1XoAuJ8VZ5ShBedADX
 | 
					# 35tTsgosw6/ZqSuuegmv15ZZymAaBelmdugyUiYSL+erCFDPs0S3XdjELgN1q2jz
 | 
				
			||||||
# DGDKxHNZhLu3EW8x5ot/IOk6izLTlAFtvIXOgzXs/HaOM72XHKykMZHAdL/fpZtA
 | 
					# y23zOlyhFvRGuuA4ZKxuZDV4pqBjDy3TQJP4494HDdVceaVJKecNvqATd76UPe/7
 | 
				
			||||||
# SM5PalmsXX4Ol8lXkm9jR55K56C7q9+hDU+2tjGHaE1ZWlablNUXBhaZgtCJCd60
 | 
					# 4ytaEB9NViiienLgEjq3SV7Y7e1DkYPZe7J7hhvZPrGMXeiJT4Qa8qEvWeSQOy2u
 | 
				
			||||||
# UyZvgI7/uNzcafj0/Vw2bait9nDAVd24yt/XCZnHY3yX7ZsHjIuHpsl+PpDXai1D
 | 
					# M1jFtz7+MtOzAz2xsq+SOH7SnYAs9U5WkSE1JcM5bmR/U7qcD60ZI4TL9LoDho33
 | 
				
			||||||
# we9p0ryCZsl9SOMHextIHe9qlTbtWYJ8WtWLoH9dEMQxVLnmPPDOVmBj7LZhSji3
 | 
					# X/DQUr+MlIe8wCF0JV8YKLbMJyg4JZg5SjbPfLGSrhwjp6lm7GEfauEoSZ1fiOIl
 | 
				
			||||||
# 8N9Vpz/FAgMBAAGjggEbMIIBFzAdBgNVHQ4EFgQU86rK5Qcm+QE5NBXGCPIiCBdD
 | 
					# XdMhSz5SxLVXPyQD8NF6Wy/VI+NwXQ9RRnez+ADhvKwCgl/bwBWzvRvUVUvnOaEP
 | 
				
			||||||
# JPgwHwYDVR0jBBgwFoAU1WM6XIoxkPNDe3xGG8UzaFqFbVUwVgYDVR0fBE8wTTBL
 | 
					# 6SNJvBi4RHxF5MHDcnrgcuck379GmcXvwhxX24ON7E1JMKerjt/sW5+v/N2wZuLB
 | 
				
			||||||
# oEmgR4ZFaHR0cDovL2NybC5taWNyb3NvZnQuY29tL3BraS9jcmwvcHJvZHVjdHMv
 | 
					# l4F77dbtS+dJKacTKKanfWeA5opieF+yL4TXV5xcv3coKPHtbcMojyyPQDdPweGF
 | 
				
			||||||
# TWljVGltU3RhUENBXzIwMTAtMDctMDEuY3JsMFoGCCsGAQUFBwEBBE4wTDBKBggr
 | 
					# RInECUzF1KVDL3SV9274eCBYLBNdYJWaPk8zhNqwiBfenk70lrC8RqBsmNLg1oiM
 | 
				
			||||||
# BgEFBQcwAoY+aHR0cDovL3d3dy5taWNyb3NvZnQuY29tL3BraS9jZXJ0cy9NaWNU
 | 
					# CwIDAQABo4IB7TCCAekwEAYJKwYBBAGCNxUBBAMCAQAwHQYDVR0OBBYEFEhuZOVQ
 | 
				
			||||||
# aW1TdGFQQ0FfMjAxMC0wNy0wMS5jcnQwDAYDVR0TAQH/BAIwADATBgNVHSUEDDAK
 | 
					# BdOCqhc3NyK1bajKdQKVMBkGCSsGAQQBgjcUAgQMHgoAUwB1AGIAQwBBMAsGA1Ud
 | 
				
			||||||
# BggrBgEFBQcDCDANBgkqhkiG9w0BAQsFAAOCAQEAkxxZPGEgIgAhsqZNTZk58V1v
 | 
					# DwQEAwIBhjAPBgNVHRMBAf8EBTADAQH/MB8GA1UdIwQYMBaAFHItOgIxkEO5FAVO
 | 
				
			||||||
# QiJ5ja2xHl5TqGA6Hwj5SioLg3FSLiTmGV+BtFlpYUtkneB4jrZsuNpMtfbTMdG7
 | 
					# 4eqnxzHRI4k0MFoGA1UdHwRTMFEwT6BNoEuGSWh0dHA6Ly9jcmwubWljcm9zb2Z0
 | 
				
			||||||
# p/xAyIVtwvXnTXqKlCD1T9Lcr94pVedzHGJzL1TYNQyZJBouCfzkgkzccOuFOfeW
 | 
					# LmNvbS9wa2kvY3JsL3Byb2R1Y3RzL01pY1Jvb0NlckF1dDIwMTFfMjAxMV8wM18y
 | 
				
			||||||
# PfnMTiI5UBW5OdmoyHPQWDSGHoboW1dTKqXeJtuVDTYbHTKs4zjfCBMFjmylRu52
 | 
					# Mi5jcmwwXgYIKwYBBQUHAQEEUjBQME4GCCsGAQUFBzAChkJodHRwOi8vd3d3Lm1p
 | 
				
			||||||
# Zpiz+9MBeRj4iAeou0F/3xvIzepoIKgUWCZ9mmViWEkVwCtTGbV8eK73KeEE0tfM
 | 
					# Y3Jvc29mdC5jb20vcGtpL2NlcnRzL01pY1Jvb0NlckF1dDIwMTFfMjAxMV8wM18y
 | 
				
			||||||
# U/YY2UmoGPc8YwburDEfelegLW+YHkfrcGAGlftCmqtOdOLeghLoG0Ubx/B7sTCC
 | 
					# Mi5jcnQwgZ8GA1UdIASBlzCBlDCBkQYJKwYBBAGCNy4DMIGDMD8GCCsGAQUFBwIB
 | 
				
			||||||
# BnEwggRZoAMCAQICCmEJgSoAAAAAAAIwDQYJKoZIhvcNAQELBQAwgYgxCzAJBgNV
 | 
					# FjNodHRwOi8vd3d3Lm1pY3Jvc29mdC5jb20vcGtpb3BzL2RvY3MvcHJpbWFyeWNw
 | 
				
			||||||
# BAYTAlVTMRMwEQYDVQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRtb25kMR4w
 | 
					# cy5odG0wQAYIKwYBBQUHAgIwNB4yIB0ATABlAGcAYQBsAF8AcABvAGwAaQBjAHkA
 | 
				
			||||||
# HAYDVQQKExVNaWNyb3NvZnQgQ29ycG9yYXRpb24xMjAwBgNVBAMTKU1pY3Jvc29m
 | 
					# XwBzAHQAYQB0AGUAbQBlAG4AdAAuIB0wDQYJKoZIhvcNAQELBQADggIBAGfyhqWY
 | 
				
			||||||
# dCBSb290IENlcnRpZmljYXRlIEF1dGhvcml0eSAyMDEwMB4XDTEwMDcwMTIxMzY1
 | 
					# 4FR5Gi7T2HRnIpsLlhHhY5KZQpZ90nkMkMFlXy4sPvjDctFtg/6+P+gKyju/R6mj
 | 
				
			||||||
# NVoXDTI1MDcwMTIxNDY1NVowfDELMAkGA1UEBhMCVVMxEzARBgNVBAgTCldhc2hp
 | 
					# 82nbY78iNaWXXWWEkH2LRlBV2AySfNIaSxzzPEKLUtCw/WvjPgcuKZvmPRul1LUd
 | 
				
			||||||
# bmd0b24xEDAOBgNVBAcTB1JlZG1vbmQxHjAcBgNVBAoTFU1pY3Jvc29mdCBDb3Jw
 | 
					# d5Q54ulkyUQ9eHoj8xN9ppB0g430yyYCRirCihC7pKkFDJvtaPpoLpWgKj8qa1hJ
 | 
				
			||||||
# b3JhdGlvbjEmMCQGA1UEAxMdTWljcm9zb2Z0IFRpbWUtU3RhbXAgUENBIDIwMTAw
 | 
					# Yx8JaW5amJbkg/TAj/NGK978O9C9Ne9uJa7lryft0N3zDq+ZKJeYTQ49C/IIidYf
 | 
				
			||||||
# ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCpHQ28dxGKOiDs/BOX9fp/
 | 
					# wzIY4vDFLc5bnrRJOQrGCsLGra7lstnbFYhRRVg4MnEnGn+x9Cf43iw6IGmYslmJ
 | 
				
			||||||
# aZRrdFQQ1aUKAIKF++18aEssX8XD5WHCdrc+Zitb8BVTJwQxH0EbGpUdzgkTjnxh
 | 
					# aG5vp7d0w0AFBqYBKig+gj8TTWYLwLNN9eGPfxxvFX1Fp3blQCplo8NdUmKGwx1j
 | 
				
			||||||
# MFmxMEQP8WCIhFRDDNdNuDgIs0Ldk6zWczBXJoKjRQ3Q6vVHgc2/JGAyWGBG8lhH
 | 
					# NpeG39rz+PIWoZon4c2ll9DuXWNB41sHnIc+BncG0QaxdR8UvmFhtfDcxhsEvt9B
 | 
				
			||||||
# hjKEHnRhZ5FfgVSxz5NMksHEpl3RYRNuKMYa+YaAu99h/EbBJx0kZxJyGiGKr0tk
 | 
					# xw4o7t5lL+yX9qFcltgA1qFGvVnzl6UJS0gQmYAf0AApxbGbpT9Fdx41xtKiop96
 | 
				
			||||||
# iVBisV39dx898Fd1rL2KQk1AUdEPnAY+Z3/1ZsADlkR+79BL/W7lmsqxqPJ6Kgox
 | 
					# eiL6SJUfq/tHI4D1nvi/a7dLl+LrdXga7Oo3mXkYS//WsyNodeav+vyL6wuA6mk7
 | 
				
			||||||
# 8NpOBpG2iAg16HgcsOmZzTznL0S6p/TcZL2kAcEgCZN4zfy8wMlEXV4WnAEFTyJN
 | 
					# r/ww7QRMjt/fdW1jkT3RnVZOT7+AVyKheBEyIXrvQQqxP/uozKRdwaGIm1dxVk5I
 | 
				
			||||||
# AgMBAAGjggHmMIIB4jAQBgkrBgEEAYI3FQEEAwIBADAdBgNVHQ4EFgQU1WM6XIox
 | 
					# RcBCyZt2WwqASGv9eZ/BvW1taslScxMNelDNMYIVZDCCFWACAQEwgZUwfjELMAkG
 | 
				
			||||||
# kPNDe3xGG8UzaFqFbVUwGQYJKwYBBAGCNxQCBAweCgBTAHUAYgBDAEEwCwYDVR0P
 | 
					# A1UEBhMCVVMxEzARBgNVBAgTCldhc2hpbmd0b24xEDAOBgNVBAcTB1JlZG1vbmQx
 | 
				
			||||||
# BAQDAgGGMA8GA1UdEwEB/wQFMAMBAf8wHwYDVR0jBBgwFoAU1fZWy4/oolxiaNE9
 | 
					# HjAcBgNVBAoTFU1pY3Jvc29mdCBDb3Jwb3JhdGlvbjEoMCYGA1UEAxMfTWljcm9z
 | 
				
			||||||
# lJBb186aGMQwVgYDVR0fBE8wTTBLoEmgR4ZFaHR0cDovL2NybC5taWNyb3NvZnQu
 | 
					# b2Z0IENvZGUgU2lnbmluZyBQQ0EgMjAxMQITMwAAAYdyF3IVWUDHCQAAAAABhzAN
 | 
				
			||||||
# Y29tL3BraS9jcmwvcHJvZHVjdHMvTWljUm9vQ2VyQXV0XzIwMTAtMDYtMjMuY3Js
 | 
					# BglghkgBZQMEAgEFAKCBrjAZBgkqhkiG9w0BCQMxDAYKKwYBBAGCNwIBBDAcBgor
 | 
				
			||||||
# MFoGCCsGAQUFBwEBBE4wTDBKBggrBgEFBQcwAoY+aHR0cDovL3d3dy5taWNyb3Nv
 | 
					# BgEEAYI3AgELMQ4wDAYKKwYBBAGCNwIBFTAvBgkqhkiG9w0BCQQxIgQgpT/bxWwe
 | 
				
			||||||
# ZnQuY29tL3BraS9jZXJ0cy9NaWNSb29DZXJBdXRfMjAxMC0wNi0yMy5jcnQwgaAG
 | 
					# aW0EinKMWCAzDXUjwXkIHldYzR6lw4/1Pc0wQgYKKwYBBAGCNwIBDDE0MDKgFIAS
 | 
				
			||||||
# A1UdIAEB/wSBlTCBkjCBjwYJKwYBBAGCNy4DMIGBMD0GCCsGAQUFBwIBFjFodHRw
 | 
					# AE0AaQBjAHIAbwBzAG8AZgB0oRqAGGh0dHA6Ly93d3cubWljcm9zb2Z0LmNvbTAN
 | 
				
			||||||
# Oi8vd3d3Lm1pY3Jvc29mdC5jb20vUEtJL2RvY3MvQ1BTL2RlZmF1bHQuaHRtMEAG
 | 
					# BgkqhkiG9w0BAQEFAASCAQCHd7sSQVq0YDg8QDx6/kLWn3s6jtvvIDCCgsO9spHM
 | 
				
			||||||
# CCsGAQUFBwICMDQeMiAdAEwAZQBnAGEAbABfAFAAbwBsAGkAYwB5AF8AUwB0AGEA
 | 
					# quPd4FPbG67DCsKDClekQs52qrtRO3Zo+JMnCw4j3bS+gZHzeJr2shbftOrpsFoD
 | 
				
			||||||
# dABlAG0AZQBuAHQALiAdMA0GCSqGSIb3DQEBCwUAA4ICAQAH5ohRDeLG4Jg/gXED
 | 
					# l7OPcUmtrqul9dkQCOp8t0MP3ls0n96/YyNy6lz4BAlTdkdDx957uAxalKaCIBzb
 | 
				
			||||||
# PZ2joSFvs+umzPUxvs8F4qn++ldtGTCzwsVmyWrf9efweL3HqJ4l4/m87WtUVwgr
 | 
					# R9QyppOKIfNFvwD4EI5KI6tpmSy/uH8SrRg7ZExAYZl6J6R18WkL7KHn649lPoAQ
 | 
				
			||||||
# UYJEEvu5U4zM9GASinbMQEBBm9xcF/9c+V4XNZgkVkt070IQyK+/f8Z/8jd9Wj8c
 | 
					# ujwrIXH10xOJops45ILGzKWQcHmCzLJGYapL4VHUuK+73nT+9ZROGHdk/PyvIcdw
 | 
				
			||||||
# 8pl5SpFSAK84Dxf1L3mBZdmptWvkx872ynoAb0swRCQiPM/tA6WWj1kpvLb9BOFw
 | 
					# iERa+C06v305t3DA+CuHFy1tvyw7IFF6RVbLZPwxrJjToYIS7jCCEuoGCisGAQQB
 | 
				
			||||||
# nzJKJ/1Vry/+tuWOM7tiX5rbV0Dp8c6ZZpCM/2pif93FSguRJuI57BlKcWOdeyFt
 | 
					# gjcDAwExghLaMIIS1gYJKoZIhvcNAQcCoIISxzCCEsMCAQMxDzANBglghkgBZQME
 | 
				
			||||||
# w5yjojz6f32WapB4pm3S4Zz5Hfw42JT0xqUKloakvZ4argRCg7i1gJsiOCC1JeVk
 | 
					# AgEFADCCAVUGCyqGSIb3DQEJEAEEoIIBRASCAUAwggE8AgEBBgorBgEEAYRZCgMB
 | 
				
			||||||
# 7Pf0v35jWSUPei45V3aicaoGig+JFrphpxHLmtgOR5qAxdDNp9DvfYPw4TtxCd9d
 | 
					# MDEwDQYJYIZIAWUDBAIBBQAEIOCaTmvM1AP0WaEVqzKaaCu/R+bTlR4kCrM/ZXsb
 | 
				
			||||||
# dJgiCGHasFAeb73x4QDf5zEHpJM692VHeOj4qEir995yfmFrb3epgcunCaw5u+zG
 | 
					# /eNOAgZgGeLsMwsYEzIwMjEwMjAzMjExNzQ5LjU5MVowBIACAfSggdSkgdEwgc4x
 | 
				
			||||||
# y9iCtHLNHfS4hQEegPsbiSpUObJb2sgNVZl6h3M7COaYLeqN4DMuEin1wC9UJyH3
 | 
					# CzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRt
 | 
				
			||||||
# yKxO2ii4sanblrKnQqLJzxlBTeCG+SqaoxFmMNO7dDJL32N79ZmKLxvHIa9Zta7c
 | 
					# b25kMR4wHAYDVQQKExVNaWNyb3NvZnQgQ29ycG9yYXRpb24xKTAnBgNVBAsTIE1p
 | 
				
			||||||
# RDyXUHHXodLFVeNp3lfB0d4wwP3M5k37Db9dT+mdHhk4L7zPWAUu7w2gUDXa7wkn
 | 
					# Y3Jvc29mdCBPcGVyYXRpb25zIFB1ZXJ0byBSaWNvMSYwJAYDVQQLEx1UaGFsZXMg
 | 
				
			||||||
# HNWzfjUeCLraNtvTX4/edIhJEqGCAtIwggI7AgEBMIH8oYHUpIHRMIHOMQswCQYD
 | 
					# VFNTIEVTTjo4OTdBLUUzNTYtMTcwMTElMCMGA1UEAxMcTWljcm9zb2Z0IFRpbWUt
 | 
				
			||||||
# VQQGEwJVUzETMBEGA1UECBMKV2FzaGluZ3RvbjEQMA4GA1UEBxMHUmVkbW9uZDEe
 | 
					# U3RhbXAgU2VydmljZaCCDkEwggT1MIID3aADAgECAhMzAAABLCKvRZd1+RvuAAAA
 | 
				
			||||||
# MBwGA1UEChMVTWljcm9zb2Z0IENvcnBvcmF0aW9uMSkwJwYDVQQLEyBNaWNyb3Nv
 | 
					# AAEsMA0GCSqGSIb3DQEBCwUAMHwxCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpXYXNo
 | 
				
			||||||
# ZnQgT3BlcmF0aW9ucyBQdWVydG8gUmljbzEmMCQGA1UECxMdVGhhbGVzIFRTUyBF
 | 
					# aW5ndG9uMRAwDgYDVQQHEwdSZWRtb25kMR4wHAYDVQQKExVNaWNyb3NvZnQgQ29y
 | 
				
			||||||
# U046RjdBNi1FMjUxLTE1MEExJTAjBgNVBAMTHE1pY3Jvc29mdCBUaW1lLVN0YW1w
 | 
					# cG9yYXRpb24xJjAkBgNVBAMTHU1pY3Jvc29mdCBUaW1lLVN0YW1wIFBDQSAyMDEw
 | 
				
			||||||
# IFNlcnZpY2WiIwoBATAHBgUrDgMCGgMVAEXTL+FQbc2G+3MXXvIRKVr2oXCnoIGD
 | 
					# MB4XDTE5MTIxOTAxMTUwM1oXDTIxMDMxNzAxMTUwM1owgc4xCzAJBgNVBAYTAlVT
 | 
				
			||||||
# MIGApH4wfDELMAkGA1UEBhMCVVMxEzARBgNVBAgTCldhc2hpbmd0b24xEDAOBgNV
 | 
					# MRMwEQYDVQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRtb25kMR4wHAYDVQQK
 | 
				
			||||||
# BAcTB1JlZG1vbmQxHjAcBgNVBAoTFU1pY3Jvc29mdCBDb3Jwb3JhdGlvbjEmMCQG
 | 
					# ExVNaWNyb3NvZnQgQ29ycG9yYXRpb24xKTAnBgNVBAsTIE1pY3Jvc29mdCBPcGVy
 | 
				
			||||||
# A1UEAxMdTWljcm9zb2Z0IFRpbWUtU3RhbXAgUENBIDIwMTAwDQYJKoZIhvcNAQEF
 | 
					# YXRpb25zIFB1ZXJ0byBSaWNvMSYwJAYDVQQLEx1UaGFsZXMgVFNTIEVTTjo4OTdB
 | 
				
			||||||
# BQACBQDi3yR1MCIYDzIwMjAwODEzMDYzMTE3WhgPMjAyMDA4MTQwNjMxMTdaMHcw
 | 
					# LUUzNTYtMTcwMTElMCMGA1UEAxMcTWljcm9zb2Z0IFRpbWUtU3RhbXAgU2Vydmlj
 | 
				
			||||||
# PQYKKwYBBAGEWQoEATEvMC0wCgIFAOLfJHUCAQAwCgIBAAICKbYCAf8wBwIBAAIC
 | 
					# ZTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAPK1zgSSq+MxAYo3qpCt
 | 
				
			||||||
# EkQwCgIFAOLgdfUCAQAwNgYKKwYBBAGEWQoEAjEoMCYwDAYKKwYBBAGEWQoDAqAK
 | 
					# QDxSMPPJy6mm/wfEJNjNUnYtLFBwl1BUS5trEk/t41ldxITKehs+ABxYqo4Qxsg3
 | 
				
			||||||
# MAgCAQACAwehIKEKMAgCAQACAwGGoDANBgkqhkiG9w0BAQUFAAOBgQBI2hPSmSPK
 | 
					# Gy1ugKiwHAnYiiekfC+ZhptNFgtnDZIn45zC0AlVr/6UfLtsLcHCh1XElLUHfEC0
 | 
				
			||||||
# XurK36pE46s0uBEW23aGxotfubZR3iQCxDZ+dcZEN83t2JE4wh4a9HGpzXta/1Yz
 | 
					# nBuQcM/SpYo9e3l1qY5NdMgDGxCsmCKdiZfYXIu+U0UYIBhdzmSHnB3fxZOBVcr5
 | 
				
			||||||
# fgoIxgsI5wogRQF20sCD7x7ZTbpMweqxFCQSGRE8Z2B0FmntXXrEvQtS1ee0PC/1
 | 
					# htFHEBBNt/rFJlm/A4yb8oBsp+Uf0p5QwmO/bCcdqB15JpylOhZmWs0sUfJKlK9E
 | 
				
			||||||
# +eD7oAsVwmsSWdQHKfOVBqz51g2S+ImuzTGCAw0wggMJAgEBMIGTMHwxCzAJBgNV
 | 
					# rAhBwGki2eIRFKsQBdkXS9PWpF1w2gIJRvSkDEaCf+lbGTPdSzHSbfREWOF9wY3i
 | 
				
			||||||
# BAYTAlVTMRMwEQYDVQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRtb25kMR4w
 | 
					# Yj8CAwEAAaOCARswggEXMB0GA1UdDgQWBBRRahZSGfrCQhCyIyGH9DkiaW7L0zAf
 | 
				
			||||||
# HAYDVQQKExVNaWNyb3NvZnQgQ29ycG9yYXRpb24xJjAkBgNVBAMTHU1pY3Jvc29m
 | 
					# BgNVHSMEGDAWgBTVYzpcijGQ80N7fEYbxTNoWoVtVTBWBgNVHR8ETzBNMEugSaBH
 | 
				
			||||||
# dCBUaW1lLVN0YW1wIFBDQSAyMDEwAhMzAAABJYvei2xyJjHdAAAAAAElMA0GCWCG
 | 
					# hkVodHRwOi8vY3JsLm1pY3Jvc29mdC5jb20vcGtpL2NybC9wcm9kdWN0cy9NaWNU
 | 
				
			||||||
# SAFlAwQCAQUAoIIBSjAaBgkqhkiG9w0BCQMxDQYLKoZIhvcNAQkQAQQwLwYJKoZI
 | 
					# aW1TdGFQQ0FfMjAxMC0wNy0wMS5jcmwwWgYIKwYBBQUHAQEETjBMMEoGCCsGAQUF
 | 
				
			||||||
# hvcNAQkEMSIEIJICFqJn2Gtkce4xbJqSJCqpNLdz4fjym2OW0Ac8zI+nMIH6Bgsq
 | 
					# BzAChj5odHRwOi8vd3d3Lm1pY3Jvc29mdC5jb20vcGtpL2NlcnRzL01pY1RpbVN0
 | 
				
			||||||
# hkiG9w0BCRACLzGB6jCB5zCB5DCBvQQgXd/Gsi5vMF/6iX2CDh+VfmL5RvqaFkFw
 | 
					# YVBDQV8yMDEwLTA3LTAxLmNydDAMBgNVHRMBAf8EAjAAMBMGA1UdJQQMMAoGCCsG
 | 
				
			||||||
# luiyje9B9w4wgZgwgYCkfjB8MQswCQYDVQQGEwJVUzETMBEGA1UECBMKV2FzaGlu
 | 
					# AQUFBwMIMA0GCSqGSIb3DQEBCwUAA4IBAQBPFxHIwi4vAH49w9Svmz6K3tM55RlW
 | 
				
			||||||
# Z3RvbjEQMA4GA1UEBxMHUmVkbW9uZDEeMBwGA1UEChMVTWljcm9zb2Z0IENvcnBv
 | 
					# 5pPeULXdut2Rqy6Ys0+VpZsbuaEoxs6Z1C3hMbkiqZFxxyltxJpuHTyGTg61zfNI
 | 
				
			||||||
# cmF0aW9uMSYwJAYDVQQDEx1NaWNyb3NvZnQgVGltZS1TdGFtcCBQQ0EgMjAxMAIT
 | 
					# F5n6RsYF3s7IElDXNfZznF1/2iWc6uRPZK8rxxUJ/7emYXZCYwuUY0XjsCpP9pbR
 | 
				
			||||||
# MwAAASWL3otsciYx3QAAAAABJTAiBCBSjc2CBOdr7iaTswYVN8f7KwiN5s4uBEO+
 | 
					# RKeJi6r5arSyI+NfKxvgoM21JNt1BcdlXuAecdd/k8UjxCscffanoK2n6LFw1PcZ
 | 
				
			||||||
# JVI8WLhgFzANBgkqhkiG9w0BAQsFAASCAQCfsvzXMzAN1kylt4eAKSH4ryFIJqBH
 | 
					# lEO7NId7o+soM2C0QY5BYdghpn7uqopB6ixyFIIkDXFub+1E7GmAEwfU6VwEHL7y
 | 
				
			||||||
# O7jcx7iIA9X6OPTuUmBniZGf2fmFG61V4HlmRgGOXuisJdpU3kiC7EZyFX6ZJoIj
 | 
					# 9rNE8bd+JrQs+yAtkkHy9FmXg/PsGq1daVzX1So7CJ6nyphpuHSN3VfTMIIGcTCC
 | 
				
			||||||
# kgvCQf4BPu/cLtn2w6odZ68OrTHs7BfBKBr6eQKKcZ/kgRSsjMNinh8tHPlrxE63
 | 
					# BFmgAwIBAgIKYQmBKgAAAAAAAjANBgkqhkiG9w0BAQsFADCBiDELMAkGA1UEBhMC
 | 
				
			||||||
# Zha3mUFfsnX5bi+F4VPhluGvRuA7q3IqMzfA/dTxON9WH5L+t3TwW61VebBaSPkT
 | 
					# VVMxEzARBgNVBAgTCldhc2hpbmd0b24xEDAOBgNVBAcTB1JlZG1vbmQxHjAcBgNV
 | 
				
			||||||
# YevYlj0TTlCw1B3zk0ztU37uulqDi4rFr67VaoR3qrhL/xZ/DsaNXg1V/RXqQRrw
 | 
					# BAoTFU1pY3Jvc29mdCBDb3Jwb3JhdGlvbjEyMDAGA1UEAxMpTWljcm9zb2Z0IFJv
 | 
				
			||||||
# eCag1OFRASAQOUOlWSi0QtYgUDl5FKKzxaJTEd946+6mJIkNXZB3nmA1
 | 
					# b3QgQ2VydGlmaWNhdGUgQXV0aG9yaXR5IDIwMTAwHhcNMTAwNzAxMjEzNjU1WhcN
 | 
				
			||||||
 | 
					# MjUwNzAxMjE0NjU1WjB8MQswCQYDVQQGEwJVUzETMBEGA1UECBMKV2FzaGluZ3Rv
 | 
				
			||||||
 | 
					# bjEQMA4GA1UEBxMHUmVkbW9uZDEeMBwGA1UEChMVTWljcm9zb2Z0IENvcnBvcmF0
 | 
				
			||||||
 | 
					# aW9uMSYwJAYDVQQDEx1NaWNyb3NvZnQgVGltZS1TdGFtcCBQQ0EgMjAxMDCCASIw
 | 
				
			||||||
 | 
					# DQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKkdDbx3EYo6IOz8E5f1+n9plGt0
 | 
				
			||||||
 | 
					# VBDVpQoAgoX77XxoSyxfxcPlYcJ2tz5mK1vwFVMnBDEfQRsalR3OCROOfGEwWbEw
 | 
				
			||||||
 | 
					# RA/xYIiEVEMM1024OAizQt2TrNZzMFcmgqNFDdDq9UeBzb8kYDJYYEbyWEeGMoQe
 | 
				
			||||||
 | 
					# dGFnkV+BVLHPk0ySwcSmXdFhE24oxhr5hoC732H8RsEnHSRnEnIaIYqvS2SJUGKx
 | 
				
			||||||
 | 
					# Xf13Hz3wV3WsvYpCTUBR0Q+cBj5nf/VmwAOWRH7v0Ev9buWayrGo8noqCjHw2k4G
 | 
				
			||||||
 | 
					# kbaICDXoeByw6ZnNPOcvRLqn9NxkvaQBwSAJk3jN/LzAyURdXhacAQVPIk0CAwEA
 | 
				
			||||||
 | 
					# AaOCAeYwggHiMBAGCSsGAQQBgjcVAQQDAgEAMB0GA1UdDgQWBBTVYzpcijGQ80N7
 | 
				
			||||||
 | 
					# fEYbxTNoWoVtVTAZBgkrBgEEAYI3FAIEDB4KAFMAdQBiAEMAQTALBgNVHQ8EBAMC
 | 
				
			||||||
 | 
					# AYYwDwYDVR0TAQH/BAUwAwEB/zAfBgNVHSMEGDAWgBTV9lbLj+iiXGJo0T2UkFvX
 | 
				
			||||||
 | 
					# zpoYxDBWBgNVHR8ETzBNMEugSaBHhkVodHRwOi8vY3JsLm1pY3Jvc29mdC5jb20v
 | 
				
			||||||
 | 
					# cGtpL2NybC9wcm9kdWN0cy9NaWNSb29DZXJBdXRfMjAxMC0wNi0yMy5jcmwwWgYI
 | 
				
			||||||
 | 
					# KwYBBQUHAQEETjBMMEoGCCsGAQUFBzAChj5odHRwOi8vd3d3Lm1pY3Jvc29mdC5j
 | 
				
			||||||
 | 
					# b20vcGtpL2NlcnRzL01pY1Jvb0NlckF1dF8yMDEwLTA2LTIzLmNydDCBoAYDVR0g
 | 
				
			||||||
 | 
					# AQH/BIGVMIGSMIGPBgkrBgEEAYI3LgMwgYEwPQYIKwYBBQUHAgEWMWh0dHA6Ly93
 | 
				
			||||||
 | 
					# d3cubWljcm9zb2Z0LmNvbS9QS0kvZG9jcy9DUFMvZGVmYXVsdC5odG0wQAYIKwYB
 | 
				
			||||||
 | 
					# BQUHAgIwNB4yIB0ATABlAGcAYQBsAF8AUABvAGwAaQBjAHkAXwBTAHQAYQB0AGUA
 | 
				
			||||||
 | 
					# bQBlAG4AdAAuIB0wDQYJKoZIhvcNAQELBQADggIBAAfmiFEN4sbgmD+BcQM9naOh
 | 
				
			||||||
 | 
					# IW+z66bM9TG+zwXiqf76V20ZMLPCxWbJat/15/B4vceoniXj+bzta1RXCCtRgkQS
 | 
				
			||||||
 | 
					# +7lTjMz0YBKKdsxAQEGb3FwX/1z5Xhc1mCRWS3TvQhDIr79/xn/yN31aPxzymXlK
 | 
				
			||||||
 | 
					# kVIArzgPF/UveYFl2am1a+THzvbKegBvSzBEJCI8z+0DpZaPWSm8tv0E4XCfMkon
 | 
				
			||||||
 | 
					# /VWvL/625Y4zu2JfmttXQOnxzplmkIz/amJ/3cVKC5Em4jnsGUpxY517IW3DnKOi
 | 
				
			||||||
 | 
					# PPp/fZZqkHimbdLhnPkd/DjYlPTGpQqWhqS9nhquBEKDuLWAmyI4ILUl5WTs9/S/
 | 
				
			||||||
 | 
					# fmNZJQ96LjlXdqJxqgaKD4kWumGnEcua2A5HmoDF0M2n0O99g/DhO3EJ3110mCII
 | 
				
			||||||
 | 
					# YdqwUB5vvfHhAN/nMQekkzr3ZUd46PioSKv33nJ+YWtvd6mBy6cJrDm77MbL2IK0
 | 
				
			||||||
 | 
					# cs0d9LiFAR6A+xuJKlQ5slvayA1VmXqHczsI5pgt6o3gMy4SKfXAL1QnIffIrE7a
 | 
				
			||||||
 | 
					# KLixqduWsqdCosnPGUFN4Ib5KpqjEWYw07t0MkvfY3v1mYovG8chr1m1rtxEPJdQ
 | 
				
			||||||
 | 
					# cdeh0sVV42neV8HR3jDA/czmTfsNv11P6Z0eGTgvvM9YBS7vDaBQNdrvCScc1bN+
 | 
				
			||||||
 | 
					# NR4Iuto229Nfj950iEkSoYICzzCCAjgCAQEwgfyhgdSkgdEwgc4xCzAJBgNVBAYT
 | 
				
			||||||
 | 
					# AlVTMRMwEQYDVQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRtb25kMR4wHAYD
 | 
				
			||||||
 | 
					# VQQKExVNaWNyb3NvZnQgQ29ycG9yYXRpb24xKTAnBgNVBAsTIE1pY3Jvc29mdCBP
 | 
				
			||||||
 | 
					# cGVyYXRpb25zIFB1ZXJ0byBSaWNvMSYwJAYDVQQLEx1UaGFsZXMgVFNTIEVTTjo4
 | 
				
			||||||
 | 
					# OTdBLUUzNTYtMTcwMTElMCMGA1UEAxMcTWljcm9zb2Z0IFRpbWUtU3RhbXAgU2Vy
 | 
				
			||||||
 | 
					# dmljZaIjCgEBMAcGBSsOAwIaAxUADE5OKSMoNx/mYxYWap1RTOohbJ2ggYMwgYCk
 | 
				
			||||||
 | 
					# fjB8MQswCQYDVQQGEwJVUzETMBEGA1UECBMKV2FzaGluZ3RvbjEQMA4GA1UEBxMH
 | 
				
			||||||
 | 
					# UmVkbW9uZDEeMBwGA1UEChMVTWljcm9zb2Z0IENvcnBvcmF0aW9uMSYwJAYDVQQD
 | 
				
			||||||
 | 
					# Ex1NaWNyb3NvZnQgVGltZS1TdGFtcCBQQ0EgMjAxMDANBgkqhkiG9w0BAQUFAAIF
 | 
				
			||||||
 | 
					# AOPFChkwIhgPMjAyMTAyMDMxNTQwMDlaGA8yMDIxMDIwNDE1NDAwOVowdDA6Bgor
 | 
				
			||||||
 | 
					# BgEEAYRZCgQBMSwwKjAKAgUA48UKGQIBADAHAgEAAgIXmDAHAgEAAgIRyTAKAgUA
 | 
				
			||||||
 | 
					# 48ZbmQIBADA2BgorBgEEAYRZCgQCMSgwJjAMBgorBgEEAYRZCgMCoAowCAIBAAID
 | 
				
			||||||
 | 
					# B6EgoQowCAIBAAIDAYagMA0GCSqGSIb3DQEBBQUAA4GBAHeeznL2n6HWCjHH94Fl
 | 
				
			||||||
 | 
					# hcdW6TEXzq4XNgp1Gx1W9F8gJ4x+SwoV7elJZkwgGffcpHomLvIY/VSuzsl1NgtJ
 | 
				
			||||||
 | 
					# TWM2UxoqSv58BBOrl4eGhH6kkg8Ucy2tdeK5T8cHa8pMkq2j9pFd2mRG/6VMk0dl
 | 
				
			||||||
 | 
					# Xz7Uy3Z6bZqkcABMyAfuAaGbMYIDDTCCAwkCAQEwgZMwfDELMAkGA1UEBhMCVVMx
 | 
				
			||||||
 | 
					# EzARBgNVBAgTCldhc2hpbmd0b24xEDAOBgNVBAcTB1JlZG1vbmQxHjAcBgNVBAoT
 | 
				
			||||||
 | 
					# FU1pY3Jvc29mdCBDb3Jwb3JhdGlvbjEmMCQGA1UEAxMdTWljcm9zb2Z0IFRpbWUt
 | 
				
			||||||
 | 
					# U3RhbXAgUENBIDIwMTACEzMAAAEsIq9Fl3X5G+4AAAAAASwwDQYJYIZIAWUDBAIB
 | 
				
			||||||
 | 
					# BQCgggFKMBoGCSqGSIb3DQEJAzENBgsqhkiG9w0BCRABBDAvBgkqhkiG9w0BCQQx
 | 
				
			||||||
 | 
					# IgQg/QYv7yp+354WTjWUIsXWndTEzXjaYjqwYjcBxCJKjdUwgfoGCyqGSIb3DQEJ
 | 
				
			||||||
 | 
					# EAIvMYHqMIHnMIHkMIG9BCBbn/0uFFh42hTM5XOoKdXevBaiSxmYK9Ilcn9nu5ZH
 | 
				
			||||||
 | 
					# 4TCBmDCBgKR+MHwxCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpXYXNoaW5ndG9uMRAw
 | 
				
			||||||
 | 
					# DgYDVQQHEwdSZWRtb25kMR4wHAYDVQQKExVNaWNyb3NvZnQgQ29ycG9yYXRpb24x
 | 
				
			||||||
 | 
					# JjAkBgNVBAMTHU1pY3Jvc29mdCBUaW1lLVN0YW1wIFBDQSAyMDEwAhMzAAABLCKv
 | 
				
			||||||
 | 
					# RZd1+RvuAAAAAAEsMCIEIIfIM3YbzHswb/Kj/qq1l1cHA6QBl+gEXYanUNJomrpT
 | 
				
			||||||
 | 
					# MA0GCSqGSIb3DQEBCwUABIIBAAwdcXssUZGO7ho5+NHLjIxLtQk543aKGo+lrRMY
 | 
				
			||||||
 | 
					# Q9abE1h/AaaNJl0iGxX4IihNWyfovSfYL3L4eODUBAu68tWSxeceRfWNsb/ZZfUi
 | 
				
			||||||
 | 
					# v89hpLssI/Gf1BEgNMA4zCuIGQiC8okusVumEpAhhvCEbSiTTTtBdolTnU/CAKui
 | 
				
			||||||
 | 
					# oxaU3R9XkKh1F4oAM26+dJ1J2BLQXPs5afNvvedDsZWNQUPK1sFF3JRfzxiTrwBW
 | 
				
			||||||
 | 
					# EJRyflev9gyDoqCHzippgb+6+eti1WTkcA9Q49GIT11S6LOAVqkSC9N7Nqf8ksh8
 | 
				
			||||||
 | 
					# ARdwT8jigpsm+mj7lrVU9upDkhVYhKeO8oiZq95Q53Zkteo=
 | 
				
			||||||
# SIG # End signature block
 | 
					# SIG # End signature block
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										319
									
								
								externals/install-dotnet.sh
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										319
									
								
								externals/install-dotnet.sh
									
									
									
									
										vendored
									
									
								
							@ -40,7 +40,7 @@ if [ -t 1 ] && command -v tput > /dev/null; then
 | 
				
			|||||||
fi
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
say_warning() {
 | 
					say_warning() {
 | 
				
			||||||
    printf "%b\n" "${yellow:-}dotnet_install: Warning: $1${normal:-}"
 | 
					    printf "%b\n" "${yellow:-}dotnet_install: Warning: $1${normal:-}" >&3
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
say_err() {
 | 
					say_err() {
 | 
				
			||||||
@ -183,6 +183,9 @@ get_current_os_name() {
 | 
				
			|||||||
        elif is_musl_based_distro; then
 | 
					        elif is_musl_based_distro; then
 | 
				
			||||||
            echo "linux-musl"
 | 
					            echo "linux-musl"
 | 
				
			||||||
            return 0
 | 
					            return 0
 | 
				
			||||||
 | 
					        elif [ "$linux_platform_name" = "linux-musl" ]; then
 | 
				
			||||||
 | 
					            echo "linux-musl"
 | 
				
			||||||
 | 
					            return 0
 | 
				
			||||||
        else
 | 
					        else
 | 
				
			||||||
            echo "linux"
 | 
					            echo "linux"
 | 
				
			||||||
            return 0
 | 
					            return 0
 | 
				
			||||||
@ -241,42 +244,6 @@ check_min_reqs() {
 | 
				
			|||||||
    return 0
 | 
					    return 0
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
check_pre_reqs() {
 | 
					 | 
				
			||||||
    eval $invocation
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    if [ "${DOTNET_INSTALL_SKIP_PREREQS:-}" = "1" ]; then
 | 
					 | 
				
			||||||
        return 0
 | 
					 | 
				
			||||||
    fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    if [ "$(uname)" = "Linux" ]; then
 | 
					 | 
				
			||||||
        if is_musl_based_distro; then
 | 
					 | 
				
			||||||
            if ! command -v scanelf > /dev/null; then
 | 
					 | 
				
			||||||
                say_warning "scanelf not found, please install pax-utils package."
 | 
					 | 
				
			||||||
                return 0
 | 
					 | 
				
			||||||
            fi
 | 
					 | 
				
			||||||
            LDCONFIG_COMMAND="scanelf --ldpath -BF '%f'"
 | 
					 | 
				
			||||||
            [ -z "$($LDCONFIG_COMMAND 2>/dev/null | grep libintl)" ] && say_warning "Unable to locate libintl. Probable prerequisite missing; install libintl (or gettext)."
 | 
					 | 
				
			||||||
        else
 | 
					 | 
				
			||||||
            if [ ! -x "$(command -v ldconfig)" ]; then
 | 
					 | 
				
			||||||
                say_verbose "ldconfig is not in PATH, trying /sbin/ldconfig."
 | 
					 | 
				
			||||||
                LDCONFIG_COMMAND="/sbin/ldconfig"
 | 
					 | 
				
			||||||
            else
 | 
					 | 
				
			||||||
                LDCONFIG_COMMAND="ldconfig"
 | 
					 | 
				
			||||||
            fi
 | 
					 | 
				
			||||||
            local librarypath=${LD_LIBRARY_PATH:-}
 | 
					 | 
				
			||||||
            LDCONFIG_COMMAND="$LDCONFIG_COMMAND -NXv ${librarypath//:/ }"
 | 
					 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        [ -z "$($LDCONFIG_COMMAND 2>/dev/null | grep zlib)" ] && say_warning "Unable to locate zlib. Probable prerequisite missing; install zlib."
 | 
					 | 
				
			||||||
        [ -z "$($LDCONFIG_COMMAND 2>/dev/null | grep ssl)" ] && say_warning "Unable to locate libssl. Probable prerequisite missing; install libssl."
 | 
					 | 
				
			||||||
        [ -z "$($LDCONFIG_COMMAND 2>/dev/null | grep libicu)" ] && say_warning "Unable to locate libicu. Probable prerequisite missing; install libicu."
 | 
					 | 
				
			||||||
        [ -z "$($LDCONFIG_COMMAND 2>/dev/null | grep lttng)" ] && say_warning "Unable to locate liblttng. Probable prerequisite missing; install libcurl."
 | 
					 | 
				
			||||||
        [ -z "$($LDCONFIG_COMMAND 2>/dev/null | grep libcurl)" ] && say_warning "Unable to locate libcurl. Probable prerequisite missing; install libcurl."
 | 
					 | 
				
			||||||
    fi
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    return 0
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# args:
 | 
					# args:
 | 
				
			||||||
# input - $1
 | 
					# input - $1
 | 
				
			||||||
to_lowercase() {
 | 
					to_lowercase() {
 | 
				
			||||||
@ -332,11 +299,11 @@ get_machine_architecture() {
 | 
				
			|||||||
    if command -v uname > /dev/null; then
 | 
					    if command -v uname > /dev/null; then
 | 
				
			||||||
        CPUName=$(uname -m)
 | 
					        CPUName=$(uname -m)
 | 
				
			||||||
        case $CPUName in
 | 
					        case $CPUName in
 | 
				
			||||||
        armv7l)
 | 
					        armv*l)
 | 
				
			||||||
            echo "arm"
 | 
					            echo "arm"
 | 
				
			||||||
            return 0
 | 
					            return 0
 | 
				
			||||||
            ;;
 | 
					            ;;
 | 
				
			||||||
        aarch64)
 | 
					        aarch64|arm64)
 | 
				
			||||||
            echo "arm64"
 | 
					            echo "arm64"
 | 
				
			||||||
            return 0
 | 
					            return 0
 | 
				
			||||||
            ;;
 | 
					            ;;
 | 
				
			||||||
@ -373,10 +340,34 @@ get_normalized_architecture_from_architecture() {
 | 
				
			|||||||
            ;;
 | 
					            ;;
 | 
				
			||||||
    esac
 | 
					    esac
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    say_err "Architecture \`$architecture\` not supported. If you think this is a bug, report it at https://github.com/dotnet/sdk/issues"
 | 
					    say_err "Architecture \`$architecture\` not supported. If you think this is a bug, report it at https://github.com/dotnet/install-scripts/issues"
 | 
				
			||||||
    return 1
 | 
					    return 1
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# args:
 | 
				
			||||||
 | 
					# user_defined_os - $1
 | 
				
			||||||
 | 
					get_normalized_os() {
 | 
				
			||||||
 | 
					    eval $invocation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    local osname="$(to_lowercase "$1")"
 | 
				
			||||||
 | 
					    if [ ! -z "$osname" ]; then
 | 
				
			||||||
 | 
					        case "$osname" in
 | 
				
			||||||
 | 
					            osx | freebsd | rhel.6 | linux-musl | linux)
 | 
				
			||||||
 | 
					                echo "$osname"
 | 
				
			||||||
 | 
					                return 0
 | 
				
			||||||
 | 
					                ;;
 | 
				
			||||||
 | 
					            *)
 | 
				
			||||||
 | 
					                say_err "'$user_defined_os' is not a supported value for --os option, supported values are: osx, linux, linux-musl, freebsd, rhel.6. If you think this is a bug, report it at https://github.com/dotnet/install-scripts/issues."
 | 
				
			||||||
 | 
					                return 1
 | 
				
			||||||
 | 
					                ;;
 | 
				
			||||||
 | 
					        esac
 | 
				
			||||||
 | 
					    else
 | 
				
			||||||
 | 
					        osname="$(get_current_os_name)" || return 1
 | 
				
			||||||
 | 
					    fi
 | 
				
			||||||
 | 
					    echo "$osname"
 | 
				
			||||||
 | 
					    return 0
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# The version text returned from the feeds is a 1-line or 2-line string:
 | 
					# The version text returned from the feeds is a 1-line or 2-line string:
 | 
				
			||||||
# For the SDK and the dotnet runtime (2 lines):
 | 
					# For the SDK and the dotnet runtime (2 lines):
 | 
				
			||||||
# Line 1: # commit_hash
 | 
					# Line 1: # commit_hash
 | 
				
			||||||
@ -418,14 +409,12 @@ is_dotnet_package_installed() {
 | 
				
			|||||||
# azure_feed - $1
 | 
					# azure_feed - $1
 | 
				
			||||||
# channel - $2
 | 
					# channel - $2
 | 
				
			||||||
# normalized_architecture - $3
 | 
					# normalized_architecture - $3
 | 
				
			||||||
# coherent - $4
 | 
					 | 
				
			||||||
get_latest_version_info() {
 | 
					get_latest_version_info() {
 | 
				
			||||||
    eval $invocation
 | 
					    eval $invocation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    local azure_feed="$1"
 | 
					    local azure_feed="$1"
 | 
				
			||||||
    local channel="$2"
 | 
					    local channel="$2"
 | 
				
			||||||
    local normalized_architecture="$3"
 | 
					    local normalized_architecture="$3"
 | 
				
			||||||
    local coherent="$4"
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    local version_file_url=null
 | 
					    local version_file_url=null
 | 
				
			||||||
    if [[ "$runtime" == "dotnet" ]]; then
 | 
					    if [[ "$runtime" == "dotnet" ]]; then
 | 
				
			||||||
@ -433,11 +422,7 @@ get_latest_version_info() {
 | 
				
			|||||||
    elif [[ "$runtime" == "aspnetcore" ]]; then
 | 
					    elif [[ "$runtime" == "aspnetcore" ]]; then
 | 
				
			||||||
        version_file_url="$uncached_feed/aspnetcore/Runtime/$channel/latest.version"
 | 
					        version_file_url="$uncached_feed/aspnetcore/Runtime/$channel/latest.version"
 | 
				
			||||||
    elif [ -z "$runtime" ]; then
 | 
					    elif [ -z "$runtime" ]; then
 | 
				
			||||||
        if [ "$coherent" = true ]; then
 | 
					 | 
				
			||||||
            version_file_url="$uncached_feed/Sdk/$channel/latest.coherent.version"
 | 
					 | 
				
			||||||
        else
 | 
					 | 
				
			||||||
         version_file_url="$uncached_feed/Sdk/$channel/latest.version"
 | 
					         version_file_url="$uncached_feed/Sdk/$channel/latest.version"
 | 
				
			||||||
        fi
 | 
					 | 
				
			||||||
    else
 | 
					    else
 | 
				
			||||||
        say_err "Invalid value for \$runtime"
 | 
					        say_err "Invalid value for \$runtime"
 | 
				
			||||||
        return 1
 | 
					        return 1
 | 
				
			||||||
@ -468,7 +453,6 @@ parse_jsonfile_for_version() {
 | 
				
			|||||||
    sdk_list=$(echo $sdk_section | awk -F"[{}]" '{print $2}')
 | 
					    sdk_list=$(echo $sdk_section | awk -F"[{}]" '{print $2}')
 | 
				
			||||||
    sdk_list=${sdk_list//[\" ]/}
 | 
					    sdk_list=${sdk_list//[\" ]/}
 | 
				
			||||||
    sdk_list=${sdk_list//,/$'\n'}
 | 
					    sdk_list=${sdk_list//,/$'\n'}
 | 
				
			||||||
    sdk_list="$(echo -e "${sdk_list}" | tr -d '[[:space:]]')"
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    local version_info=""
 | 
					    local version_info=""
 | 
				
			||||||
    while read -r line; do
 | 
					    while read -r line; do
 | 
				
			||||||
@ -505,26 +489,16 @@ get_specific_version_from_version() {
 | 
				
			|||||||
    local json_file="$5"
 | 
					    local json_file="$5"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if [ -z "$json_file" ]; then
 | 
					    if [ -z "$json_file" ]; then
 | 
				
			||||||
        case "$version" in
 | 
					        if [[ "$version" == "latest" ]]; then
 | 
				
			||||||
            latest)
 | 
					 | 
				
			||||||
            local version_info
 | 
					            local version_info
 | 
				
			||||||
            version_info="$(get_latest_version_info "$azure_feed" "$channel" "$normalized_architecture" false)" || return 1
 | 
					            version_info="$(get_latest_version_info "$azure_feed" "$channel" "$normalized_architecture" false)" || return 1
 | 
				
			||||||
            say_verbose "get_specific_version_from_version: version_info=$version_info"
 | 
					            say_verbose "get_specific_version_from_version: version_info=$version_info"
 | 
				
			||||||
            echo "$version_info" | get_version_from_version_info
 | 
					            echo "$version_info" | get_version_from_version_info
 | 
				
			||||||
            return 0
 | 
					            return 0
 | 
				
			||||||
                ;;
 | 
					        else
 | 
				
			||||||
            coherent)
 | 
					 | 
				
			||||||
                local version_info
 | 
					 | 
				
			||||||
                version_info="$(get_latest_version_info "$azure_feed" "$channel" "$normalized_architecture" true)" || return 1
 | 
					 | 
				
			||||||
                say_verbose "get_specific_version_from_version: version_info=$version_info"
 | 
					 | 
				
			||||||
                echo "$version_info" | get_version_from_version_info
 | 
					 | 
				
			||||||
                return 0
 | 
					 | 
				
			||||||
                ;;
 | 
					 | 
				
			||||||
            *)
 | 
					 | 
				
			||||||
            echo "$version"
 | 
					            echo "$version"
 | 
				
			||||||
            return 0
 | 
					            return 0
 | 
				
			||||||
                ;;
 | 
					        fi
 | 
				
			||||||
        esac
 | 
					 | 
				
			||||||
    else
 | 
					    else
 | 
				
			||||||
        local version_info
 | 
					        local version_info
 | 
				
			||||||
        version_info="$(parse_jsonfile_for_version "$json_file")" || return 1
 | 
					        version_info="$(parse_jsonfile_for_version "$json_file")" || return 1
 | 
				
			||||||
@ -538,6 +512,7 @@ get_specific_version_from_version() {
 | 
				
			|||||||
# channel - $2
 | 
					# channel - $2
 | 
				
			||||||
# normalized_architecture - $3
 | 
					# normalized_architecture - $3
 | 
				
			||||||
# specific_version - $4
 | 
					# specific_version - $4
 | 
				
			||||||
 | 
					# normalized_os - $5
 | 
				
			||||||
construct_download_link() {
 | 
					construct_download_link() {
 | 
				
			||||||
    eval $invocation
 | 
					    eval $invocation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -545,17 +520,16 @@ construct_download_link() {
 | 
				
			|||||||
    local channel="$2"
 | 
					    local channel="$2"
 | 
				
			||||||
    local normalized_architecture="$3"
 | 
					    local normalized_architecture="$3"
 | 
				
			||||||
    local specific_version="${4//[$'\t\r\n']}"
 | 
					    local specific_version="${4//[$'\t\r\n']}"
 | 
				
			||||||
 | 
					    local specific_product_version="$(get_specific_product_version "$1" "$4")"
 | 
				
			||||||
    local osname
 | 
					    local osname="$5"
 | 
				
			||||||
    osname="$(get_current_os_name)" || return 1
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    local download_link=null
 | 
					    local download_link=null
 | 
				
			||||||
    if [[ "$runtime" == "dotnet" ]]; then
 | 
					    if [[ "$runtime" == "dotnet" ]]; then
 | 
				
			||||||
        download_link="$azure_feed/Runtime/$specific_version/dotnet-runtime-$specific_version-$osname-$normalized_architecture.tar.gz"
 | 
					        download_link="$azure_feed/Runtime/$specific_version/dotnet-runtime-$specific_product_version-$osname-$normalized_architecture.tar.gz"
 | 
				
			||||||
    elif [[ "$runtime" == "aspnetcore" ]]; then
 | 
					    elif [[ "$runtime" == "aspnetcore" ]]; then
 | 
				
			||||||
        download_link="$azure_feed/aspnetcore/Runtime/$specific_version/aspnetcore-runtime-$specific_version-$osname-$normalized_architecture.tar.gz"
 | 
					        download_link="$azure_feed/aspnetcore/Runtime/$specific_version/aspnetcore-runtime-$specific_product_version-$osname-$normalized_architecture.tar.gz"
 | 
				
			||||||
    elif [ -z "$runtime" ]; then
 | 
					    elif [ -z "$runtime" ]; then
 | 
				
			||||||
        download_link="$azure_feed/Sdk/$specific_version/dotnet-sdk-$specific_version-$osname-$normalized_architecture.tar.gz"
 | 
					        download_link="$azure_feed/Sdk/$specific_version/dotnet-sdk-$specific_product_version-$osname-$normalized_architecture.tar.gz"
 | 
				
			||||||
    else
 | 
					    else
 | 
				
			||||||
        return 1
 | 
					        return 1
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
@ -564,6 +538,50 @@ construct_download_link() {
 | 
				
			|||||||
    return 0
 | 
					    return 0
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# args:
 | 
				
			||||||
 | 
					# azure_feed - $1
 | 
				
			||||||
 | 
					# specific_version - $2
 | 
				
			||||||
 | 
					get_specific_product_version() {
 | 
				
			||||||
 | 
					    # If we find a 'productVersion.txt' at the root of any folder, we'll use its contents
 | 
				
			||||||
 | 
					    # to resolve the version of what's in the folder, superseding the specified version.
 | 
				
			||||||
 | 
					    eval $invocation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    local azure_feed="$1"
 | 
				
			||||||
 | 
					    local specific_version="${2//[$'\t\r\n']}"
 | 
				
			||||||
 | 
					    local specific_product_version=$specific_version
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    local download_link=null
 | 
				
			||||||
 | 
					    if [[ "$runtime" == "dotnet" ]]; then
 | 
				
			||||||
 | 
					        download_link="$azure_feed/Runtime/$specific_version/productVersion.txt${feed_credential}"
 | 
				
			||||||
 | 
					    elif [[ "$runtime" == "aspnetcore" ]]; then
 | 
				
			||||||
 | 
					        download_link="$azure_feed/aspnetcore/Runtime/$specific_version/productVersion.txt${feed_credential}"
 | 
				
			||||||
 | 
					    elif [ -z "$runtime" ]; then
 | 
				
			||||||
 | 
					        download_link="$azure_feed/Sdk/$specific_version/productVersion.txt${feed_credential}"
 | 
				
			||||||
 | 
					    else
 | 
				
			||||||
 | 
					        return 1
 | 
				
			||||||
 | 
					    fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    if machine_has "curl"
 | 
				
			||||||
 | 
					    then
 | 
				
			||||||
 | 
					        specific_product_version=$(curl -s --fail "$download_link")
 | 
				
			||||||
 | 
					        if [ $? -ne 0 ]
 | 
				
			||||||
 | 
					        then
 | 
				
			||||||
 | 
					            specific_product_version=$specific_version
 | 
				
			||||||
 | 
					        fi
 | 
				
			||||||
 | 
					    elif machine_has "wget"
 | 
				
			||||||
 | 
					    then
 | 
				
			||||||
 | 
					        specific_product_version=$(wget -qO- "$download_link")
 | 
				
			||||||
 | 
					        if [ $? -ne 0 ]
 | 
				
			||||||
 | 
					        then
 | 
				
			||||||
 | 
					            specific_product_version=$specific_version
 | 
				
			||||||
 | 
					        fi
 | 
				
			||||||
 | 
					    fi
 | 
				
			||||||
 | 
					    specific_product_version="${specific_product_version//[$'\t\r\n']}"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    echo "$specific_product_version"
 | 
				
			||||||
 | 
					    return 0
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# args:
 | 
					# args:
 | 
				
			||||||
# azure_feed - $1
 | 
					# azure_feed - $1
 | 
				
			||||||
# channel - $2
 | 
					# channel - $2
 | 
				
			||||||
@ -684,11 +702,31 @@ extract_dotnet_package() {
 | 
				
			|||||||
    find "$temp_out_path" -type f | grep -Ev "$folders_with_version_regex" | copy_files_or_dirs_from_list "$temp_out_path" "$out_path" "$override_non_versioned_files"
 | 
					    find "$temp_out_path" -type f | grep -Ev "$folders_with_version_regex" | copy_files_or_dirs_from_list "$temp_out_path" "$out_path" "$override_non_versioned_files"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    rm -rf "$temp_out_path"
 | 
					    rm -rf "$temp_out_path"
 | 
				
			||||||
 | 
					    rm -f "$zip_path" && say_verbose "Temporary zip file $zip_path was removed"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if [ "$failed" = true ]; then
 | 
					    if [ "$failed" = true ]; then
 | 
				
			||||||
        say_err "Extraction failed"
 | 
					        say_err "Extraction failed"
 | 
				
			||||||
        return 1
 | 
					        return 1
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
 | 
					    return 0
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					get_http_header_curl() {
 | 
				
			||||||
 | 
					    eval $invocation
 | 
				
			||||||
 | 
					    local remote_path="$1"
 | 
				
			||||||
 | 
					    remote_path_with_credential="${remote_path}${feed_credential}"
 | 
				
			||||||
 | 
					    curl_options="-I -sSL --retry 5 --retry-delay 2 --connect-timeout 15 "
 | 
				
			||||||
 | 
					    curl $curl_options "$remote_path_with_credential" || return 1
 | 
				
			||||||
 | 
					    return 0
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					get_http_header_wget() {
 | 
				
			||||||
 | 
					    eval $invocation
 | 
				
			||||||
 | 
					    local remote_path="$1"
 | 
				
			||||||
 | 
					    remote_path_with_credential="${remote_path}${feed_credential}"
 | 
				
			||||||
 | 
					    wget_options="-q -S --spider --tries 5 --waitretry 2 --connect-timeout 15 "
 | 
				
			||||||
 | 
					    wget $wget_options "$remote_path_with_credential" 2>&1 || return 1
 | 
				
			||||||
 | 
					    return 0
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# args:
 | 
					# args:
 | 
				
			||||||
@ -706,13 +744,30 @@ download() {
 | 
				
			|||||||
    fi
 | 
					    fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    local failed=false
 | 
					    local failed=false
 | 
				
			||||||
 | 
					    local attempts=0
 | 
				
			||||||
 | 
					    while [ $attempts -lt 3 ]; do
 | 
				
			||||||
 | 
					        attempts=$((attempts+1))
 | 
				
			||||||
 | 
					        failed=false
 | 
				
			||||||
        if machine_has "curl"; then
 | 
					        if machine_has "curl"; then
 | 
				
			||||||
            downloadcurl "$remote_path" "$out_path" || failed=true
 | 
					            downloadcurl "$remote_path" "$out_path" || failed=true
 | 
				
			||||||
        elif machine_has "wget"; then
 | 
					        elif machine_has "wget"; then
 | 
				
			||||||
            downloadwget "$remote_path" "$out_path" || failed=true
 | 
					            downloadwget "$remote_path" "$out_path" || failed=true
 | 
				
			||||||
        else
 | 
					        else
 | 
				
			||||||
        failed=true
 | 
					            say_err "Missing dependency: neither curl nor wget was found."
 | 
				
			||||||
 | 
					            exit 1
 | 
				
			||||||
        fi
 | 
					        fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        if [ "$failed" = false ] || [ $attempts -ge 3 ] || { [ ! -z $http_code ] && [ $http_code = "404" ]; }; then
 | 
				
			||||||
 | 
					            break
 | 
				
			||||||
 | 
					        fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        say "Download attempt #$attempts has failed: $http_code $download_error_msg"
 | 
				
			||||||
 | 
					        say "Attempt #$((attempts+1)) will start in $((attempts*10)) seconds."
 | 
				
			||||||
 | 
					        sleep $((attempts*20))
 | 
				
			||||||
 | 
					    done
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if [ "$failed" = true ]; then
 | 
					    if [ "$failed" = true ]; then
 | 
				
			||||||
        say_verbose "Download failed: $remote_path"
 | 
					        say_verbose "Download failed: $remote_path"
 | 
				
			||||||
        return 1
 | 
					        return 1
 | 
				
			||||||
@ -720,44 +775,60 @@ download() {
 | 
				
			|||||||
    return 0
 | 
					    return 0
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Updates global variables $http_code and $download_error_msg
 | 
				
			||||||
downloadcurl() {
 | 
					downloadcurl() {
 | 
				
			||||||
    eval $invocation
 | 
					    eval $invocation
 | 
				
			||||||
 | 
					    unset http_code
 | 
				
			||||||
 | 
					    unset download_error_msg
 | 
				
			||||||
    local remote_path="$1"
 | 
					    local remote_path="$1"
 | 
				
			||||||
    local out_path="${2:-}"
 | 
					    local out_path="${2:-}"
 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Append feed_credential as late as possible before calling curl to avoid logging feed_credential
 | 
					    # Append feed_credential as late as possible before calling curl to avoid logging feed_credential
 | 
				
			||||||
    remote_path="${remote_path}${feed_credential}"
 | 
					    local remote_path_with_credential="${remote_path}${feed_credential}"
 | 
				
			||||||
 | 
					 | 
				
			||||||
    local curl_options="--retry 20 --retry-delay 2 --connect-timeout 15 -sSL -f --create-dirs "
 | 
					    local curl_options="--retry 20 --retry-delay 2 --connect-timeout 15 -sSL -f --create-dirs "
 | 
				
			||||||
    local failed=false
 | 
					    local failed=false
 | 
				
			||||||
    if [ -z "$out_path" ]; then
 | 
					    if [ -z "$out_path" ]; then
 | 
				
			||||||
        curl $curl_options "$remote_path" || failed=true
 | 
					        curl $curl_options "$remote_path_with_credential" || failed=true
 | 
				
			||||||
    else
 | 
					    else
 | 
				
			||||||
        curl $curl_options -o "$out_path" "$remote_path" || failed=true
 | 
					        curl $curl_options -o "$out_path" "$remote_path_with_credential" || failed=true
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
    if [ "$failed" = true ]; then
 | 
					    if [ "$failed" = true ]; then
 | 
				
			||||||
        say_verbose "Curl download failed"
 | 
					        local response=$(get_http_header_curl $remote_path_with_credential)
 | 
				
			||||||
 | 
					        http_code=$( echo "$response" | awk '/^HTTP/{print $2}' | tail -1 )
 | 
				
			||||||
 | 
					        download_error_msg="Unable to download $remote_path."
 | 
				
			||||||
 | 
					        if  [[ $http_code != 2* ]]; then
 | 
				
			||||||
 | 
					            download_error_msg+=" Returned HTTP status code: $http_code."
 | 
				
			||||||
 | 
					        fi
 | 
				
			||||||
 | 
					        say_verbose "$download_error_msg"
 | 
				
			||||||
        return 1
 | 
					        return 1
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
    return 0
 | 
					    return 0
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Updates global variables $http_code and $download_error_msg
 | 
				
			||||||
downloadwget() {
 | 
					downloadwget() {
 | 
				
			||||||
    eval $invocation
 | 
					    eval $invocation
 | 
				
			||||||
 | 
					    unset http_code
 | 
				
			||||||
 | 
					    unset download_error_msg
 | 
				
			||||||
    local remote_path="$1"
 | 
					    local remote_path="$1"
 | 
				
			||||||
    local out_path="${2:-}"
 | 
					    local out_path="${2:-}"
 | 
				
			||||||
 | 
					 | 
				
			||||||
    # Append feed_credential as late as possible before calling wget to avoid logging feed_credential
 | 
					    # Append feed_credential as late as possible before calling wget to avoid logging feed_credential
 | 
				
			||||||
    remote_path="${remote_path}${feed_credential}"
 | 
					    local remote_path_with_credential="${remote_path}${feed_credential}"
 | 
				
			||||||
    local wget_options="--tries 20 --waitretry 2 --connect-timeout 15 "
 | 
					    local wget_options="--tries 20 --waitretry 2 --connect-timeout 15 "
 | 
				
			||||||
    local failed=false
 | 
					    local failed=false
 | 
				
			||||||
    if [ -z "$out_path" ]; then
 | 
					    if [ -z "$out_path" ]; then
 | 
				
			||||||
        wget -q $wget_options -O - "$remote_path" || failed=true
 | 
					        wget -q $wget_options -O - "$remote_path_with_credential" || failed=true
 | 
				
			||||||
    else
 | 
					    else
 | 
				
			||||||
        wget $wget_options -O "$out_path" "$remote_path" || failed=true
 | 
					        wget $wget_options -O "$out_path" "$remote_path_with_credential" || failed=true
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
    if [ "$failed" = true ]; then
 | 
					    if [ "$failed" = true ]; then
 | 
				
			||||||
        say_verbose "Wget download failed"
 | 
					        local response=$(get_http_header_wget $remote_path_with_credential)
 | 
				
			||||||
 | 
					        http_code=$( echo "$response" | awk '/^  HTTP/{print $2}' | tail -1 )
 | 
				
			||||||
 | 
					        download_error_msg="Unable to download $remote_path."
 | 
				
			||||||
 | 
					        if  [[ $http_code != 2* ]]; then
 | 
				
			||||||
 | 
					            download_error_msg+=" Returned HTTP status code: $http_code."
 | 
				
			||||||
 | 
					        fi
 | 
				
			||||||
 | 
					        say_verbose "$download_error_msg"
 | 
				
			||||||
        return 1
 | 
					        return 1
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
    return 0
 | 
					    return 0
 | 
				
			||||||
@ -770,14 +841,18 @@ calculate_vars() {
 | 
				
			|||||||
    normalized_architecture="$(get_normalized_architecture_from_architecture "$architecture")"
 | 
					    normalized_architecture="$(get_normalized_architecture_from_architecture "$architecture")"
 | 
				
			||||||
    say_verbose "normalized_architecture=$normalized_architecture"
 | 
					    say_verbose "normalized_architecture=$normalized_architecture"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    normalized_os="$(get_normalized_os "$user_defined_os")"
 | 
				
			||||||
 | 
					    say_verbose "normalized_os=$normalized_os"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    specific_version="$(get_specific_version_from_version "$azure_feed" "$channel" "$normalized_architecture" "$version" "$json_file")"
 | 
					    specific_version="$(get_specific_version_from_version "$azure_feed" "$channel" "$normalized_architecture" "$version" "$json_file")"
 | 
				
			||||||
 | 
					    specific_product_version="$(get_specific_product_version "$azure_feed" "$specific_version")"
 | 
				
			||||||
    say_verbose "specific_version=$specific_version"
 | 
					    say_verbose "specific_version=$specific_version"
 | 
				
			||||||
    if [ -z "$specific_version" ]; then
 | 
					    if [ -z "$specific_version" ]; then
 | 
				
			||||||
        say_err "Could not resolve version information."
 | 
					        say_err "Could not resolve version information."
 | 
				
			||||||
        return 1
 | 
					        return 1
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    download_link="$(construct_download_link "$azure_feed" "$channel" "$normalized_architecture" "$specific_version")"
 | 
					    download_link="$(construct_download_link "$azure_feed" "$channel" "$normalized_architecture" "$specific_version" "$normalized_os")"
 | 
				
			||||||
    say_verbose "Constructed primary named payload URL: $download_link"
 | 
					    say_verbose "Constructed primary named payload URL: $download_link"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    legacy_download_link="$(construct_legacy_download_link "$azure_feed" "$channel" "$normalized_architecture" "$specific_version")" || valid_legacy_download_link=false
 | 
					    legacy_download_link="$(construct_legacy_download_link "$azure_feed" "$channel" "$normalized_architecture" "$specific_version")" || valid_legacy_download_link=false
 | 
				
			||||||
@ -822,38 +897,74 @@ install_dotnet() {
 | 
				
			|||||||
    zip_path="$(mktemp "$temporary_file_template")"
 | 
					    zip_path="$(mktemp "$temporary_file_template")"
 | 
				
			||||||
    say_verbose "Zip path: $zip_path"
 | 
					    say_verbose "Zip path: $zip_path"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    say "Downloading link: $download_link"
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    # Failures are normal in the non-legacy case for ultimately legacy downloads.
 | 
					    # Failures are normal in the non-legacy case for ultimately legacy downloads.
 | 
				
			||||||
    # Do not output to stderr, since output to stderr is considered an error.
 | 
					    # Do not output to stderr, since output to stderr is considered an error.
 | 
				
			||||||
 | 
					    say "Downloading primary link $download_link"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    # The download function will set variables $http_code and $download_error_msg in case of failure.
 | 
				
			||||||
    download "$download_link" "$zip_path" 2>&1 || download_failed=true
 | 
					    download "$download_link" "$zip_path" 2>&1 || download_failed=true
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    #  if the download fails, download the legacy_download_link
 | 
					    #  if the download fails, download the legacy_download_link
 | 
				
			||||||
    if [ "$download_failed" = true ]; then
 | 
					    if [ "$download_failed" = true ]; then
 | 
				
			||||||
        say "Cannot download: $download_link"
 | 
					        primary_path_http_code="$http_code"; primary_path_download_error_msg="$download_error_msg"
 | 
				
			||||||
 | 
					        case $primary_path_http_code in
 | 
				
			||||||
 | 
					        404)
 | 
				
			||||||
 | 
					            say "The resource at $download_link is not available."
 | 
				
			||||||
 | 
					            ;;
 | 
				
			||||||
 | 
					        *)
 | 
				
			||||||
 | 
					            say "$primary_path_download_error_msg"
 | 
				
			||||||
 | 
					            ;;
 | 
				
			||||||
 | 
					        esac
 | 
				
			||||||
 | 
					        rm -f "$zip_path" 2>&1 && say_verbose "Temporary zip file $zip_path was removed"
 | 
				
			||||||
        if [ "$valid_legacy_download_link" = true ]; then
 | 
					        if [ "$valid_legacy_download_link" = true ]; then
 | 
				
			||||||
            download_failed=false
 | 
					            download_failed=false
 | 
				
			||||||
            download_link="$legacy_download_link"
 | 
					            download_link="$legacy_download_link"
 | 
				
			||||||
            zip_path="$(mktemp "$temporary_file_template")"
 | 
					            zip_path="$(mktemp "$temporary_file_template")"
 | 
				
			||||||
            say_verbose "Legacy zip path: $zip_path"
 | 
					            say_verbose "Legacy zip path: $zip_path"
 | 
				
			||||||
            say "Downloading legacy link: $download_link"
 | 
					
 | 
				
			||||||
 | 
					            say "Downloading legacy link $download_link"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            # The download function will set variables $http_code and $download_error_msg in case of failure.
 | 
				
			||||||
            download "$download_link" "$zip_path" 2>&1 || download_failed=true
 | 
					            download "$download_link" "$zip_path" 2>&1 || download_failed=true
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            if [ "$download_failed" = true ]; then
 | 
					            if [ "$download_failed" = true ]; then
 | 
				
			||||||
                say "Cannot download: $download_link"
 | 
					                legacy_path_http_code="$http_code";  legacy_path_download_error_msg="$download_error_msg"
 | 
				
			||||||
 | 
					                case $legacy_path_http_code in
 | 
				
			||||||
 | 
					                404)
 | 
				
			||||||
 | 
					                    say "The resource at $download_link is not available."
 | 
				
			||||||
 | 
					                    ;;
 | 
				
			||||||
 | 
					                *)
 | 
				
			||||||
 | 
					                    say "$legacy_path_download_error_msg"
 | 
				
			||||||
 | 
					                    ;;
 | 
				
			||||||
 | 
					                esac
 | 
				
			||||||
 | 
					                rm -f "$zip_path" 2>&1 && say_verbose "Temporary zip file $zip_path was removed"
 | 
				
			||||||
            fi
 | 
					            fi
 | 
				
			||||||
        fi
 | 
					        fi
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if [ "$download_failed" = true ]; then
 | 
					    if [ "$download_failed" = true ]; then
 | 
				
			||||||
        say_err "Could not find/download: \`$asset_name\` with version = $specific_version"
 | 
					        if [[ "$primary_path_http_code" = "404" && ( "$valid_legacy_download_link" = false || "$legacy_path_http_code" = "404") ]]; then
 | 
				
			||||||
 | 
					            say_err "Could not find \`$asset_name\` with version = $specific_version"
 | 
				
			||||||
            say_err "Refer to: https://aka.ms/dotnet-os-lifecycle for information on .NET Core support"
 | 
					            say_err "Refer to: https://aka.ms/dotnet-os-lifecycle for information on .NET Core support"
 | 
				
			||||||
 | 
					        else
 | 
				
			||||||
 | 
					            say_err "Could not download: \`$asset_name\` with version = $specific_version"
 | 
				
			||||||
 | 
					            # 404-NotFound is an expected response if it goes from only one of the links, do not show that error.
 | 
				
			||||||
 | 
					            # If primary path is available (not 404-NotFound) then show the primary error else show the legacy error.
 | 
				
			||||||
 | 
					            if [ "$primary_path_http_code" != "404" ]; then
 | 
				
			||||||
 | 
					                say_err "$primary_path_download_error_msg"
 | 
				
			||||||
 | 
					                return 1
 | 
				
			||||||
 | 
					            fi
 | 
				
			||||||
 | 
					            if [[ "$valid_legacy_download_link" = true  && "$legacy_path_http_code" != "404" ]]; then
 | 
				
			||||||
 | 
					                say_err "$legacy_path_download_error_msg"
 | 
				
			||||||
 | 
					                return 1
 | 
				
			||||||
 | 
					            fi
 | 
				
			||||||
 | 
					        fi
 | 
				
			||||||
        return 1
 | 
					        return 1
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    say "Extracting zip from $download_link"
 | 
					    say "Extracting zip from $download_link"
 | 
				
			||||||
    extract_dotnet_package "$zip_path" "$install_root"
 | 
					    extract_dotnet_package "$zip_path" "$install_root" || return 1
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    #  Check if the SDK version is installed; if not, fail the installation.
 | 
					    #  Check if the SDK version is installed; if not, fail the installation.
 | 
				
			||||||
    # if the version contains "RTM" or "servicing"; check if a 'release-type' SDK version is installed.
 | 
					    # if the version contains "RTM" or "servicing"; check if a 'release-type' SDK version is installed.
 | 
				
			||||||
@ -869,12 +980,14 @@ install_dotnet() {
 | 
				
			|||||||
    fi
 | 
					    fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    #  Check if the standard SDK version is installed.
 | 
					    #  Check if the standard SDK version is installed.
 | 
				
			||||||
    say_verbose "Checking installation: version = $specific_version"
 | 
					    say_verbose "Checking installation: version = $specific_product_version"
 | 
				
			||||||
    if is_dotnet_package_installed "$install_root" "$asset_relative_path" "$specific_version"; then
 | 
					    if is_dotnet_package_installed "$install_root" "$asset_relative_path" "$specific_product_version"; then
 | 
				
			||||||
        return 0
 | 
					        return 0
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    say_err "\`$asset_name\` with version = $specific_version failed to install with an unknown error."
 | 
					    # Version verification failed. More likely something is wrong either with the downloaded content or with the verification algorithm.
 | 
				
			||||||
 | 
					    say_err "Failed to verify the version of installed \`$asset_name\`.\nInstallation source: $download_link.\nInstallation location: $install_root.\nReport the bug at https://github.com/dotnet/install-scripts/issues."
 | 
				
			||||||
 | 
					    say_err "\`$asset_name\` with version = $specific_product_version failed to install with an unknown error."
 | 
				
			||||||
    return 1
 | 
					    return 1
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -900,6 +1013,7 @@ runtime=""
 | 
				
			|||||||
runtime_id=""
 | 
					runtime_id=""
 | 
				
			||||||
override_non_versioned_files=true
 | 
					override_non_versioned_files=true
 | 
				
			||||||
non_dynamic_parameters=""
 | 
					non_dynamic_parameters=""
 | 
				
			||||||
 | 
					user_defined_os=""
 | 
				
			||||||
 | 
					
 | 
				
			||||||
while [ $# -ne 0 ]
 | 
					while [ $# -ne 0 ]
 | 
				
			||||||
do
 | 
					do
 | 
				
			||||||
@ -921,6 +1035,10 @@ do
 | 
				
			|||||||
            shift
 | 
					            shift
 | 
				
			||||||
            architecture="$1"
 | 
					            architecture="$1"
 | 
				
			||||||
            ;;
 | 
					            ;;
 | 
				
			||||||
 | 
					        --os|-[Oo][SS])
 | 
				
			||||||
 | 
					            shift
 | 
				
			||||||
 | 
					            user_defined_os="$1"
 | 
				
			||||||
 | 
					            ;;
 | 
				
			||||||
        --shared-runtime|-[Ss]hared[Rr]untime)
 | 
					        --shared-runtime|-[Ss]hared[Rr]untime)
 | 
				
			||||||
            say_warning "The --shared-runtime flag is obsolete and may be removed in a future version of this script. The recommended usage is to specify '--runtime dotnet'."
 | 
					            say_warning "The --shared-runtime flag is obsolete and may be removed in a future version of this script. The recommended usage is to specify '--runtime dotnet'."
 | 
				
			||||||
            if [ -z "$runtime" ]; then
 | 
					            if [ -z "$runtime" ]; then
 | 
				
			||||||
@ -972,6 +1090,7 @@ do
 | 
				
			|||||||
            shift
 | 
					            shift
 | 
				
			||||||
            runtime_id="$1"
 | 
					            runtime_id="$1"
 | 
				
			||||||
            non_dynamic_parameters+=" $name "\""$1"\"""
 | 
					            non_dynamic_parameters+=" $name "\""$1"\"""
 | 
				
			||||||
 | 
					            say_warning "Use of --runtime-id is obsolete and should be limited to the versions below 2.1. To override architecture, use --architecture option instead. To override OS, use --os option instead."
 | 
				
			||||||
            ;;
 | 
					            ;;
 | 
				
			||||||
        --jsonfile|-[Jj][Ss]on[Ff]ile)
 | 
					        --jsonfile|-[Jj][Ss]on[Ff]ile)
 | 
				
			||||||
            shift
 | 
					            shift
 | 
				
			||||||
@ -1004,8 +1123,6 @@ do
 | 
				
			|||||||
            echo "      -Version"
 | 
					            echo "      -Version"
 | 
				
			||||||
            echo "          Possible values:"
 | 
					            echo "          Possible values:"
 | 
				
			||||||
            echo "          - latest - most latest build on specific channel"
 | 
					            echo "          - latest - most latest build on specific channel"
 | 
				
			||||||
            echo "          - coherent - most latest coherent build on specific channel"
 | 
					 | 
				
			||||||
            echo "              coherent applies only to SDK downloads"
 | 
					 | 
				
			||||||
            echo "          - 3-part version in a format A.B.C - represents specific version of build"
 | 
					            echo "          - 3-part version in a format A.B.C - represents specific version of build"
 | 
				
			||||||
            echo "              examples: 2.0.0-preview2-006120; 1.1.0"
 | 
					            echo "              examples: 2.0.0-preview2-006120; 1.1.0"
 | 
				
			||||||
            echo "  -i,--install-dir <DIR>             Install under specified location (see Install Location below)"
 | 
					            echo "  -i,--install-dir <DIR>             Install under specified location (see Install Location below)"
 | 
				
			||||||
@ -1013,6 +1130,11 @@ do
 | 
				
			|||||||
            echo "  --architecture <ARCHITECTURE>      Architecture of dotnet binaries to be installed, Defaults to \`$architecture\`."
 | 
					            echo "  --architecture <ARCHITECTURE>      Architecture of dotnet binaries to be installed, Defaults to \`$architecture\`."
 | 
				
			||||||
            echo "      --arch,-Architecture,-Arch"
 | 
					            echo "      --arch,-Architecture,-Arch"
 | 
				
			||||||
            echo "          Possible values: x64, arm, and arm64"
 | 
					            echo "          Possible values: x64, arm, and arm64"
 | 
				
			||||||
 | 
					            echo "  --os <system>                    Specifies operating system to be used when selecting the installer."
 | 
				
			||||||
 | 
					            echo "          Overrides the OS determination approach used by the script. Supported values: osx, linux, linux-musl, freebsd, rhel.6."
 | 
				
			||||||
 | 
					            echo "          In case any other value is provided, the platform will be determined by the script based on machine configuration."
 | 
				
			||||||
 | 
					            echo "          Not supported for legacy links. Use --runtime-id to specify platform for legacy links."
 | 
				
			||||||
 | 
					            echo "          Refer to: https://aka.ms/dotnet-os-lifecycle for more information."
 | 
				
			||||||
            echo "  --runtime <RUNTIME>                Installs a shared runtime only, without the SDK."
 | 
					            echo "  --runtime <RUNTIME>                Installs a shared runtime only, without the SDK."
 | 
				
			||||||
            echo "      -Runtime"
 | 
					            echo "      -Runtime"
 | 
				
			||||||
            echo "          Possible values:"
 | 
					            echo "          Possible values:"
 | 
				
			||||||
@ -1029,14 +1151,15 @@ do
 | 
				
			|||||||
            echo "  --no-cdn,-NoCdn                    Disable downloading from the Azure CDN, and use the uncached feed directly."
 | 
					            echo "  --no-cdn,-NoCdn                    Disable downloading from the Azure CDN, and use the uncached feed directly."
 | 
				
			||||||
            echo "  --jsonfile <JSONFILE>              Determines the SDK version from a user specified global.json file."
 | 
					            echo "  --jsonfile <JSONFILE>              Determines the SDK version from a user specified global.json file."
 | 
				
			||||||
            echo "                                     Note: global.json must have a value for 'SDK:Version'"
 | 
					            echo "                                     Note: global.json must have a value for 'SDK:Version'"
 | 
				
			||||||
            echo "  --runtime-id                       Installs the .NET Tools for the given platform (use linux-x64 for portable linux)."
 | 
					 | 
				
			||||||
            echo "      -RuntimeId"
 | 
					 | 
				
			||||||
            echo "  -?,--?,-h,--help,-Help             Shows this help message"
 | 
					            echo "  -?,--?,-h,--help,-Help             Shows this help message"
 | 
				
			||||||
            echo ""
 | 
					            echo ""
 | 
				
			||||||
            echo "Obsolete parameters:"
 | 
					            echo "Obsolete parameters:"
 | 
				
			||||||
            echo "  --shared-runtime                   The recommended alternative is '--runtime dotnet'."
 | 
					            echo "  --shared-runtime                   The recommended alternative is '--runtime dotnet'."
 | 
				
			||||||
            echo "                                     This parameter is obsolete and may be removed in a future version of this script."
 | 
					            echo "                                     This parameter is obsolete and may be removed in a future version of this script."
 | 
				
			||||||
            echo "                                     Installs just the shared runtime bits, not the entire SDK."
 | 
					            echo "                                     Installs just the shared runtime bits, not the entire SDK."
 | 
				
			||||||
 | 
					            echo "  --runtime-id                       Installs the .NET Tools for the given platform (use linux-x64 for portable linux)."
 | 
				
			||||||
 | 
					            echo "      -RuntimeId"                    The parameter is obsolete and may be removed in a future version of this script. Should be used only for versions below 2.1.
 | 
				
			||||||
 | 
					            echo "                                     For primary links to override OS or/and architecture, use --os and --architecture option instead."
 | 
				
			||||||
            echo ""
 | 
					            echo ""
 | 
				
			||||||
            echo "Install Location:"
 | 
					            echo "Install Location:"
 | 
				
			||||||
            echo "  Location is chosen in following order:"
 | 
					            echo "  Location is chosen in following order:"
 | 
				
			||||||
@ -1058,6 +1181,11 @@ if [ "$no_cdn" = true ]; then
 | 
				
			|||||||
    azure_feed="$uncached_feed"
 | 
					    azure_feed="$uncached_feed"
 | 
				
			||||||
fi
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					say "Note that the intended use of this script is for Continuous Integration (CI) scenarios, where:"
 | 
				
			||||||
 | 
					say "- The SDK needs to be installed without user interaction and without admin rights."
 | 
				
			||||||
 | 
					say "- The SDK installation doesn't need to persist across multiple CI runs."
 | 
				
			||||||
 | 
					say "To set up a development environment or to run apps, use installers rather than this script. Visit https://dotnet.microsoft.com/download to get the installer.\n"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
check_min_reqs
 | 
					check_min_reqs
 | 
				
			||||||
calculate_vars
 | 
					calculate_vars
 | 
				
			||||||
script_name=$(basename "$0")
 | 
					script_name=$(basename "$0")
 | 
				
			||||||
@ -1068,7 +1196,7 @@ if [ "$dry_run" = true ]; then
 | 
				
			|||||||
    if [ "$valid_legacy_download_link" = true ]; then
 | 
					    if [ "$valid_legacy_download_link" = true ]; then
 | 
				
			||||||
        say "Legacy named payload URL: $legacy_download_link"
 | 
					        say "Legacy named payload URL: $legacy_download_link"
 | 
				
			||||||
    fi
 | 
					    fi
 | 
				
			||||||
    repeatable_command="./$script_name --version "\""$specific_version"\"" --install-dir "\""$install_root"\"" --architecture "\""$normalized_architecture"\"""
 | 
					    repeatable_command="./$script_name --version "\""$specific_version"\"" --install-dir "\""$install_root"\"" --architecture "\""$normalized_architecture"\"" --os "\""$normalized_os"\"""
 | 
				
			||||||
    if [[ "$runtime" == "dotnet" ]]; then
 | 
					    if [[ "$runtime" == "dotnet" ]]; then
 | 
				
			||||||
        repeatable_command+=" --runtime "\""dotnet"\"""
 | 
					        repeatable_command+=" --runtime "\""dotnet"\"""
 | 
				
			||||||
    elif [[ "$runtime" == "aspnetcore" ]]; then
 | 
					    elif [[ "$runtime" == "aspnetcore" ]]; then
 | 
				
			||||||
@ -1079,7 +1207,6 @@ if [ "$dry_run" = true ]; then
 | 
				
			|||||||
    exit 0
 | 
					    exit 0
 | 
				
			||||||
fi
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
check_pre_reqs
 | 
					 | 
				
			||||||
install_dotnet
 | 
					install_dotnet
 | 
				
			||||||
 | 
					
 | 
				
			||||||
bin_path="$(get_absolute_path "$(combine_paths "$install_root" "$bin_folder_relative_path")")"
 | 
					bin_path="$(get_absolute_path "$(combine_paths "$install_root" "$bin_folder_relative_path")")"
 | 
				
			||||||
@ -1090,4 +1217,6 @@ else
 | 
				
			|||||||
    say "Binaries of dotnet can be found in $bin_path"
 | 
					    say "Binaries of dotnet can be found in $bin_path"
 | 
				
			||||||
fi
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					say "Note that the script does not resolve dependencies during installation."
 | 
				
			||||||
 | 
					say "To check the list of dependencies, go to https://docs.microsoft.com/dotnet/core/install, select your operating system and check the \"Dependencies\" section."
 | 
				
			||||||
say "Installation finished successfully."
 | 
					say "Installation finished successfully."
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										52
									
								
								package-lock.json
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										52
									
								
								package-lock.json
									
									
									
										generated
									
									
									
								
							@ -5,9 +5,9 @@
 | 
				
			|||||||
  "requires": true,
 | 
					  "requires": true,
 | 
				
			||||||
  "dependencies": {
 | 
					  "dependencies": {
 | 
				
			||||||
    "@actions/core": {
 | 
					    "@actions/core": {
 | 
				
			||||||
      "version": "1.2.5",
 | 
					      "version": "1.2.6",
 | 
				
			||||||
      "resolved": "https://registry.npmjs.org/@actions/core/-/core-1.2.5.tgz",
 | 
					      "resolved": "https://registry.npmjs.org/@actions/core/-/core-1.2.6.tgz",
 | 
				
			||||||
      "integrity": "sha512-mwpoNjHSWWh0IiALdDEQi3tru124JKn0yVNziIBzTME8QRv7thwoghVuT1jBRjFvdtoHsqD58IRHy1nf86paRg=="
 | 
					      "integrity": "sha512-ZQYitnqiyBc3D+k7LsgSBmMDVkOVidaagDG7j3fOym77jNunWRuYx7VSHa9GNfFZh+zh61xsCjRj4JxMZlDqTA=="
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    "@actions/exec": {
 | 
					    "@actions/exec": {
 | 
				
			||||||
      "version": "1.0.4",
 | 
					      "version": "1.0.4",
 | 
				
			||||||
@ -610,7 +610,8 @@
 | 
				
			|||||||
        "slash": "^3.0.0",
 | 
					        "slash": "^3.0.0",
 | 
				
			||||||
        "source-map": "^0.6.0",
 | 
					        "source-map": "^0.6.0",
 | 
				
			||||||
        "string-length": "^4.0.1",
 | 
					        "string-length": "^4.0.1",
 | 
				
			||||||
        "terminal-link": "^2.0.0"
 | 
					        "terminal-link": "^2.0.0",
 | 
				
			||||||
 | 
					        "v8-to-istanbul": "^5.0.1"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "dependencies": {
 | 
					      "dependencies": {
 | 
				
			||||||
        "slash": {
 | 
					        "slash": {
 | 
				
			||||||
@ -618,23 +619,6 @@
 | 
				
			|||||||
          "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz",
 | 
					          "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz",
 | 
				
			||||||
          "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==",
 | 
					          "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==",
 | 
				
			||||||
          "dev": true
 | 
					          "dev": true
 | 
				
			||||||
        },
 | 
					 | 
				
			||||||
        "v8-to-istanbul": {
 | 
					 | 
				
			||||||
          "version": "4.1.4",
 | 
					 | 
				
			||||||
          "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-4.1.4.tgz",
 | 
					 | 
				
			||||||
          "integrity": "sha512-Rw6vJHj1mbdK8edjR7+zuJrpDtKIgNdAvTSAcpYfgMIw+u2dPDntD3dgN4XQFLU2/fvFQdzj+EeSGfd/jnY5fQ==",
 | 
					 | 
				
			||||||
          "requires": {
 | 
					 | 
				
			||||||
            "@types/istanbul-lib-coverage": "^2.0.1",
 | 
					 | 
				
			||||||
            "convert-source-map": "^1.6.0",
 | 
					 | 
				
			||||||
            "source-map": "^0.7.3"
 | 
					 | 
				
			||||||
          },
 | 
					 | 
				
			||||||
          "dependencies": {
 | 
					 | 
				
			||||||
            "source-map": {
 | 
					 | 
				
			||||||
              "version": "0.7.3",
 | 
					 | 
				
			||||||
              "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.3.tgz",
 | 
					 | 
				
			||||||
              "integrity": "sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ=="
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
          }
 | 
					 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
@ -922,7 +906,8 @@
 | 
				
			|||||||
    "@types/istanbul-lib-coverage": {
 | 
					    "@types/istanbul-lib-coverage": {
 | 
				
			||||||
      "version": "2.0.2",
 | 
					      "version": "2.0.2",
 | 
				
			||||||
      "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.2.tgz",
 | 
					      "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.2.tgz",
 | 
				
			||||||
      "integrity": "sha512-rsZg7eL+Xcxsxk2XlBt9KcG8nOp9iYdKCOikY9x2RFJCyOdNj4MKPQty0e8oZr29vVAzKXr1BmR+kZauti3o1w=="
 | 
					      "integrity": "sha512-rsZg7eL+Xcxsxk2XlBt9KcG8nOp9iYdKCOikY9x2RFJCyOdNj4MKPQty0e8oZr29vVAzKXr1BmR+kZauti3o1w==",
 | 
				
			||||||
 | 
					      "dev": true
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    "@types/istanbul-lib-report": {
 | 
					    "@types/istanbul-lib-report": {
 | 
				
			||||||
      "version": "3.0.0",
 | 
					      "version": "3.0.0",
 | 
				
			||||||
@ -1611,6 +1596,7 @@
 | 
				
			|||||||
      "version": "1.7.0",
 | 
					      "version": "1.7.0",
 | 
				
			||||||
      "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz",
 | 
					      "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz",
 | 
				
			||||||
      "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==",
 | 
					      "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==",
 | 
				
			||||||
 | 
					      "dev": true,
 | 
				
			||||||
      "requires": {
 | 
					      "requires": {
 | 
				
			||||||
        "safe-buffer": "~5.1.1"
 | 
					        "safe-buffer": "~5.1.1"
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
@ -4228,7 +4214,8 @@
 | 
				
			|||||||
    "safe-buffer": {
 | 
					    "safe-buffer": {
 | 
				
			||||||
      "version": "5.1.2",
 | 
					      "version": "5.1.2",
 | 
				
			||||||
      "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
 | 
					      "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
 | 
				
			||||||
      "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="
 | 
					      "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==",
 | 
				
			||||||
 | 
					      "dev": true
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    "safe-regex": {
 | 
					    "safe-regex": {
 | 
				
			||||||
      "version": "1.1.0",
 | 
					      "version": "1.1.0",
 | 
				
			||||||
@ -5160,6 +5147,25 @@
 | 
				
			|||||||
      "integrity": "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==",
 | 
					      "integrity": "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==",
 | 
				
			||||||
      "dev": true
 | 
					      "dev": true
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
 | 
					    "v8-to-istanbul": {
 | 
				
			||||||
 | 
					      "version": "5.0.1",
 | 
				
			||||||
 | 
					      "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-5.0.1.tgz",
 | 
				
			||||||
 | 
					      "integrity": "sha512-mbDNjuDajqYe3TXFk5qxcQy8L1msXNE37WTlLoqqpBfRsimbNcrlhQlDPntmECEcUvdC+AQ8CyMMf6EUx1r74Q==",
 | 
				
			||||||
 | 
					      "dev": true,
 | 
				
			||||||
 | 
					      "requires": {
 | 
				
			||||||
 | 
					        "@types/istanbul-lib-coverage": "^2.0.1",
 | 
				
			||||||
 | 
					        "convert-source-map": "^1.6.0",
 | 
				
			||||||
 | 
					        "source-map": "^0.7.3"
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
 | 
					      "dependencies": {
 | 
				
			||||||
 | 
					        "source-map": {
 | 
				
			||||||
 | 
					          "version": "0.7.3",
 | 
				
			||||||
 | 
					          "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.3.tgz",
 | 
				
			||||||
 | 
					          "integrity": "sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==",
 | 
				
			||||||
 | 
					          "dev": true
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
    "validate-npm-package-license": {
 | 
					    "validate-npm-package-license": {
 | 
				
			||||||
      "version": "3.0.4",
 | 
					      "version": "3.0.4",
 | 
				
			||||||
      "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz",
 | 
					      "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz",
 | 
				
			||||||
 | 
				
			|||||||
@ -30,7 +30,7 @@
 | 
				
			|||||||
  "author": "GitHub",
 | 
					  "author": "GitHub",
 | 
				
			||||||
  "license": "MIT",
 | 
					  "license": "MIT",
 | 
				
			||||||
  "dependencies": {
 | 
					  "dependencies": {
 | 
				
			||||||
    "@actions/core": "^1.2.5",
 | 
					    "@actions/core": "^1.2.6",
 | 
				
			||||||
    "@actions/exec": "^1.0.4",
 | 
					    "@actions/exec": "^1.0.4",
 | 
				
			||||||
    "@actions/github": "^1.1.0",
 | 
					    "@actions/github": "^1.1.0",
 | 
				
			||||||
    "@actions/http-client": "^1.0.8",
 | 
					    "@actions/http-client": "^1.0.8",
 | 
				
			||||||
 | 
				
			|||||||
@ -146,8 +146,8 @@ export class DotnetCoreInstaller {
 | 
				
			|||||||
      const scriptPath = await io.which(escapedScript, true);
 | 
					      const scriptPath = await io.which(escapedScript, true);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      let scriptArguments: string[] = [];
 | 
					      let scriptArguments: string[] = [];
 | 
				
			||||||
      if (this.version) {
 | 
					      if (calculatedVersion) {
 | 
				
			||||||
        scriptArguments.push('--version', this.version);
 | 
					        scriptArguments.push('--version', calculatedVersion);
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      // process.env must be explicitly passed in for DOTNET_INSTALL_DIR to be used
 | 
					      // process.env must be explicitly passed in for DOTNET_INSTALL_DIR to be used
 | 
				
			||||||
@ -163,6 +163,7 @@ export class DotnetCoreInstaller {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    if (process.env['DOTNET_INSTALL_DIR']) {
 | 
					    if (process.env['DOTNET_INSTALL_DIR']) {
 | 
				
			||||||
      core.addPath(process.env['DOTNET_INSTALL_DIR']);
 | 
					      core.addPath(process.env['DOTNET_INSTALL_DIR']);
 | 
				
			||||||
 | 
					      core.exportVariable('DOTNET_ROOT', process.env['DOTNET_INSTALL_DIR']);
 | 
				
			||||||
    } else {
 | 
					    } else {
 | 
				
			||||||
      if (IS_WINDOWS) {
 | 
					      if (IS_WINDOWS) {
 | 
				
			||||||
        // This is the default set in install-dotnet.ps1
 | 
					        // This is the default set in install-dotnet.ps1
 | 
				
			||||||
@ -176,6 +177,10 @@ export class DotnetCoreInstaller {
 | 
				
			|||||||
      } else {
 | 
					      } else {
 | 
				
			||||||
        // This is the default set in install-dotnet.sh
 | 
					        // This is the default set in install-dotnet.sh
 | 
				
			||||||
        core.addPath(path.join(process.env['HOME'] + '', '.dotnet'));
 | 
					        core.addPath(path.join(process.env['HOME'] + '', '.dotnet'));
 | 
				
			||||||
 | 
					        core.exportVariable(
 | 
				
			||||||
 | 
					          'DOTNET_ROOT',
 | 
				
			||||||
 | 
					          path.join(process.env['HOME'] + '', '.dotnet')
 | 
				
			||||||
 | 
					        );
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -245,19 +250,25 @@ export class DotnetCoreInstaller {
 | 
				
			|||||||
    const response = await httpClient.getJson<any>(DotNetCoreIndexUrl);
 | 
					    const response = await httpClient.getJson<any>(DotNetCoreIndexUrl);
 | 
				
			||||||
    const result = response.result || {};
 | 
					    const result = response.result || {};
 | 
				
			||||||
    let releasesInfo: any[] = result['releases-index'];
 | 
					    let releasesInfo: any[] = result['releases-index'];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    releasesInfo = releasesInfo.filter((info: any) => {
 | 
					    releasesInfo = releasesInfo.filter((info: any) => {
 | 
				
			||||||
      // channel-version is the first 2 elements of the version (e.g. 2.1), filter out versions that don't match 2.1.x.
 | 
					      // channel-version is the first 2 elements of the version (e.g. 2.1), filter out versions that don't match 2.1.x.
 | 
				
			||||||
      const sdkParts: string[] = info['channel-version'].split('.');
 | 
					      const sdkParts: string[] = info['channel-version'].split('.');
 | 
				
			||||||
      if (versionParts.length >= 2 && versionParts[1] != 'x') {
 | 
					      if (
 | 
				
			||||||
 | 
					        versionParts.length >= 2 &&
 | 
				
			||||||
 | 
					        !(versionParts[1] == 'x' || versionParts[1] == '*')
 | 
				
			||||||
 | 
					      ) {
 | 
				
			||||||
        return versionParts[0] == sdkParts[0] && versionParts[1] == sdkParts[1];
 | 
					        return versionParts[0] == sdkParts[0] && versionParts[1] == sdkParts[1];
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
      return versionParts[0] == sdkParts[0];
 | 
					      return versionParts[0] == sdkParts[0];
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if (releasesInfo.length === 0) {
 | 
					    if (releasesInfo.length === 0) {
 | 
				
			||||||
      throw `Could not find info for version ${versionParts.join(
 | 
					      throw `Could not find info for version ${versionParts.join(
 | 
				
			||||||
        '.'
 | 
					        '.'
 | 
				
			||||||
      )} at ${DotNetCoreIndexUrl}`;
 | 
					      )} at ${DotNetCoreIndexUrl}`;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    return releasesInfo[0]['releases.json'];
 | 
					    return releasesInfo[0]['releases.json'];
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user