Installer improvements #1291
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
lint: | |
runs-on: windows-2019 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
with: | |
# fetch all history for all branches | |
fetch-depth: 0 | |
- name: Run lint.py | |
run: python scripts/test/lint.py packages | |
- name: Run lint.ps1 | |
run: scripts/test/lint.ps1 | |
test_upload: | |
runs-on: ${{ matrix.os }} | |
needs: [lint] | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [windows-2019, windows-2022] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Get changed files | |
id: files | |
uses: Ana06/[email protected] | |
with: | |
filter: '*.nuspec' | |
- name: Build and test all modified packages | |
id: test | |
# It runs only if there are modified files | |
if: steps.files.outputs.added_modified_renamed != '' | |
run: | | |
$packages = "${{ steps.files.outputs.added_modified_renamed }}".Split(" ") | Foreach-Object { (Get-Item $_).Directory.Name } | |
scripts/test/test_install.ps1 "common.vm $packages" | |
- name: Upload logs to artifacts | |
uses: ./.github/actions/upload-logs | |
if: always() | |
- name: Push all built packages to MyGet | |
# Only push packages on master if they were built (not if testing was skipped) and | |
# only with one version of Windows (otherwise it would be pushed 3 times) | |
if: steps.test.outcome == 'success' && github.event_name == 'push' && matrix.os == 'windows-2019' | |
run: | | |
$built_pkgs = Get-ChildItem built_pkgs | |
Set-Location built_pkgs | |
foreach ($package in $built_pkgs) { | |
choco push -s "https://www.myget.org/F/vm-packages/api/v2" -k ${{ secrets.MYGET_TOKEN }} $package | |
} |