Fork of Roland Kaufmann's macOS DVP keyboard layout, with Linux-style compose key sequences.
The packaged .keylayout is generated at build time from:
- Roland Kaufmann's original Programmer Dvorak macOS package.
- libX11's
en_US.UTF-8/Compose.pre, which is the default Compose table used by X11 on Linux.
The generator keeps the original DVP key maps, promotes printable key outputs into macOS keylayout actions, and emits
the representable Multi_key compose sequences from the X11 source.
The resulting compose key sequences contain all the good stuff, including:
- Full set of German, Hungarian, Serbian (Latin) characters, including ä, ő, ű, í, đ, ž, etc.
- Less common punctuations like —, –, ·, ←, →, ≤, ≥, ⇐, ⇒, «, », “, ”, …
- 🖖 (
LLAP), 💩 (poo) and a few other gems.
This flake exposes:
packages.${system}.default: a completeLibrary/Keyboard Layouts/Programmer Dvorak Compose.bundletree that can be copied into/Libraryor~/Library.overlays.default: addspkgs."programmer-dvorak-compose".homeManagerModules.default: installs the macOS bundle under~/Library/Keyboard Layouts.darwinModules.default: installs the macOS bundle globally under/Library/Keyboard Layouts.
The Home Manager entries are guarded with pkgs.stdenv.isDarwin and install the bundle as real directories with
per-file symlinks. The nix-darwin module installs the global bundle during activation by copying the Nix store files
into a real bundle. This avoids per-file symlinks, which macOS may not discover for global keyboard layouts.
Pro tip: set inputs.nixpkgs.follows to your own flake's nixpkgs input, and you'll get updates to the compose key
sequences alongise your regular updates. The result is fully consistent sequences across all your Linux & macOS
devices.
For a per-user install through Home Manager:
{
inputs.programmer-dvorak-compose.url = "github:attilaolah/programmer-dvorak-compose";
outputs = inputs @ {
programmer-dvorak-compose,
...
}: {
homeConfigurations.example = home-manager.lib.homeManagerConfiguration {
modules = [
programmer-dvorak-compose.homeManagerModules.default
];
};
};
}For a global install through nix-darwin:
{
inputs.programmer-dvorak-compose.url = "github:attilaolah/programmer-dvorak-compose";
outputs = inputs @ {
programmer-dvorak-compose,
...
}: {
darwinConfigurations.example = nix-darwin.lib.darwinSystem {
modules = [
programmer-dvorak-compose.darwinModules.default
];
};
};
}