Skip to content

Instantly share code, notes, and snippets.

@bendera
Created January 19, 2020 15:06
Show Gist options
  • Save bendera/c8ca9aff0c9a9450388c1ba0d8245e83 to your computer and use it in GitHub Desktop.
Save bendera/c8ca9aff0c9a9450388c1ba0d8245e83 to your computer and use it in GitHub Desktop.
#!/bin/bash
# Fix the commonly misspelled Hungarian accents
# Replace ÕõŨũÔôÛû characters to ŐőŰűŐőŰű
# Usage: hunaccents filename.txt
sed -i -e 's/Õ/Ő/g' "$1"
sed -i -e 's/õ/ő/g' "$1"
sed -i -e 's/Ũ/Ű/g' "$1"
sed -i -e 's/ũ/ű/g' "$1"
sed -i -e 's/Ô/Ő/g' "$1"
sed -i -e 's/ô/ő/g' "$1"
sed -i -e 's/Û/Ű/g' "$1"
sed -i -e 's/û/ű/g' "$1"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment