line !~ /\(^#\)\|\(^[\s\t]*$\)/ Is supposed to filter empty lines and lines commented by "#" symbol at the beginning. Separately the both patterns work but with "|" operation it doesn't filter. What I missed? Roman Rytov