[PATCH] Add a test for disadvised words.
David Shea
dshea at redhat.com
Wed Aug 6 19:24:35 UTC 2014
On 08/06/2014 03:12 PM, Chris Lumens wrote:
>> +# {'bad re': 'suggestion'}
>> +# All the crazy looking underscores are to catch strings with arbitrary
>> +# gtk accelerators set. (?i) makes the re case-insensitive
>> +bad_strings = {'(?i)b_?o_?o_?t_?l_?o_?a_?d_?e_?r': 'boot loader',
>> + '(?i)f_?i_?l_?e_?s_?y_?s_?t_?e_?m': 'file system',
>> + '(?i)u_?s_?e_?r_?n_?a_?m_?e': 'user name',
>> + '[Vv]_?l_?a_?n': 'VLAN',
>> + '(?i)h_?o_?s_?t_?n_?a_?m_?e': 'hostname',
>> + 'Z_?F_?C_?P': 'zFCP',
>> + 'z_?f_?c_?p': 'zFCP',
>> + 'B_?T_?R_?F_?S': 'Btrfs',
>> + 'b_?t_?r_?f_?s': 'Btrfs',
>> + '[Cc]an not': 'can not',
>> + '(?i)m_?o_?u_?n_?t_?p_?o_?i_?n_?t': 'mount point'}
> I don't know if it helps, but you can use pango to remove underscores:
>
>
str.replace() seems more straightforward. I'll try that.
More information about the anaconda-patches
mailing list