You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cat /etc/apache2/sites-available/*.conf | xo '/\*:443.*?ServerName\s(www\.)?([-.0-9A-Za-z]+)/$1:?www.$2/mis'
stops on the . after www, so sites that contain www. in the name are output as www..site-name.com. To fix this, we should introduce optionally wrapping fallback values within parenthesis, as well as support for escaping those parenthesis in the case that they are actually needed in the formatter.
The text was updated successfully, but these errors were encountered:
Oversight on my part. It is working correctly. If we handle allowing periods inside of fallback values then it will mess up formatting sentences, which is what xo is often used for, when the value needs to end with a period. Corrected command would be:
cat /etc/apache2/sites-available/*.conf | xo '/\*:443.*?ServerName\s(www)?\.?([-.0-9A-Za-z]+)/$1?:www.$2/mis'
For example,
cat /etc/apache2/sites-available/*.conf | xo '/\*:443.*?ServerName\s(www\.)?([-.0-9A-Za-z]+)/$1:?www.$2/mis'
stops on the
.
afterwww
, so sites that containwww.
in the name are output aswww..site-name.com
. To fix this, we should introduce optionally wrapping fallback values within parenthesis, as well as support for escaping those parenthesis in the case that they are actually needed in the formatter.The text was updated successfully, but these errors were encountered: