I gotta write a command to change the accounts in /etc/passwd that use a shell other than the bash to bash shell. those accounts that dont use a shell shouldnt get modified. assuming all the shell programs end in sh and other programs dont. and the result should go into /etc/passwd.rev
tnx a lot,
now what if I want to limit my sed further more so that it only looks for the lines that have 144 or 275 somewhere in them?
this is what I have:
sed '/.*144.*sh$/s#:[^:][^:]$#:/bin/bash#' /etc/passwd
how can I include both 144 and 275 before the "."?
tnx again