Plubi

1

votes
1

answer
47

views

How to hide text after matching and before keyword in regular expressions?

I would like to match any user comment until KEYWORD. Also I would like to skip variable unimportant text after last comment before keyword. import re` string = ''' COMMENTS: first comment /user_x second comment two lines /user_y Here is some unimportant text. KEYWORD: Don't match comments aft...
Plubi