Skip to content

Commit

Permalink
upgrade os
Browse files Browse the repository at this point in the history
  • Loading branch information
flier committed Oct 22, 2024
1 parent d1efc44 commit c81811d
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 32 deletions.
45 changes: 13 additions & 32 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ on:
push:
branches:
- master
- "feature/**"
- "releases/**"
paths-ignore:
- "**.md"
pull_request:
Expand All @@ -18,8 +20,8 @@ jobs:
test:
strategy:
matrix:
os: [ubuntu-22.04, ubuntu-20.04, macos-12, macos-11]
go: [stable, 1.20.x, 1.19.x, 1.18.x]
os: [ubuntu-24.04, ubuntu-22.04, macos-15, macos-14]
go: [stable, 1.23.x, 1.22.x, 1.21.x]
name: Go ${{ matrix.go }} tests @ ${{ matrix.os }} for hyperscan
runs-on: ${{ matrix.os }}
steps:
Expand All @@ -34,13 +36,12 @@ jobs:
run: |
brew install hyperscan pkg-config libpcap
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Install Golang ${{ matrix.go }}
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
cache: true

- name: Test Hyperscan v4 API
run: |
Expand All @@ -58,30 +59,30 @@ jobs:
include:
- os: macos-latest
go: stable
hyperscan_version: 5.4.1
hyperscan_version: 5.4.2
pcre_version: 8.45
build_flags: -tags hyperscan_v54,chimera
chimera: true
- os: macos-12
- os: macos-14
go: stable
hyperscan_version: 5.2.1
pcre_version: 8.45
build_flags: -tags hyperscan_v52,chimera
chimera: true
- os: macos-11
- os: macos-13
go: stable
hyperscan_version: 5.1.1
pcre_version: 8.45
build_flags: -tags chimera
chimera: true
- os: ubuntu-22.04
- os: ubuntu-24.04
go: stable
hyperscan_version: 5.4.1
pcre_version: 8.45
build_flags: -tags hyperscan_v54,chimera
chimera: true
coverage: true
- os: ubuntu-20.04
- os: ubuntu-22.04
go: stable
hyperscan_version: 5.2.1
pcre_version: 8.45
Expand All @@ -94,7 +95,7 @@ jobs:
CGO_CFLAGS: -I${{ github.workspace }}/dist/include/hs
CGO_LDFLAGS: -L${{ github.workspace }}/dist/lib
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Install Hyperscan ${{ matrix.hyperscan }} with PCRE ${{ matrix.pcre_version }}
uses: flier/install-hyperscan@main
Expand All @@ -107,10 +108,9 @@ jobs:
cache_key: ${{ runner.os }}-build-hyperscan-${{ matrix.hyperscan_version }}-pcre-${{ matrix.pcre_version }}

- name: Install Golang ${{ matrix.go }}
uses: actions/setup-go@v3
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
cache: true

- name: Test Hyperscan API
run: |
Expand All @@ -130,22 +130,3 @@ jobs:
run: |
go test -v ${{ matrix.build_flags }} -race -coverprofile=coverage.out -covermode=atomic ./...
bash <(curl -s https://codecov.io/bash)
golangci:
name: lint
runs-on: ubuntu-22.04
steps:
- name: Install Linux dependencies
run: |
sudo apt-get update
sudo apt-get install -yq libhyperscan-dev libpcap-dev
- uses: actions/setup-go@v3

- uses: actions/checkout@v3

- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: latest
working-directory: hyperscan
33 changes: 33 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: golangci-lint
on:
push:
branches:
- main
- master
pull_request:

permissions:
contents: read
# Optional: allow read access to pull request. Use with `only-new-issues` option.
# pull-requests: read

jobs:
golangci:
name: lint
runs-on: ubuntu-latest
steps:
- name: Install Linux dependencies
run: |
sudo apt-get update
sudo apt-get install -yq libhyperscan-dev libpcap-dev
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: stable

- name: golangci-lint
uses: golangci/golangci-lint-action@v6
with:
version: latest
working-directory: hyperscan

0 comments on commit c81811d

Please sign in to comment.