Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Add window condition for executable path prefix #359

Open
graywolf opened this issue Aug 5, 2024 · 1 comment
Open

Add window condition for executable path prefix #359

graywolf opened this issue Aug 5, 2024 · 1 comment
Labels
feature-proposal A well defined feature proposal triaged The issue makes sense to maintainers

Comments

@graywolf
Copy link

graywolf commented Aug 5, 2024

Hello,

I am trying to use the on-window-detected callback to move a window, and I am having trouble differentiating between two windows with the same application id. The application in question is Firefox. I need to have two separate profiles running at the same time, one for hardened browsing, other for Zoom. Using cp -r I ended up with /Applications/Firefox.app and /Applications/Firefox for Zoom.app. It works fine it seems.

However when I want to place one firefox on workspace 2, and other on workspace 4, I am unsure how to currently do it. Both have the same application id, so if.app-id cannot be used. Matching on window title will not work either, since the title differs based on the active tabs.

The solution for me would be to introduce new condition, for example if.app-path-prefix, so I could do

[[on-window-detected]]
if.app-path-prefix = '/Applications/Firefox.app/'
run = 'move-node-to-workspace 2'

[[on-window-detected]]
if.app-path-prefix = '/Applications/Firefox for Zoom.app/'
run = 'move-node-to-workspace 4'

Thank you for considering this feature.

(As off-topic note at the end, thank you, AeroSpace is great. When I was forced to switch to Mac few days back, the usability was horrible. Then I installed AeroSpace, ported over my i3 config, and suddenly I no longer want to shoot my brain out. So, thanks a lot.)

@nikitabobko
Copy link
Owner

Feature like this makes total sense. Some GUI applications don't even have a App Bundle ID (If I remember correclty, Android emulator is such)

But since I plan to implement an alternative syntax for on-window-detected callback #278 , I want to finish that first before adding any new features to the callback

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
feature-proposal A well defined feature proposal triaged The issue makes sense to maintainers
Projects
None yet
Development

No branches or pull requests

2 participants