I am fixing the spell of some articles withreplace.py
by replacing "choeur" by "chœur".
There are also file links in the mediawiki syntax :
[[Fichier:Menditte (Pyr-Atl, Fr) choeur de l'église.JpG|thumb|Chœur de l'église]]
Editing that kind of thing will broke the link. I can't use []
because there's also the link description :
[[Fichier:JeronimosRoyalTombs.Jpg|thumb|right|Tombeaux de [[Jean III de Portugal]] (à gauche) et de [[Catherine de Castille]] (à droite) dans la choeur de l'église]]
In that case, the spell should be fixed.
So I need to not do the edit if there is.jpg
on the same line and after "choeur".
My problem is I couldn't find the way to handle boolean expressions inside python regex