-
Notifications
You must be signed in to change notification settings - Fork 0
52 lines (48 loc) · 1.34 KB
/
ci.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
name: CI
on: [push, pull_request]
defaults:
run:
shell: pwsh
env:
dotnet-version: "3.1.x"
node-version: "12.x"
build_version: "0.0.1.${{ github.run_number }}-preview"
jobs:
ci:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup dotnet
uses: actions/setup-dotnet@v1
with:
dotnet-version: ${{ env.dotnet-version }}
- name: Setup NodeJS
uses: actions/setup-node@v1
with:
node-version: ${{ env.node-version }}
- name: Setup psake
run: Set-PSRepository -Name PSGallery -InstallationPolicy Trusted; Install-Module -Name psake
- name: CI
env:
NUGET_AUTH_TOKEN: ${{ secrets.AZ_TOKEN }}
run: Invoke-psake ci -parameters @{ "NUGET_AUTH_TOKEN" = $env:NUGET_AUTH_TOKEN ; "build_version" = $env:build_version }
- name: Upload reports
uses: actions/upload-artifact@v2
with:
name: ci-${{ matrix.os }}
path: ./reports
invoke-cd:
needs: ci
runs-on: ubuntu-latest
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
steps:
- name: Repository Dispatch
uses: peter-evans/repository-dispatch@v1
with:
token: ${{ secrets.PA_TOKEN }}
event-type: cd