github.com/vishvananda/netlink@v1.3.0/.github/workflows/main.yml (about)

     1  name: Main 
     2  
     3  on:
     4    push:
     5      branches: [ main ]
     6    pull_request:
     7      branches: [ main ]
     8  
     9  jobs:
    10  
    11    build:
    12      runs-on: ubuntu-latest
    13      steps:
    14      - uses: actions/checkout@v2
    15  
    16      - name: Set up Go
    17        uses: actions/setup-go@v2
    18        with:
    19          go-version: 1.17
    20  
    21      - name: Kernel Modules
    22        run: ./.github/scripts/modprobe.sh
    23        shell: bash
    24  
    25      - name: Test
    26        run: sudo -E env PATH=$PATH go test -v ./ ./nl
    27  
    28    build-macos:
    29      # netlink is Linux-only, but this ensures that netlink builds without error
    30      # on macOS, which helps catch missing build tags.
    31      runs-on: macos-latest
    32      steps:
    33      - uses: actions/checkout@v2
    34  
    35      - name: Set up Go
    36        uses: actions/setup-go@v2
    37        with:
    38          go-version: 1.17
    39            
    40      - name: Build
    41        run: go build ./...
    42  
    43      - name: Test
    44        run: go test ./...