mirror of
https://github.com/lukaszraczylo/mcp-readitall.git
synced 2026-10-12 00:45:33 +00:00
ci: use the shared pull request, release and autoupdate workflows (#1)
* ci(release): add goreleaser and semver configuration The release builds only cmd/readitall for Linux, macOS and Windows on amd64 and arm64. The checksum file is signed with cosign. The semver config uses regex matching. A major release needs an explicit trailer line. * ci: add shared pull request, release and autoupdate workflows The workflows call the shared workflows in lukaszraczylo/shared-actions. The release runs on push to main when Go files change. * docs: describe release binary installation The README now tells you to download a binary from the GitHub release page. * fix(browser): remove the unused mutex field of SessionStore Staticcheck reports U1000 for the field. No method locks it. The pull request checks fail until the field is removed.
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
name: Autoupdate go.mod and go.sum
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: "0 3 * * *"
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
actions: write
|
||||
pull-requests: write
|
||||
security-events: write
|
||||
|
||||
jobs:
|
||||
autoupdate:
|
||||
uses: lukaszraczylo/shared-actions/.github/workflows/go-autoupdate.yaml@main
|
||||
with:
|
||||
go-version: ">=1.26"
|
||||
release-workflow: "release.yaml"
|
||||
secrets: inherit
|
||||
@@ -0,0 +1,22 @@
|
||||
name: Pull Request
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
push:
|
||||
branches:
|
||||
- "**"
|
||||
- "!main"
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
actions: write
|
||||
pull-requests: write
|
||||
security-events: write
|
||||
|
||||
jobs:
|
||||
pr-checks:
|
||||
uses: lukaszraczylo/shared-actions/.github/workflows/go-pr.yaml@main
|
||||
with:
|
||||
go-version: ">=1.26"
|
||||
@@ -0,0 +1,23 @@
|
||||
name: Release
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
paths:
|
||||
- "**.go"
|
||||
- "go.mod"
|
||||
- "go.sum"
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
packages: write
|
||||
id-token: write
|
||||
|
||||
jobs:
|
||||
release:
|
||||
uses: lukaszraczylo/shared-actions/.github/workflows/go-release.yaml@main
|
||||
with:
|
||||
go-version: ">=1.26"
|
||||
secrets: inherit
|
||||
@@ -0,0 +1,61 @@
|
||||
version: 2
|
||||
|
||||
builds:
|
||||
- id: readitall
|
||||
main: ./cmd/readitall
|
||||
binary: readitall
|
||||
env:
|
||||
- CGO_ENABLED=0
|
||||
goos:
|
||||
- linux
|
||||
- darwin
|
||||
- windows
|
||||
goarch:
|
||||
- amd64
|
||||
- arm64
|
||||
flags:
|
||||
- -trimpath
|
||||
ldflags:
|
||||
- -s -w
|
||||
|
||||
archives:
|
||||
- id: readitall
|
||||
formats: [tar.gz]
|
||||
name_template: "readitall-{{ .Version }}-{{ .Os }}-{{ .Arch }}"
|
||||
format_overrides:
|
||||
- goos: windows
|
||||
formats: [zip]
|
||||
files:
|
||||
- README.md
|
||||
|
||||
checksum:
|
||||
name_template: "readitall-{{ .Version }}-checksums.txt"
|
||||
algorithm: sha256
|
||||
|
||||
changelog:
|
||||
sort: asc
|
||||
filters:
|
||||
exclude:
|
||||
- '^docs:'
|
||||
- '^test:'
|
||||
- '^Merge'
|
||||
- '^WIP'
|
||||
|
||||
release:
|
||||
github:
|
||||
owner: lukaszraczylo
|
||||
name: mcp-readitall
|
||||
name_template: "Release {{.Version}}"
|
||||
draft: false
|
||||
prerelease: auto
|
||||
|
||||
signs:
|
||||
- cmd: cosign
|
||||
signature: "${artifact}.sigstore.json"
|
||||
args:
|
||||
- sign-blob
|
||||
- "--bundle=${signature}"
|
||||
- "${artifact}"
|
||||
- "--yes"
|
||||
artifacts: checksum
|
||||
output: true
|
||||
@@ -64,7 +64,12 @@ to stop waiting and save the session.
|
||||
|
||||
## Build & install
|
||||
|
||||
Requirements:
|
||||
Each [GitHub release](https://github.com/lukaszraczylo/mcp-readitall/releases)
|
||||
contains `readitall` binaries for Linux, macOS and Windows (amd64 and arm64).
|
||||
Download the archive for your platform and put `readitall` on your `$PATH`.
|
||||
The browser requirement below still applies.
|
||||
|
||||
To build from source, use the following requirements:
|
||||
|
||||
- Go 1.22+
|
||||
- A Chromium-family browser on `$PATH` or installed at the standard
|
||||
|
||||
@@ -9,7 +9,6 @@ import (
|
||||
"path/filepath"
|
||||
"sort"
|
||||
"strings"
|
||||
"sync"
|
||||
"time"
|
||||
)
|
||||
|
||||
@@ -20,8 +19,6 @@ import (
|
||||
// is the same as Playwright's storage state so sessions are interchangeable.
|
||||
type SessionStore struct {
|
||||
root string
|
||||
|
||||
mu sync.Mutex
|
||||
}
|
||||
|
||||
// SessionInfo describes a persisted session, returned to the MCP client by
|
||||
|
||||
+20
@@ -0,0 +1,20 @@
|
||||
version: 1
|
||||
matching: regex
|
||||
|
||||
force:
|
||||
major: 0
|
||||
minor: 1
|
||||
patch: 0
|
||||
|
||||
blacklist:
|
||||
- "Merge branch"
|
||||
- "Merge pull request"
|
||||
- "WIP"
|
||||
|
||||
wording:
|
||||
minor:
|
||||
- '(?m)^feat(\(.+\))?!?:'
|
||||
patch:
|
||||
- '(?m)^(fix|chore|docs|test|style|refactor|build|ci|perf)(\(.+\))?:'
|
||||
major:
|
||||
- '(?m)^Semver-Major:'
|
||||
Reference in New Issue
Block a user