Re: [PATCH/RFC] Add userdiff built-in pattern for CSS code
- From
Matthieu Moy <matthieu.moy@grenoble-inp.fr>
- Date
- May 19, 2016, 14:45 UTC
- Message-ID
- <840800650.10903639.1463669101272.JavaMail.zimbra@imag.fr>
- In-Reply-To
- <20160519100625.7945-1-william.duclot@ensimag.grenoble-inp.fr>
> Subject: [PATCH/RFC] Add userdiff built-in pattern for CSS code
We normally write subject lines as "<subsystem>: <description", hence that would be:
userdiff: add built-in pattern for CSS
william.duclot@ensimag.grenoble-inp.fr wrote:
Show 5 quoted lines
> CSS is widely used, motivating it being included as a built-in pattern. > It must be noted that the word_regex for CSS (i.e. the regex defining what is > a word in the language) does not consider '.' and '#' characters (in CSS > selectors) to be part of the word. This behavior is documented by the test > t/t4018/css-rule.
This text wasn't properly wrapped. Please wrap around 72 columns (M-q on Emacs, or google "text wrap $youreditor" for others).
Also, saying _what_ your patch does is not the most important question here. Focus on the _why_ in the commit message.
(We had a real-life off-list discussion about this and I agree that it's a sensible behavior, but others may disagree)
> Add the info in documentation that CSS is now built-in.
This doesn't add much to the patch (we can already see that from the patch itself). I'd remove it.
Missing sign-off (yours, and you can add mine to mark the fact that I allow you to contribute to Git as part of your student project).
> +PATTERNS("css",
> + "^([^,{}]+)((,[^}]*\\{)|([ \t]*\\{))$",
> + /* -- */
> + /* This regex comes from W3C CSS specs. Should theorically also allow ISOs/theorically/theoretically/
-- Matthieu Moy http://www-verimag.imag.fr/~moy/