Skip to content

feat: improve CI and README badges#56

Merged
nomeguy merged 6 commits intomasterfrom
copilot/rewrite-ci-scripts-readme
Jan 13, 2026
Merged

feat: improve CI and README badges#56
nomeguy merged 6 commits intomasterfrom
copilot/rewrite-ci-scripts-readme

Conversation

Copy link
Contributor

Copilot AI commented Jan 13, 2026

fix: #55

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@nomeguy nomeguy marked this pull request as ready for review January 13, 2026 17:32
Copilot AI and others added 4 commits January 13, 2026 17:34
Co-authored-by: nomeguy <85475922+nomeguy@users.noreply.github.com>
…urces

Co-authored-by: nomeguy <85475922+nomeguy@users.noreply.github.com>
Co-authored-by: nomeguy <85475922+nomeguy@users.noreply.github.com>
Co-authored-by: nomeguy <85475922+nomeguy@users.noreply.github.com>
Copilot AI changed the title [WIP] Re-write CI scripts and update README with badges Modernize CI workflow and README badges to match Casbin standards Jan 13, 2026
Copilot AI requested a review from nomeguy January 13, 2026 17:41
@nomeguy
Copy link

nomeguy commented Jan 13, 2026

@copilot use Go 1.23

The following duplicated CI checks ran in this open PR

failing checks
Build / Back-end (pull_request)Started now — This check has started...
Loading
Build / Back-end (push)
Build / Back-end (push)Started now — This check has started...
Loading
Build / Front-end (pull_request)
Build / Front-end (pull_request)Started now — This check has started...
Loading
Build / Front-end (push)
Build / Front-end (push)Started now — This check has started...
Loading
Build / Go-Linter (pull_request)
Build / Go-Linter (pull_request)Started now — This check has started...
Loading
Build / Go-Linter (push)
Build / Go-Linter (push)Started now — This check has started...

I think for an open state PR, it should not run "XXX (push)" checks, right? It should run for the git push after PR merge?
Need to fix the CI.

you should refer to:

name: Go

on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master ]

jobs:
  test:
    runs-on: ubuntu-latest
    permissions:
      contents: read
    strategy:
      fail-fast: false
      matrix:
        go-version: [ '1.23' ]

    services:
      etcd:
        image: quay.io/coreos/etcd:v3.5.0
        ports:
          - 2379:2379
          - 2380:2380
        env:
          ETCD_LISTEN_CLIENT_URLS: http://0.0.0.0:2379
          ETCD_ADVERTISE_CLIENT_URLS: http://0.0.0.0:2379

    steps:
      - name: Checkout code
        uses: actions/checkout@v3

      - name: Set up Go
        uses: actions/setup-go@v4
        with:
          go-version: ${{ matrix.go-version }}

      - name: Test
        run: go test -covermode atomic -coverprofile=covprofile ./...

      - name: Install goveralls
        run: go install github.com/mattn/goveralls@latest

      - name: Send coverage
        env:
          COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        run: goveralls -coverprofile=covprofile -service=github

  semantic-release:
    needs: [test]
    if: github.repository == 'casbin/etcd-watcher' && github.event_name == 'push'
    runs-on: ubuntu-latest
    permissions:
      contents: write
    steps:
      - name: Checkout code
        uses: actions/checkout@v3

      - name: Install Node.js
        uses: actions/setup-node@v3
        with:
          node-version: '18.x'

      - name: Install semantic-release
        run: npm install --save-dev semantic-release@21.0.0 @semantic-release/commit-analyzer @semantic-release/release-notes-generator @semantic-release/github

      - name: Run semantic-release
        run: npx semantic-release
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Co-authored-by: nomeguy <85475922+nomeguy@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Jan 13, 2026

@copilot use Go 1.23

The following duplicated CI checks ran in this open PR
...

Updated to Go 1.23 and fixed the CI triggers to avoid duplicate checks. The workflow now uses:

  • on: push: branches: [master] and pull_request: branches: [master] (instead of on: [push, pull_request])
  • Go 1.23 with matrix strategy
  • checkout@v3 and setup-go@v4
  • Manual goveralls installation
  • semantic-release 21.0.0 with plugins
  • Proper permissions

This matches the etcd-watcher reference you provided. Commit: 18086d6

@nomeguy nomeguy changed the title Modernize CI workflow and README badges to match Casbin standards feat: improve CI and README badges Jan 13, 2026
@nomeguy nomeguy merged commit 1d998a3 into master Jan 13, 2026
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[feature] re-write the whole CI scripts and README content text, add all README badges

3 participants