#!/bin/sh which potool &>/dev/null || { echo "potool not found - try 'apt-get install potool'" >&2; exit 1; } PROJ_DIR=$(cd "$(dirname $0)/.."; pwd) find "$PROJ_DIR/intl" "$PROJ_DIR/plugins" -type f -name \*.po | grep /intl/en/ | while read a do potool -c -n scmt "$a" > "${a}.new" && mv "${a}.new" "$a" done