#!/bin/bash for i in *.xm; do xxd -p "$i" > "$i"txt_t ; done for i in *.xmtxt_t; do dd if="$i" of="$i".xmtxt conv=ucase ; done for i in *.xmtxt_t; do rm "$i" ; done