Remix.run Logo
pjm331 19 hours ago

here is my entire config

    hs.hotkey.bind({"ctrl"}, "D", function()
      hs.grid.show()
    end)
i've tried all of the other fancy window managers and for me nothing has ever beat the ease of use of just

(1) ctrl-d to see the grid, (2) type the letter where you want the top left corner of your window to be, (3) type the letter where you want the bottom right corner to be

window resized

matthewmc3 14 hours ago | parent | next [-]

Wow... that's... incredible. I've used Hammerspoon forever and never knew that existed.

Just messing around I found you can extend the grid size with `hs.grid.setGrid('4x4')`, which you also may then want to shrink the text size with `hs.grid.ui.textSize = 30`, and finally if you use an alternative keyboard layout (eg: Colemak), you can set the grid to use it with `hs.grid.HINTS`. They really thought of everything with this feature.

elAhmo 18 hours ago | parent | prev | next [-]

This is amazing! I have a slightly more elaborate setup that allows me to resize from one or another side, similar to what Apple added recently but with more flexibility, but this is super interesting, thanks for sharing!

hrmtst93837 17 hours ago | parent | prev | next [-]

Neat until you need to sync configs or keep multiple machines in harmony, at which point dotfile headaches stack up with Hammerspoon and Lua. Adding complex logic like window rules, app-specific behavior, or handling monitor changes strips away some of that hotkey simplicity and leads to endless tweaking. Still, for avoiding the mouse, it's one of the few flexible options left on macOS that doesn't feel ancient. Tradeoffs everywhere but nowhere else really compares in control.

dbalatero 15 hours ago | parent [-]

Syncing configs is a pretty solved problem with dotfile repos. I even made a starter repo anyone can fork & use: https://github.com/dbalatero/dotfiles-starter

stackghost 18 hours ago | parent | prev [-]

Not that I insert EOFs very often, but does that conflict with CTRL+D in the terminal?

xyzzy_plugh 18 hours ago | parent | next [-]

I use EOF all the time to end terminal sessions.

commandertso 17 hours ago | parent [-]

Great handle, btw.

theshrike79 17 hours ago | parent | prev | next [-]

Make caps lock a hyperkey (shift+ctrl+option+cmd) and use that for non-overlapping shortcuts

1-more 16 hours ago | parent [-]

make caps lock control on hold, double quote on tap. Make control hyperkey on hold, angle bracket on tap. My keyboard firmware is very odd. This is not easily done with soft remaps to the point that I don't bother trying.

dbalatero 10 hours ago | parent [-]

If you're on macOS have you tried Karabiner Elements? It seems to do just fine with software mapping my macbook keyboard.

pjm331 17 hours ago | parent | prev [-]

yeah the CTRL+D definitely gives me problems from time to time but thus far i have been too lazy to fix it