Skip to content

Commit

Permalink
ci: add Github Action to check license header
Browse files Browse the repository at this point in the history
  • Loading branch information
torives committed Nov 23, 2023
1 parent bd15112 commit 6295b94
Show file tree
Hide file tree
Showing 4 changed files with 16,384 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/license-check/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[
{
"include": ["**/*.go", "**/*.rs"],
"exclude": ["offchain/target/**"],
"license": ".github/license-check/header.txt"
}
]
2 changes: 2 additions & 0 deletions .github/license-check/header.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
// (c) Cartesi and individual authors (see AUTHORS)
// SPDX-License-Identifier: Apache-2.0 (see LICENSE)
24 changes: 24 additions & 0 deletions .github/workflows/license-header.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
name: Check license header

on:
push:
paths:
- ".github/workflows/license-header.yml"
- ".github/license-check"
- "cmd/**"
- "internal/**"
- "offchain/**"
jobs:
check-copyright:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
with:
submodules: recursive

- uses: viperproject/check-license-header@v2
with:
path: ./
config: .github/license-check/config.json
Loading

0 comments on commit 6295b94

Please sign in to comment.