Skip to content

Instantly share code, notes, and snippets.

@MighteeCactus
Last active September 6, 2015 23:15
Show Gist options
  • Save MighteeCactus/2dda2b3f7e14bff27648 to your computer and use it in GitHub Desktop.
Save MighteeCactus/2dda2b3f7e14bff27648 to your computer and use it in GitHub Desktop.
Regular expression for Anki cart 日本語 ふりがな conversion
find: (.*?)>(.*?)<div>(.*?)</div>(.*?)\n
replace: $1><ruby>$2<rt>$3</rt></ruby>$4\n
find: (.?)<u>(.*?)</u>
replace: <ruby>$1<rt>$2</rt></ruby>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment