Skip to content

Commit 6b2b813

Browse files
author
mirkobrombin
committed
ci: add workflows
1 parent 5102ecb commit 6b2b813

3 files changed

Lines changed: 61 additions & 1 deletion

File tree

.github/workflows/build.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Go
2+
3+
on:
4+
push:
5+
pull_request:
6+
branches: [ "main" ]
7+
8+
jobs:
9+
10+
build:
11+
name: Build
12+
runs-on: ubuntu-latest
13+
container:
14+
image: ghcr.io/vanilla-os/pico:main
15+
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
- name: Set up Go
20+
uses: actions/setup-go@v5
21+
with:
22+
go-version: 1.21
23+
24+
- name: Build
25+
run: go build -o hrun
26+
27+
- uses: actions/upload-artifact@v4
28+
with:
29+
name: hrun
30+
path: |
31+
hrun

.github/workflows/release.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- '*'
7+
8+
jobs:
9+
release:
10+
runs-on: ubuntu-latest
11+
container:
12+
image: ghcr.io/vanilla-os/pico:main
13+
14+
steps:
15+
- uses: actions/checkout@v4
16+
17+
- name: Set up Go
18+
uses: actions/setup-go@v5
19+
with:
20+
go-version: 1.21
21+
22+
- name: Build
23+
run: go build -o hrun
24+
25+
- uses: softprops/action-gh-release@v2
26+
with:
27+
token: "${{ secrets.GITHUB_TOKEN }}"
28+
files: |
29+
hrun

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/distrobox/hrun
22

3-
go 1.21.6
3+
go 1.21
44

55
require (
66
github.com/creack/pty v1.1.21

0 commit comments

Comments
 (0)