8000 GitHub - benauca/district-21
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

benauca/district-21

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

district-21

Coverage

District 21 Game

Testing

go test ./... -v

If we want test with coverage

go test ./... -test.coverprofile coverage go test ./... -cover

CI/CD

CI Tool Chain For Go

For my personal code I use GitHub as a repository, so assuming that the tools I’ll employ are:

  • GitHub Actions: Automate the workflow

  • Codecov.io: A coverage dashboard

  • Readme badges: Easy visibility dashboard on CI status

  • Templates CI/CD for golang projects

CI-WORKFLOW [ ./gihub/workspaces/ci-go.yml ]

Start with any events on

  • Push:
    • On branches main or feature
  • Any pull_request
stateDiagram
    direction LR
    [*] --> checkout@v3
    checkout@v3 --> setup_go@v3
    setup_go@v3 --> vet
    vet --> fmt
    fmt --> test
    test --> go_coverage_badge
    go_coverage_badge --> verify_changed_files
    verify_changed_files --> push_changes
    push_changes --> build
    build --> [*]
Loading

LINT Golang [ ./github/workspaces/golangci-lint]

Start with

  • Push:
    • On Tag with name as v*
    • On branches main or feature
  • Any pull_request
stateDiagram
    direction LR
    [*] --> checkout@v3
    checkout@v3 --> golangci_lint
    golangci_lint --> [*]
Loading

CD Workflow [ ./github/workspaces/release.yml ]

  • Push:
    • On Tag with name as v*
    • On only branches main
  • Any pull_request
stateDiagram
    direction LR
    [*] --> checkout@v3
    checkout@v3 --> setup_go@v3
    setup_go@v3 --> goreleaser
    goreleaser --> [*]
Loading

WellCome workflow

jobs:
  greeting:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/first-interaction@v1.1.0
      with:
        repo-token: ${{ secrets.GITHUB_TOKEN }}
        issue-message: "Thanks for reporting this issue, don't forget to star this project if you haven't already to help us reach a wider audience."
        pr-message: "Thanks for implementing a fix, could you ensure that the test covers your changes if applicable."

TODOs

Colaborate

Include Fix fix(#issueId): include a comment

Include Feature feat(#issueId): Include an commit change

Improbe documentation doc(#issueid): Include an change

For example doc(#1): [README.md] Include CI and CD Workflows

About

No description or website provided.

Topics

Resources

Code of conduct

Security policy

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages

0