Skip to content

Repository files navigation

koron-go/kcalign

PkgGoDev Actions/Go

Key code alignment library. Designed to use with QMK keymap.json.

keymapfmt - A tool to format QMK's keymap.json

kcalign includes a tool called keymapfmt. it formats "layers" property in QMK keymap.json with layout which affected its physical key alignments.

Samples:

keymapfmt: How to install

$ go install github.com/koron-go/kcalign/cmd/keymapfmt

keymapfmt: How to use

Most simple usage is reading from STDIN, writing to STDOUT.

keymapfmt [-format {format}] < in.json > out.json

Where {format} accepts two types. First type is file name, it read formatter.json from the file. See formats/_schema_.json and kcalign code for details of its schema.

Second type is pre-defined formats. It is form of @{name} or @{name}:{param}. Currently, keymapfmt includes these pre-defined formats:

  • @crkbd - crkbd. no {param} support.
  • @re64 - Re64. no {param} support.

Extended usage is reading from file.

keymapfmt [-format {format}] [-inplace] {files...}

In this form, keymapfmt read JSON from {files...} and write all to STDOUT.

When -inplace option given, keymapfmt replaces contents of each {files...} in place.

About

Key code alignment library

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages