-
Notifications
You must be signed in to change notification settings - Fork 40
79 lines (67 loc) · 2.23 KB
/
PullRequest.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT License.
#
# CI workflow for PRs and merges to master
# https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-syntax-for-github-actions
name: PullRequest
on:
workflow_dispatch: # allow for manual workflow triggering as needed
push:
branches: [main]
pull_request:
branches: [main, release/stable]
env:
DEBUG : taskTest:*,-taskTest:runner:stdout
DEBUG_COLORS : 1
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-latest
- windows-latest
steps:
- uses: actions/checkout@v2
with:
lfs: true
- name: Setup .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: 6.0.x
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: 16
registry-url: https://npm.pkg.github.com
- name: Configure npm
run: npm config set //npm.pkg.github.com/:_authToken=${{ secrets.GPR_ACCESS_TOKEN }}
- name: Install npm@8 globally (windows)
if: matrix.os == 'windows-latest'
run: npm i -g npm@8
- name: Install npm@9 globally (linux)
if: matrix.os != 'windows-latest'
run: npm i -g npm@9
- name: Install npm dependencies
run: npm ci
- name: Build and test
run: npm run ci
# Note: To set version:
# npm run ci -- --major 1 --minor 0 --patch 30
# all version parts are optional
# each will default to whatever version is set to in src at extension/extension-manifest.json
# Example:
# npm run ci --patch 30
# "version": "1.0.29" (in extension-manifest.json)
# output VSIX version: 1.0.30
env:
AZ_DevOps_Read_PAT: ${{ secrets.AZ_DevOps_Read_PAT }}
PA_BT_ORG_PASSWORD: ${{ secrets.PA_BT_ORG_PASSWORD }}
PR_NUMBER: ${{ github.event.number }}
RUN_ID: ${{ github.run_id }}
- name: Upload PAC CLI logs
if: always()
uses: actions/upload-artifact@v4
with:
name: pac-cli-log ${{ matrix.os }}
path: out/pp-bt-test/tasks/tool-installer/**/pac*/tools/logs/pac-log.txt