Compare commits
9 Commits
21b541bdc1
...
c20a3fdbc8
| Author | SHA1 | Date | |
|---|---|---|---|
| c20a3fdbc8 | |||
|
36a543f3b9
|
|||
|
|
2abf750fc6 | ||
|
|
51fa77b84b | ||
|
|
f1d241ee6a | ||
|
|
29f03992a4 | ||
|
|
d95946bd4d | ||
|
|
611f73f48a | ||
|
|
d9ba3867f9 |
47
.gitea/workflows/build.yaml
Normal file
47
.gitea/workflows/build.yaml
Normal file
@@ -0,0 +1,47 @@
|
|||||||
|
name: Build artifact
|
||||||
|
run-name: Build from ${{ gitea.actor }} 🚀
|
||||||
|
on: [push]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Set up Go
|
||||||
|
uses: actions/setup-go@v4
|
||||||
|
with:
|
||||||
|
go-version: 1.21
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
run: go build -v ./...
|
||||||
|
|
||||||
|
- name: Test
|
||||||
|
run: go test -v ./...
|
||||||
|
|
||||||
|
- name: Upload artifact
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: InnkeeperBot
|
||||||
|
path: ./InnkeeperBot
|
||||||
|
|
||||||
|
release:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
needs: build
|
||||||
|
if: startsWith(gitea.event.ref, 'refs/tags/v')
|
||||||
|
steps:
|
||||||
|
- uses: actions/download-artifact@v2
|
||||||
|
with:
|
||||||
|
name: InnkeeperBot
|
||||||
|
- name: Set up Go
|
||||||
|
uses: actions/setup-go@v4
|
||||||
|
with:
|
||||||
|
go-version: 1.21
|
||||||
|
- name: Release artifact
|
||||||
|
id: use-go-action
|
||||||
|
uses: https://gitea.com/actions/release-action@main
|
||||||
|
with:
|
||||||
|
files: |-
|
||||||
|
InnkeeperBot
|
||||||
|
api_key: '${{secrets.RELEASE_TOKEN}}'
|
||||||
|
|
||||||
4
Dockerfile
Normal file
4
Dockerfile
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
FROM scratch
|
||||||
|
|
||||||
|
COPY InnkeeperBot /
|
||||||
|
RUN chmod a+x /InnkeeperBot
|
||||||
Reference in New Issue
Block a user