Skip to content

Commit

Permalink
Merge pull request #1 from sincerefly/cicd/add_go_build_action
Browse files Browse the repository at this point in the history
Cicd/add go build action
  • Loading branch information
sincerefly committed Jan 17, 2024
2 parents cc6c071 + 7fe647e commit 837172e
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Build
on: [push, pull_request]
permissions:
contents: read

jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:

- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '^1.20'
id: go

- name: Check out code into the Go module directory
uses: actions/checkout@v4

- name: Get dependencies
run: |
go get -v -t -d ./...
if [ -f Gopkg.toml ]; then
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
dep ensure
fi
- name: Check the build
shell: bash -l {0}
run: |
export PATH=${PATH}:`go env GOPATH`/bin
make build
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Easycmd
![Build](https://github.com/sincerefly/easycmd/workflows/Build/badge.svg)
<a href="https://opensource.org/licenses/MIT"><img src="https://img.shields.io/badge/license-MIT-_red.svg"></a>
<a href="https://github.com/sincerefly/easycmd/issues"><img src="https://img.shields.io/badge/contributions-welcome-brightgreen.svg?style=flat"></a>
<a href='https://coveralls.io/github/sincerefly/easycmd?branch=main'><img src='https://coveralls.io/repos/github/sincerefly/easycmd/badge.svg?branch=main' alt='Coverage Status' /></a>
Expand Down

0 comments on commit 837172e

Please sign in to comment.