ci.yml 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. name: CI
  2. on:
  3. workflow_call:
  4. workflow_dispatch:
  5. push:
  6. branches:
  7. - "**"
  8. tags:
  9. - "v*.*.*"
  10. paths-ignore:
  11. - "**/*.md"
  12. - "**/*.yaml"
  13. pull_request:
  14. branches:
  15. - "**"
  16. paths-ignore:
  17. - "**/*.md"
  18. - "**/*.yaml"
  19. jobs:
  20. golangci-lint-aiproxy:
  21. name: Lint AI Proxy
  22. runs-on: ubuntu-24.04
  23. steps:
  24. - name: Checkout
  25. uses: actions/checkout@v4
  26. - name: Setup Golang with cache
  27. uses: magnetikonline/action-golang-cache@v5
  28. with:
  29. go-version: "1.23"
  30. - name: Go test
  31. working-directory: core
  32. run: |
  33. go test -v -timeout 30s -count=1 ./...
  34. - name: Run Linter
  35. uses: golangci/golangci-lint-action@v6
  36. with:
  37. version: v1.64.6
  38. working-directory: core
  39. args: "--out-format colored-line-number --max-issues-per-linter 0 --max-same-issues 0 --config ./.golangci.yml"
  40. golangci-lint-openapimcp:
  41. name: Lint OpneAPI MCP
  42. runs-on: ubuntu-24.04
  43. steps:
  44. - name: Checkout
  45. uses: actions/checkout@v4
  46. - name: Setup Golang with cache
  47. uses: magnetikonline/action-golang-cache@v5
  48. with:
  49. go-version: "1.23"
  50. - name: Run Linter
  51. uses: golangci/golangci-lint-action@v6
  52. with:
  53. version: v1.64.6
  54. working-directory: openapi-mcp
  55. args: "--out-format colored-line-number --max-issues-per-linter 0 --max-same-issues 0 --config ./.golangci.yml"