User:Bookofjude/header cleanup

From Wikisource
Jump to navigation Jump to search

I've recently been cleaning up the headers on various texts.

Completed:

In progress:

Tools:

  • Regexps (double-escaped for use in JavaScripts):
    • Eaton's Bible Dictionary
      • search: <div[\\s\\S\\n\\R]*\\[\\[EBD1897:([^|]*)\\|[^\\]]*\\]\\][\\s\\S\\n\\R]*\\[\\[EBD1897:([^|]*)\\|[^\\]]*\\]\\][\\s\\S\\n\\R]*\\[\\[w:([^|]*)\\|[^\\]]*\\]\\][\\s\\S\\n\\R]*</div>
      • replace: {{EBDHeader|previous=$1|next=$2|wikipedia=$3}}
      • search: {{EBD1897 entry\\|([^|]*)\\|([^|]*)\\|([^}]*)}}
      • replace: {{EBDheader|previous=$1|next=$2|wikipedia=$3}}
    • Emily Dickinson
      • search: <table.*>\\n<tr><td.*>([^\\r\\n]*)\\n<tr><td>Written by:<td>[\\s\\S\\r\\n]*<tr><td>Poem #:<td>'''([0-9]+)'''\\n[^']*<tr><td>'''Preceded by:'''<td>'''\\[\\[([^\\]]*)\\]\\] -([0-9]+)-'''\\n<tr><td>'''Succeeded by:'''<td>'''\\[\\[([^\\]]*)\\]\\] -([0-9]+)-'''\\n[\\s\\S\\r\\n]*\\[\\[w:([^\\|]*)\\|Wikipedia article\\]\\]\\n</table>
      • replace: {{EDheader|title=$1|number=$2|prevt=$3|prevn=$4|nextt=$5|nextn=$6|wikipedia=$7}}
    • Non-specific regexps:
      • (pipe relative links) search: \\[\\[\\.\\./([^|\\]]*)\\]\\]
      • replace: [[../$1|$1]]