chewearn's blog - Find window ID of a process ID in BASH script

In a BASH script, I launched an application and use %u201C$!%u201D variable to grab it%u2019s process ID. I would like to perform some action on the application%u2019s main window (e.g. move or resize it). However, this requires knowing the application%u2019s window ID. How do I find the application%u2019s window ID, using only it%u2019s process ID as a starting point?

Ajouter un commentaire