Skip to content

Commit

Permalink
Update copyright_check.py
Browse files Browse the repository at this point in the history
Add `%` as a valid comment starter.
  • Loading branch information
celinval authored Sep 4, 2024
1 parent d51ddfe commit eb64bf4
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions scripts/ci/copyright_check.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
from itertools import chain


COMMENT_OR_EMPTY_PATTERN = '^(//.*$|#.*$|\\s*$)'
COMMENT_OR_EMPTY_PATTERN = '^(//.*$|#.*$|\\s*$||%.*$)'

STANDARD_HEADER_PATTERN_1 = '(//|#) Copyright Kani Contributors'
STANDARD_HEADER_PATTERN_2 = '(//|#) SPDX-License-Identifier: Apache-2.0 OR MIT'
STANDARD_HEADER_PATTERN_1 = '(//|#|%) Copyright Kani Contributors'
STANDARD_HEADER_PATTERN_2 = '(//|#|%) SPDX-License-Identifier: Apache-2.0 OR MIT'

MODIFIED_HEADER_PATTERN_1 = '(//|#) SPDX-License-Identifier: Apache-2.0 OR MIT'
MODIFIED_HEADER_PATTERN_1 = '(//|#|%) SPDX-License-Identifier: Apache-2.0 OR MIT'
MODIFIED_HEADER_PATTERN_2 = COMMENT_OR_EMPTY_PATTERN
MODIFIED_HEADER_PATTERN_3 = '(//|#) Modifications Copyright Kani Contributors'
MODIFIED_HEADER_PATTERN_4 = '(//|#) See GitHub history for details.'
MODIFIED_HEADER_PATTERN_3 = '(//|#|%) Modifications Copyright Kani Contributors'
MODIFIED_HEADER_PATTERN_4 = '(//|#|%) See GitHub history for details.'

class CheckResult(Enum):
FAIL = 1
Expand Down

0 comments on commit eb64bf4

Please sign in to comment.