Skip to content

Commit 6aebd1b

Browse files
committed
Fixes a regex for language and locale recognition
See oasis-tcs/sarif-spec#490 See #418 Note that this changes the sarif spec file. Unless this change is actually merged in the sarif spec repo, the version used by the action will be slightly different.
1 parent 0c2281f commit 6aebd1b

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

src/sarif_v2.1.0_schema.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2339,9 +2339,8 @@
23392339
"description": "The language of the messages emitted into the log file during this run (expressed as an ISO 639-1 two-letter lowercase culture code) and an optional region (expressed as an ISO 3166-1 two-letter uppercase subculture code associated with a country or region). The casing is recommended but not required (in order for this data to conform to RFC5646).",
23402340
"type": "string",
23412341
"default": "en-US",
2342-
"pattern": "^[a-zA-Z]{2}|^[a-zA-Z]{2}-[a-zA-Z]{2}]?$"
2342+
"pattern": "^[a-zA-Z]{2}(-[a-zA-Z]{2})?$"
23432343
},
2344-
23452344
"versionControlProvenance": {
23462345
"description": "Specifies the revision in version control of the artifacts that were scanned.",
23472346
"type": "array",
@@ -3040,7 +3039,7 @@
30403039
"description": "The language of the messages emitted into the log file during this run (expressed as an ISO 639-1 two-letter lowercase language code) and an optional region (expressed as an ISO 3166-1 two-letter uppercase subculture code associated with a country or region). The casing is recommended but not required (in order for this data to conform to RFC5646).",
30413040
"type": "string",
30423041
"default": "en-US",
3043-
"pattern": "^[a-zA-Z]{2}|^[a-zA-Z]{2}-[a-zA-Z]{2}]?$"
3042+
"pattern": "^[a-zA-Z]{2}(-[a-zA-Z]{2})?$"
30443043
},
30453044

30463045
"contents": {

0 commit comments

Comments
 (0)