Hi,
I have got more then 3000 pages of different macros, what i need to know is how we can delete the nested macros from pages making its content as it is, we only want to remove tags from it .
currently we are using either this
pattern = fr'<ac:structured-macro\s+ac:name="{macro_name}"[^>]*>(.*?)</ac:structured-macro>|{macro_name}_\w*'
or
this pattern
pattern = fr'<ac:structured-macro\s+ac:name="{macro_name}"[^>]*>(.*?)</ac:structured-macro>|{macro_name}_\w*' 2 updated_content = re.sub(pattern, r'\1', current_content, flags=re.DOTALL)
but for few pages this is getting helpful but not for all pages, is there any specific regex which will work if the macros are in nested format
can you please help with the nested macro removal using regex irrespective of what format they ?
@Aditya Jha Welcome to the Atlassian community
Are you trying to remove them via the API?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.