I spent quite a bit of time writing my configuration for Phoenix, if you're thinking about writing your own I think you might find starting from mine useful.
It's easy to customize, there are gifs in the readme, and it comes packed with features, I hope you'll like it:
One could take a similar approach to mine, but use the list of spaces in an application other than Alfred, or just use the shortcuts macOS provides. I'm not aware of any already available alternative.
After many ours spent on several scriptable window managers I've settled on Spectacle, which is a lot less powerful, but proved to be enough for me, while being dead easy and hassle free.
I use MacOS at home and happily use Hammerspoon to manage these interactions, in the past using Slate—I use Windows at work and I really wish it had something better than AutoHotKey: is this just something I'm unaware of or does the design of windows really hamper the creation of tools like these?
I've been using Phoenix for 2 years straight and it's been pretty smooth sailings. Kasper has done an excellent job maintaining and implementing new features every once in a while, thanks Kasper!
My personal configuration is written in TypeScript and I maintain typings for Phoenix as well. I try to find ways to improve my every-day and implement them in Phoenix, things like: moving/resizing windows, coffee timer, monitor brightness, terminal hotkey, etc. In the past I've used it to track what applications I spend my time in or to automatically switch Karabiner-Element profiles based on which monitor is connected. If you're looking for inspiration, feel free to have a look:
I have a 34" 1440p screen and I use Mozaic.app (https://www.lightpillar.com/mosaic.html) for managing my windows. Usually, i'll divide my windows as either 1:1, 1:2:1 or 1:4 sizes. It's pretty useful as I can use keyboard shortcuts to position my windows. Is there any added benefits that I can get by using phoenix or hammerspoon?
As a hammerspoon user, probably not if that's all you're using it for. Hammerspoon does add a bunch of extra features mosaic doesn't add—but if you don't need them and you've already invested in software to solve your problem: not likely.
Basically the same reason you're using mosaic + the ability to change what exactly is being done. I use it to map 'hyper'+key (where hyper is the equivalent of ctrl+cmd+shift+option and is assigned to control, capslock is assigned to the original control functionality) to move windows between screens and on their own grid. Effectively I just didn't pay for mosaic-like functionality. I have better touch tool, but I never liked having to drag to snap and had hammerspoon implemented already.
My use case is to split the screen in two, editor on one side and terminal on the other. I specifically want the terminal to be 80 characters wide (inside that window I use tmux), and the editor to take up the rest of the space.
I've tried most of the simpler, GUI-based window managers for macOS but I haven't found one that let's me set window sizes explicitly in pixels yet. With hammerspoon I figure out the width of the terminal app I want, and adjust the windows accordingly.
Both Phoenix and Hammerspoon are free and open-source. You can also configure them in endless ways, so either you can have a really simple setup or a very dynamic one that works just the way you like.
Say for example you want to do something dynamically when an app launches. You could open an app and the windows would automatically be arranged across your monitors the way you want.
I’ve tried tiling WM (well, MacOS’ Amethyst, before that used kwm for a while, used fluxbox a long time ago on arch which can be used with tiling) but still can’t get the “why”, they don’t help my process and mostly stand on my way. Anything I’m missing? What do you find so changing?
What I find valuable in a tiling window manager is what it doesn't have. Usually, I want a window full screen. Ocassionally, I want two windows side by side. I can't think of a time I want a window halfway transparent with its upper left corner at (0,32) that's partially occulding another window. It's just so much faster when all the things I don't want to do aren't possible.
My issue is that 90% of the time I just need all my windows full screen (and it's always at least 3 of them), and in the rare occasions I don't, I don't mind setting up something ad-hoc. But then, tiling gets in the way by trying to maximise or reposition everything when I open anything new, or I need to add more virtual desktops/screens
A few reasons:
- I know what is going to happen when I open anything and can get things where they need to be very quickly (since it is keyboard driven).
- The wm is working with me to use the entire screen.
- You can always revert to making windows float if you need it.
Basically I always get tripped with the fact that I always, always have emacs in full screen, as well as a terminal also maximised. Then I end up needing 5 or 6 spaces to hold all the windows I open and close during the day and starts to get hard to manage. But thanks for sharing your perspective, knowing me, I'll retry in a few months :)
Can you configure the margins between those three terminal windows? I currently use Tmux with one fullscreen terminal to achieve a similar effect, but this looks interesting too. I'd like to eliminate any margins though. A one-pixel border is all I would want.
I have yet to use chunkwm, but I have tried a few of the precursors. They were all nice, but super glitchy, especially when it comes to multiple monitors. Does any of that seem better with chunkwm?
I've just tried it out with one external monitor (laptop + external) and chunkwm works as expected. Don't know how that scales past 1 external monitor though.
Just a quick question for current Phoenix users — how is the multiple monitor performance? By that I mean a situation where I'm going from just the MacBook screen to three monitors on one desk to four monitors on another desk. Will it automatically detect how many monitors are present, without having to resort to hardware-specific configurations? This is a killer feature for me on Hammerspoon, but I much rather script with JS than Lua, out of familiarity.
I moved from MacOS to Linux for my desktop machine and still use a Macbook with MacOS on the go. I've tried chunkwm, Spectacle, and a few odd ones on GitHub. But none really come anywhere close to something like i3 on Linux if you're looking for a good window manager. MacOS is just too limited if you really want to have a predefined setup of (work)spaces and window regions.
Hammerspoon uses Lua for the configuration language. Phoenix uses JavaScript, or anything that translates to it. Personally I think Phoenix’s API is much simpler and easier to understand, but I’m of course bias. :) Hammerspoon does have some additional features that go beyond window and app management. Phoenix doesn’t cover those.
Wow. The named spaces switcher seems promising to me.
I think it would be great to have custom names for spaces, and assign various apps to each space, and then be able to log the time spent in each space to a text file.
In many conceptual ways, such as sharing the same language for configuration, though this is a completely different project so they don’t share the same origin. Slate has become rather abandoned and unsupported nowadays. Phoenix hopefully continues strong in this area.
It's easy to customize, there are gifs in the readme, and it comes packed with features, I hope you'll like it:
https://github.com/fabiospampinato/phoenix