I guess you could do this:

    echo "TMOUT=$(units -t '7 days' seconds)" >> .bashrc
If a shell has been sitting at the prompt for 7 days with no input, it's probably OK for it to close. I'm sure it'll be wrong sometimes, but it seems less bad than pkill en masse.