aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/convert_to_utf8
blob: 2272750ebb23dedb847ae6b4bb2ab3b661dfce38 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/bash
# SPDX-License-Identifier: GPL-2.0

for file in $(find queue-* -type f | grep patch); do
	ISO=$(file "${file}" | grep ISO)
	if [ "${ISO}" != "" ] ; then
		echo "Converting ${file}"
		tmpfile=$(mktemp convert-XXXXX || exit 1)
		iconv -c --to-code=UTF-8//TRANSLIT "${file}" > "${tmpfile}"
		mv "${tmpfile}" "${file}"
	fi
done