Skip to content

Commit

Permalink
Merge branch 'named-data:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
zjkmxy authored Jan 16, 2023
2 parents fa09ba1 + e3d432a commit 6aeb87e
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 51 deletions.
28 changes: 17 additions & 11 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,35 @@
---
name: build
name: Build
on:
push:
pull_request:

permissions:
contents: read

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: ['ubuntu-20.04', 'windows-2019', 'macos-10.15']
os: [ubuntu-20.04, ubuntu-22.04,
macos-11, macos-12,
windows-2019, windows-2022]
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
- uses: actions/setup-go@v2
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: "^1.18"
- uses: actions/checkout@v2
- name: build without cgo
- name: Checkout repository
uses: actions/checkout@v3
- name: Build without cgo
run: make
env:
CGO_ENABLED: 0
- name: install cgo dependencies (Linux)
run: sudo apt-get install libpcap-dev
if: ${{ matrix.os == 'ubuntu-20.04' }}
- name: build with cgo
- name: Install cgo dependencies (Linux)
run: sudo apt-get -qy install libpcap-dev
if: ${{ runner.os == 'Linux' }}
- name: Build with cgo
run: make
env:
CGO_ENABLED: 1
43 changes: 11 additions & 32 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,3 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"

on:
Expand All @@ -33,39 +22,29 @@ jobs:
fail-fast: false
matrix:
language: [ 'go' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
# Learn more:
# https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Use only 'java' to analyze code written in Java, Kotlin or both
# Use only 'javascript' to analyze code written in JavaScript, TypeScript or both
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support

steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v3

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, or Java).
- name: Autobuild
uses: github/codeql-action/autobuild@v1

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release
uses: github/codeql-action/autobuild@v2

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
uses: github/codeql-action/analyze@v2
18 changes: 10 additions & 8 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,24 @@
---
name: test
on: [push, pull_request]
name: Test
on:
push:
pull_request:

jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
go-version: [1.18.x]
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
fail-fast: false
steps:
- name: Install Go
uses: actions/setup-go@v2
uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go-version }}
- name: Checkout repository
uses: actions/checkout@v2
- name: Go Imports Check
uses: actions/checkout@v3
- name: Go imports check
uses: zjkmxy/[email protected]
with:
run: imports
Expand All @@ -24,4 +27,3 @@ jobs:
run: go test ./...
env:
CGO_ENABLED: 0

0 comments on commit 6aeb87e

Please sign in to comment.