cat test.txt
$config['useragent'] = 'Roundcube Webmail'; // Hide version number
//$config['username_domain'] = 'www.b.com'; #要去掉前面的//
$config['mime_types'] = '/etc/mime.types';
sed -i '/\/\/$config.*username_domain/ s&//&&g' test
cat test.txt
$config['useragent'] = 'Roundcube Webmail'; // Hide version number
//$config['username_domain'] = 'www.b.com'; #要去掉前面的//
$config['mime_types'] = '/etc/mime.types';
sed -i '/\/\/$config.*username_domain/ s&//&&g' test