forked from aliencube/microsoft-teams-actions
-
Notifications
You must be signed in to change notification settings - Fork 0
56 lines (47 loc) · 1.49 KB
/
main.yaml
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
name: Build and Test GitHub actions
on:
push:
branches:
- master
- release/*
- dev
pull_request:
branches:
- dev
jobs:
build_and_test:
name: Build and test the GitHub Action
strategy:
matrix:
os: [ 'ubuntu-latest' ]
dotnet: [ '3.1.100' ]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout the repository
uses: actions/checkout@v2
- name: Setup .NET SDK
uses: actions/setup-dotnet@v1
with:
dotnet-version: ${{ matrix.dotnet }}
- name: Restore NuGet packages
shell: bash
run: |
dotnet restore
- name: Build console app
shell: bash
run: |
dotnet build
- name: Test console app
shell: bash
run: |
dotnet test test/**/*.csproj
- name: Run the private action
uses: ./
with:
webhook_uri: ${{ secrets.WEBHOOK_URI }}
title: ''
summary: 'GitHub Actions Message'
text: ''
theme_color: ''
sections: '[{ "activityImage": "https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png", "activityTitle": "GitHub Action invoked", "activitySubtitle": "Event triggered by ${{ github.event.head_commit.author.name }}", "activityText": "Commit message: [${{ github.event.head_commit.message}}](${{ github.event.head_commit.url }})" }]'
actions: '[{ "@type": "OpenUri", "name": "View Commit", "targets": [{ "os": "default", "uri": "${{ github.event.head_commit.url }}" }] }]'