agzam / spacehammer

Hammerspoon config inspired by Spacemacs
MIT License
556 stars 70 forks source link

Fix the initial history not tracked #155

Closed HyunggyuJang closed 2 years ago

HyunggyuJang commented 2 years ago

Currently, the history.push ignores initial window frame information. Think it should be respected.

agzam commented 2 years ago

It's been quite a while since the last time I touched that piece. Could you please explain the problem and the change? Functionally, I'm not seeing any difference between this and what's in master ¯\_(ツ)_/¯

HyunggyuJang commented 2 years ago

For my use case, after doing some stuff with maximized window, usually, I’d like to see the ‘state’ before I jumped into the focused, maximized window. Unfortunately, without this commit, if there were no window action triggered other than maximization for that window, I couldn’t get back to the before maximization.

Here, I used maximization action as an example, but will apply for the first actions to given window.

Grazfather commented 2 years ago

Is this for undo? I don't really understand the use case either, and undo doesn't seem to work for me.

Grazfather commented 2 years ago

Actually, this helped me find a bug in my own config. We should probably be more careful with when we push.