Skip to content

Commit 6de7679

Browse files
committed
- Add pre-commit checks
- Add CI (GH actions) config - Add badges to README
1 parent c6d0018 commit 6de7679

File tree

3 files changed

+65
-0
lines changed

3 files changed

+65
-0
lines changed

.github/workflows/go.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# This workflow will build a golang project
2+
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go
3+
4+
name: Go
5+
6+
on: [push, pull_request]
7+
8+
defaults:
9+
run:
10+
shell: 'bash -Eeuo pipefail -x {0}'
11+
12+
jobs:
13+
14+
build:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v3
18+
19+
- name: Set up Go
20+
uses: actions/setup-go@v4
21+
with:
22+
go-version: '1.20'
23+
24+
- name: Build
25+
run: go build -v
26+
- name: Test
27+
run: |
28+
set -e
29+
go install github.com/go-critic/go-critic/cmd/gocritic@latest
30+
go install golang.org/x/tools/cmd/goimports@latest
31+
go install golang.org/x/lint/golint@latest
32+
go install github.com/gordonklaus/ineffassign@latest
33+
pip install pre-commit
34+
pre-commit install
35+
pre-commit run --all-files
36+
# go test -v
37+
38+
#- name: Test
39+
#run: go test -v

.pre-commit-config.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
repos:
2+
- repo: https://github.com/jessp01/pre-commit-golang.git
3+
rev: v0.5.4
4+
hooks:
5+
- id: go-fmt
6+
- id: go-imports
7+
#- id: go-vet
8+
- id: go-lint
9+
- id: go-critic
10+
- id: go-ineffassign
11+
- id: shellcheck

README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
# go-uml
2+
3+
[![CI][badge-build]][build]
4+
[![GoDoc][go-docs-badge]][go-docs]
5+
[![GoReportCard][go-report-card-badge]][go-report-card]
6+
[![License][badge-license]][license]
7+
28
Just a little tool to create UML Diagrams built in Go. You can use it already to build simple sequence diagrams, however, this project is still under development
39
and you won't find some functionalities yet such as
410

@@ -65,3 +71,12 @@ Some more examples:
6571
## Warning - AI not welcome here
6672
Because of my own personal philosophy regarding technology and AI, all the code in this repository that was written by me - I wrote 100% on my own. There is and will be no usage of Github Co-Pilot or any other AI tool. I became a software developer because of my passion for our craft - Software Engineering. I build this tool because I enjoy programming. Every single line of code you'll read in this repo, that was written by me, is produced first in my mind and then manifested into reality through my hands. I encourage any contributor to follow the same principle, though I can't and don't want to put any restrictions on this.
6773
Just like people stopped walking because they commute by cars and trains, which caused an increase in obesity and illness, I believe that the massive usage of AI will cause people to stop thinking and using their minds and the resulting havoc is unthinkable.
74+
75+
[license]: ./LICENSE
76+
[badge-license]: https://img.shields.io/github/license/MrIceman/go-uml.svg
77+
[go-docs-badge]: https://godoc.org/github.com/MrIceman/go-uml?status.svg
78+
[go-docs]: https://godoc.org/github.com/MrIceman/go-uml
79+
[go-report-card-badge]: https://goreportcard.com/badge/github.com/MrIceman/go-uml
80+
[go-report-card]: https://goreportcard.com/report/github.com/MrIceman/go-uml
81+
[badge-build]: https://github.com/MrIceman/go-uml/actions/workflows/go.yml/badge.svg
82+
[build]: https://github.com/MrIceman/go-uml/actions/workflows/go.yml

0 commit comments

Comments
 (0)