Double-space to period, everywhere on Linux.
Tap Space twice after a word. Get a period. Keep typing.
hello world
+
Space Space
→
hello world.
period-space brings the familiar iOS and macOS double-space shortcut to Linux. It remaps your keyboard at the device level with keyd, so the shortcut works across your entire system—not just inside one app.
Terminal, editor, browser, desktop, or raw TTY: if you can type there, period-space works there.
- System-wide — one setup for every app
- Desktop-agnostic — works on Wayland, X11, GNOME, KDE, niri, and more
- Shortcut-safe — Ctrl, Alt, Super, and AltGr + Space keep their normal behavior
- Lightweight — a small controller and one focused keyd configuration
- Yours to tune — adjust the timing with a single config value
One command. No clone required.
curl -fsSL https://hapwi.github.io/install/period-space.sh | bashThe installer downloads the latest stable GitHub Release to /usr/local/bin, verifies its checksum, creates your user config, installs keyd when needed, and enables the shortcut. It requests sudo once for the system-wide command and keyboard access.
Note
Requires Linux with Python 3, sudo, and systemd.
| Distribution | Installation path |
|---|---|
| Fedora / RHEL family | COPR via dnf |
| Arch / Manjaro | pacman |
| Ubuntu / Mint / Pop!_OS | apt, with the keyd PPA on older Ubuntu releases |
| Debian 13+ | apt |
| openSUSE | zypper |
Other systemd distributions fall back to building the latest keyd release from source. If keyd is already available on your PATH, the installer leaves it alone.
Install from a local clone
git clone https://github.com/hapwi/period-space.git
cd period-space
./install.shNixOS and non-systemd systems
NixOS: enable keyd in configuration.nix, rebuild, then rerun the quick install command. From a clone, use python3 period-space install --enable.
OpenRC / runit: automatic service setup is not supported yet. You can install keyd manually to experiment, but period-space on currently expects systemctl.
App-specific plugins only work where you install them. Desktop extensions stop at the edge of the desktop. Shell settings stop at the terminal.
period-space sits below all of them.
The keyboard event is transformed before it reaches your compositor or application. Type Write the sentence, tap Space twice, and every app receives Write the sentence. .
| Command | Purpose |
|---|---|
period-space on |
Enable the mapping and start keyd |
period-space off |
Remove the mapping while keeping keyd installed |
period-space status |
Show the config, service, and feature status |
period-space reload |
Apply changes from your user config |
period-space update |
Check for a newer release and ask before installing it |
period-space --version |
Print the installed version |
Try it after installation: type a word, then tap Space twice. You should get word. .
period-space updateThe updater reports your installed version and the latest stable release. When a newer version exists, it asks before downloading and verifying the release:
current version: 1.0.0
latest version: 1.0.1
Install period-space 1.0.1? [y/N]
For scripts and unattended upgrades, use period-space update --yes. Your personal config at ~/.config/period-space/keyd.conf is never overwritten.
Publishing a release
- Update
VERSIONin theperiod-spaceCLI. - Commit the release changes.
- Tag that commit with the matching version, such as
v1.0.1. - Push the tag to GitHub.
The release workflow validates the version, generates SHA-256 checksums, and publishes the CLI, config, and installer as GitHub Release assets.
Your config lives at:
~/.config/period-space/keyd.conf
Change the double-space window by editing oneshot_timeout, then run period-space reload:
[global]
oneshot_timeout = 400Raise the value if you type slowly. Lower it if accidental double-spaces are becoming periods.
Exclude a mouse, headset, or gamepad
Some devices advertise a keyboard interface and may need to be excluded. First, find the device ID:
keyd monitorThen add it to your config:
[ids]
*
-1532:007dApply the change with period-space reload.
period-space manages the setup; keyd handles the always-on remapping.
- The first Space is emitted normally and opens a short timing window.
- A second Space inside that window becomes Backspace,
., Space. - The window closes. A third Space behaves normally.
Because the transformation happens at the input-device level, every desktop, compositor, terminal, and TTY receives the same finished . .
Tip
If your keyboard ever becomes unresponsive, hold Backspace + Escape + Enter to stop keyd.
period-space off
sudo rm -f /usr/local/bin/period-space
sudo rm -rf /usr/local/share/period-spacekeyd stays installed in case you use it for other remappings.
Bug reports and suggestions are welcome. Pull requests are currently limited to trusted contributors; see CONTRIBUTING.md for details.
Released under the MIT License.