#!/bin/bash #terminate wineserver wineserver -k; #kill every exe process for i in `ps ax|grep -E "\.exe"|awk '{print $1 }'`;do kill -9 $i;done; #kill wineserver if it didn't terminate #(might corrupt Wine's registry if wineserver was still running) sleep 1 killall -9 wine wineserver; echo 'killed wine'