fastfetch-cli/fastfetch

[Question] Detect macOS yabai(Window manager)

Helloyunho opened this issue · 11 comments

Be sure to read FAQ before submitting a new issue.

Wanted features:

Currently fastfetch doesn't know I'm using yabai for window manager

Motivation:

neofetch does know I'm using a custom window manager as seen below:
CleanShot 2024-05-31 at 14 16 06@2x
But fastfetch just says Quartz:
CleanShot 2024-05-31 at 14 16 35@2x

neofetch only knows you have a process named yabai running, it doesn't know whether it is the WM yabai or not.

Same as fastfetch --wm-detect-plugin

neofetch only knows you have a process named yabai running, it doesn't know whether it is the WM yabai or not.

Same as fastfetch --wm-detect-plugin

Oh I didn't know it was separated
I tried fastfetch -c all but it still didn't detect yabai so I thought it was missing
Anyway thanks for the help!

I want to clarify it again that the wm detection is very loose. Try this

$ ln -s $(which vim) fakechunkwmfake && ./fakechunkwmfake &
$ neofetch

I want to clarify it again that the wm detection is very loose. Try this

$ ln -s $(which vim) fakechunkwmfake && ./fakechunkwmfake &
$ neofetch

CleanShot 2024-05-31 at 14 44 16@2x
WOah what?! It's based on program name 🤣

Is yabai an ancestor process of the iterm2 process? What does pstree print?

Is yabai an ancestor process of the iterm2 process? What does pstree print?

pstree is not installed on my Mac but I can say that it's not running on iTerm, rather it's a daemon(launched by launchd)

ps -ef should be ok

ps -ef should be ok

I don't really know how to read the output but it sure has yabai in it

501 10797 1 0 3:48PM ?? 1:08.68 /opt/homebrew/bin/yabai

Just paste the output here

ps -ef | pbcopy

Good. So that yabai is a daemon process. We can reduce some mis-detection by testing its ppid is 1

You can remove the process list

Rectangle output from ps -ef:

501 97721     1   0 Wed09AM ??         0:42.18 /Applications/Rectangle.app/Contents/MacOS/Rectangle

and pstree (also trimmed)

-+= 00001 root /sbin/launchd
...
 |--= 97721 matthias /Applications/Rectangle.app/Contents/MacOS/Rectangle
...

Any thing else I can do to help debug?
It still wasn't working on the lastest build for me.