1

I can kill a terminal opened with xterm -hold by typing xkill and then clicking the left mouse button. But I'd like to avoid the need for the click. I would have expected that

xkill -id `echo $$`

would work, but it throws an error. Could somebody please tell me how to accomplish this?

1

Yeah, the manual description is not clear, but you need to specify the window ID, not the PID. In Xterm,

xkill -id "$WINDOWID"

In all terminals,

xkill -id "$(xdotool getactivewindow)"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.