Skip to content

Commit

Permalink
fix: Allow whitespace character in license SLUG.
Browse files Browse the repository at this point in the history
This PR fixes the regex for the license SLUG by (1) allowing the space
character to occur and (2) moving the `-` to the beginning of the list
of allowed characters where it belongs.

Signed-off-by: Ingo Müller <[email protected]>
  • Loading branch information
ingomueller-net committed Oct 28, 2024
1 parent c40e51b commit e032c1c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion verify-spdx-headers
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import os
import re

SLUG = re.compile('[a-zA-Z0-9.-]+')
SLUG = re.compile('[- a-zA-Z0-9.]+')
SPDX = re.compile(f'SPDX-License-Identifier:\s+({SLUG.pattern})')

class Language:
Expand Down

0 comments on commit e032c1c

Please sign in to comment.