Skip to main content

Deterministic Glove80 layout toolkit

Project description

Glove80 Layout Toolkit

This repository is the canonical, code-first source of the Glove80 layout families (Default, TailorKey, QuantumTouch, and Glorious Engrammer). Every release JSON under layouts/*/releases can be regenerated deterministically from the declarative specs and metadata checked into src/glove80.

Why this exists: TailorKey (and now QuantumTouch, Glorious Engrammer, etc.) used to be kept in sync by hand in the layout editor, which made even trivial tweaks error-prone and slow to propagate across Windows/macOS/Dual/Bilateral variants. By expressing every layer, macro, combo, and alpha layout in Python, we get reproducible builds, automated regression tests, and the ability to spin up new variants (Colemak, Colemak-DH, Dvorak, custom mixes) by reusing the same building blocks instead of copying JSON around. You can still download the generated JSON into the editor for visualization, but the code here is the single source of truth that guarantees consistency.

Highlights

  • The default, TailorKey, QuantumTouch, and Glorious Engrammer families live under src/glove80/families/ with typed specs, factories, and regression tests.
  • Metadata travels with the package (src/glove80/families/*/metadata.json), so the CLI and library always agree on UUIDs, release notes, and output paths.
  • A Typer-powered CLI (glove80 generate …) replaces ad-hoc scripts and keeps the regeneration workflow uniform across layouts.
  • Release artifacts are grouped under layouts/<layout>/releases, keeping the repo root clean while preserving the published JSON verbatim.

Quick Start

  1. Install dependencies (the repo uses uv):
    uv sync
    
  2. Regenerate every release JSON:
    just regen
    
  3. Run the full regression suite (per-layer tests + layout parity checks):
    just ci
    
  4. Need a single variant? Use the CLI directly:
    glove80 generate --layout tailorkey --variant mac
    

just --list shows the available helper tasks.

Using the Python API

The public API lives on the root package:

from glove80 import build_layout, list_families

print(list_families())  # ['default', 'tailorkey', 'quantum_touch', 'glorious_engrammer']
layout = build_layout("tailorkey", "mac")

build_layout(<family>, <variant>) always returns the same dictionary that the CLI would write into layouts/<family>/releases/….

Repository Layout

.
├─ layouts/                     # checked-in release JSON + layout-specific README.md files
│  ├─ default/
│  │  └─ releases/
│  ├─ tailorkey/
│  │  └─ releases/
│  ├─ quantum_touch/
│  │  └─ releases/
│  └─ glorious-engrammer/
│     └─ releases/
├─ docs/                        # architecture overview
├─ src/glove80/
│  ├─ cli/                      # Typer CLI
│  ├─ layouts/                  # registry, common helpers, CLI wiring
│  └─ families/                 # default, TailorKey, QuantumTouch, Glorious Engrammer implementations + metadata
│     ├─ default/
│     ├─ tailorkey/
│     ├─ quantum_touch/
│     └─ glorious_engrammer/
└─ tests/                       # split by layout family
  • Read docs/architecture.md for a walkthrough of the data flow and regeneration pipeline.
  • layouts/default/README.md, layouts/tailorkey/README.md, layouts/quantum_touch/README.md, and layouts/glorious-engrammer/README.md explain how each layout family is structured, the available layers, and the steps for adding new variants.

CI Contract

.github/workflows/ci.yml runs the same steps you do locally:

  • just regen must leave layouts/*/releases unchanged or the build fails, proving the checked-in JSON matches the current code.
  • just ci (uv run pytest) covers every layer factory plus whole-layout comparisons.
  • Pull requests are required to keep both commands clean, so regeneration plus tests are the only gatekeepers.

Contributing

  1. Edit specs or metadata, re-run just regen, and inspect the resulting diffs under layouts/.
  2. Extend/adjust the targeted per-layer tests under tests/<layout>/ when you change behavior.
  3. Document intentional changes in the relevant layouts/<family>/README.md (and docs/architecture.md if the pipeline changes) so future contributors understand the rationale.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

glove80-1.2.0.tar.gz (319.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

glove80-1.2.0-py3-none-any.whl (111.1 kB view details)

Uploaded Python 3

File details

Details for the file glove80-1.2.0.tar.gz.

File metadata

  • Download URL: glove80-1.2.0.tar.gz
  • Upload date:
  • Size: 319.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for glove80-1.2.0.tar.gz
Algorithm Hash digest
SHA256 dc1cb096fb4aab6d5299669cc3550be116d6cd4919dbd69ec78d7cc57129a7a3
MD5 f28ecaf22342999ec2707e9727293ac3
BLAKE2b-256 fe31d62463eef628e0e941e81873d06ba9222716e0cc80fe9e5cf8efb734acf9

See more details on using hashes here.

Provenance

The following attestation bundles were made for glove80-1.2.0.tar.gz:

Publisher: release.yml on basnijholt/glove80

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file glove80-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: glove80-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 111.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for glove80-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f510dbb7e1de54ff74952f0edbd6e590bd00e18790a589eea702f9d33c3ad3f4
MD5 7564c79803686541101e656da24f82f8
BLAKE2b-256 c1717cb993a49182583e1c498209927eb6076517094db35306feca0dc2130468

See more details on using hashes here.

Provenance

The following attestation bundles were made for glove80-1.2.0-py3-none-any.whl:

Publisher: release.yml on basnijholt/glove80

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page