I have written the following code:
who | while read x; do
echo $x | grep '.co.uk' | cut -d' ' -f2;
What I want to do is find out if any users have logged in to the system through a ".co.uk" domain. If they have then I want to run skill -KILL -t <terminal> against that entry.
How do I amend this code to get this working?