-
Notifications
You must be signed in to change notification settings - Fork 31
74 lines (64 loc) · 1.66 KB
/
build-workload.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
name: Build Workload
on:
push:
branches:
- main
- net7.0
- net8.0
paths:
- 'workload/**'
- '.github/workflows/**'
pull_request:
branches:
- main
- net7.0
paths:
- 'workload/**'
- '.github/workflows/**'
workflow_dispatch:
inputs:
prerelease:
description: 'Pre-release tag name'
required: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Build
env:
PULLREQUEST_ID: ${{ github.event.number }}
PRERELEASE_TAG: ${{ github.event.inputs.prerelease }}
run: make test
working-directory: ./workload
- uses: actions/upload-artifact@v4
with:
name: tizen-workload-pkgs
path: ./workload/out/nuget-unsigned/*.nupkg
deploy:
runs-on: ubuntu-latest
needs: build
if: ${{ github.ref == 'refs/heads/main' }}
steps:
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.x
- name: Install Github Package Registry Tool
run: dotnet tool install --global --no-cache gpr
- uses: actions/download-artifact@v4
with:
name: tizen-workload-pkgs
- name: Push packages to GPR
run: |
gpr push --api-key ${{ secrets.GITHUB_TOKEN }} \
--repository ${{ github.repository }} \
--retries 3 Samsung.*.nupkg
- name: Push packages to MyGet
run: |
dotnet nuget push Samsung.*.nupkg \
-k ${{ secrets.MYGET_APIKEY }} \
-s https://tizen.myget.org/F/dotnet/api/v2/package \
-t 3000