Skip to content

Implement Lisp macros #13

@srithon

Description

@srithon

Lisp macros enable terser configurations.

Here's a motivating example:

[layer]
[[private]]
homerow-mod = (kbdx-macro (key mod) (tap-hold-next-release $hmod-delay key mod))
[[keys]]
s = (homerow-mod! s lalt)
d = (homerow-mod! d lctl)
f = (homerow-mod! f lshift)

g = (homerow-mod! g lmet)
h = (homerow-mod! h lmet)

k = (homerow-mod! k lctl)
j = (homerow-mod! j rshift)
l = (homerow-mod! l ralt)

Lisp macros also supercede #3; here's its motivating example converted into an equivalent macro form:

[some-layer]
[[private]]
exit-layer = (layer-rem (get-current-layer!))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions