Validate conventional commit subject lines with optional scope.
^(feat|fix|docs|chore|refactor|test|perf)(\([a-z0-9-]+\))?: .{1,72}$feat(api): add health endpoint Match feature add health endpoint No Match Don't chain five separate if-statements. Use a single regex with positive lookaheads to enforce password rules like length, digits, and special characters.
Design robust username and social handle validators with clear boundaries, Unicode tradeoffs, and platform-specific constraints.
Use battle-tested regex patterns to extract timestamps, status codes, trace IDs, and error messages from noisy application logs.