You might be able to use a simple AWK script. Assuming your table is laid out like:
{| class="wikitable"
|-
! Years !! Name !! Alternative spellings !! Notes !! References
|-
| 1083 – ? || Ordouvin || Ordowinus || Possible first Prior before Ernulph || {{harvtxt|Hastead|1798}}
|-
| – 1150 || Walter Boxley || Philips || Boxley took his family name of Philips after the dissolution. || {{harvtxt|Hastead|1798}}
|}
You need to:
* Drop the lines starting "{|" and "|}".
* Drop lines with just a "|-"
* Convert "!" at the start of a line to "^"
* Convert "!!" to "^", likewise "||" to "|"
* Add a "|" to the end of each line (including the title, it doesn't matter at the end of a line".
Something along the lines of (this is
untested):
/{|/ {next}
/|}/ {next}
/|-/ {next}
/^!/ {$0 = "^" substr( $0, 2 )}
{
gsub( /!!/, "^" )
gsub( /||/, "|" )
printf( "%s |\n", $0 )
}