-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (53 loc) · 1.87 KB
/
TrainerBot.yml
File metadata and controls
63 lines (53 loc) · 1.87 KB
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
name: TrainerBot
on:
push:
branches: ["main"]
paths-ignore:
- 'README.md'
- '.gitignore'
- '.editorconfig'
workflow_dispatch:
env:
dotnet: 8.0.x
jobs:
build:
runs-on: windows-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 10
- name: Configure .NET SDK ${{ env.dotnet }}
uses: actions/setup-dotnet@v2
with:
dotnet-version: ${{ env.dotnet }}
- name: Generating version
id: versioning
uses: mathieudutour/github-tag-action@v6.1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
default_bump: patch
release_branches: main
tag_prefix: ''
dry_run: true
- name: Source
run: dotnet nuget add source --username roxeez --password ${{ secrets.NUGET_PACKAGES }} --store-password-in-clear-text --name talefactory "https://nuget.pkg.github.com/talefactory/index.json"
- name: .NET Restore
run: dotnet restore TaleSuit.TrainerBot
- name: .NET Build
run: dotnet build TaleSuit.TrainerBot --no-restore -c Release -o build /p:Version=${{ steps.versioning.outputs.new_tag }} /p:DebugType=None /p:DebugSymbols=false
- name: Cloudflare R2 Upload
uses: okkema/github-action-r2@v0.1.1
with:
account_id: ${{ secrets.R2_ACCOUNT_ID }}
r2_access_key: ${{ secrets.R2_ACCESS_KEY }}
r2_secret_key: ${{ secrets.R2_SECRET_KEY }}
r2_bucket: trainerbot-builds
source_dir: build
destination_dir: ${{ steps.versioning.outputs.new_tag }}
- name: Create tag
uses: mathieudutour/github-tag-action@v6.1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
tag_prefix: ''
custom_tag: ${{ steps.versioning.outputs.new_tag }}