Rustnake
Classic Snake for the terminal, built in Rust.

Install and Update
Recommended for most users: Cargo install (cross-platform).
Install:
Update:
--locked keeps dependency resolution reproducible.
Binary Support Tiers
- Tiers apply to prebuilt binaries only. Cargo install is cross-platform and outside tier classification.
- Tier 1: Linux (
x86_64-unknown-linux-gnu) with maintainer testing (Arch/Fedora) plus CI validation. - Tier 2: macOS and Windows convenience binaries, validated in CI only (no maintainer manual testing).
Binary Trust Policy
- macOS/Windows binaries are intentionally unsigned as project policy.
- On first run, macOS may show Gatekeeper prompts and Windows may show SmartScreen prompts.
- No signing/notarization rollout is currently planned.
Binary Install and Update
Linux (Tier 1)
Install (release binary):
Update (release binary):
Install or update (system-wide):
Run (and launch later):
Install or update (no sudo, user-only):
On unsigned binaries, macOS may ask for confirmation in Privacy & Security on first run.
If blocked: open System Settings -> Privacy & Security and choose Open Anyway.
Install or update (PowerShell):
$InstallDir = Join-Path $env:LOCALAPPDATA "Rustnake"
$ExePath = Join-Path $InstallDir "rustnake.exe"
$ChecksumPath = Join-Path $InstallDir "rustnake-windows-x86_64.exe.sha256"
New-Item -ItemType Directory -Force -Path $InstallDir | Out-Null
Invoke-WebRequest -Uri "https://github.com/MiguelRegueiro/rustnake/releases/latest/download/rustnake-windows-x86_64.exe" -OutFile $ExePath
Invoke-WebRequest -Uri "https://github.com/MiguelRegueiro/rustnake/releases/latest/download/rustnake-windows-x86_64.exe.sha256" -OutFile $ChecksumPath
$expectedHash = ((Get-Content $ChecksumPath -Raw).Trim() -split '\s+')[0].ToLowerInvariant()
$actualHash = (Get-FileHash -Algorithm SHA256 -Path $ExePath).Hash.ToLowerInvariant()
if ($actualHash -ne $expectedHash) { throw "Checksum mismatch for rustnake.exe" }
Run (and launch later):
& (Join-Path $env:LOCALAPPDATA "Rustnake\rustnake.exe")
On unsigned binaries, Windows may show a SmartScreen prompt on first run.
If prompted: click More info then Run anyway.
Cargo (all platforms):
Linux binary:
macOS binary:
Windows binary (PowerShell):
Remove-Item -Force -ErrorAction SilentlyContinue (Join-Path $env:LOCALAPPDATA "Rustnake\rustnake.exe")
Remove-Item -Force -ErrorAction SilentlyContinue (Join-Path $env:LOCALAPPDATA "Rustnake\rustnake-windows-x86_64.exe.sha256")
Build from source
Optional helper script:
Gameplay
| Action | Key |
|---|---|
| Move | WASD or Arrow Keys |
| Pause | P |
| Mute | M |
| Confirm menu option | ENTER or SPACE |
| Select menu option directly | 1-6 |
| Quit | Q |
Features
- Wrap-around movement (Nokia style).
- Four difficulty levels:
Easy,Medium,Hard,Extreme. - Power-ups for speed, score, and size effects.
- Dynamic pace scaling by score and difficulty.
- Per-difficulty high scores.
- Localized UI:
en,es,ja,pt,zh. - Responsive layout with terminal resize support.
Requirements
- Rust
1.85+(Edition 2024) for source builds. - Primary tested target: Linux
x86_64-unknown-linux-gnu. - Terminal with Unicode font support and ANSI escape sequence support.
Configuration and Data
Config file locations:
- Linux:
~/.rustnake.toml - macOS:
~/Library/Application Support/Rustnake/config.toml - Windows:
%APPDATA%\Rustnake\config.toml - Fallback:
./.rustnake.toml(if platform/user env vars are unavailable)
Persisted data includes:
high_scoresby difficulty- user
settings(language, pause on focus loss, sound, default difficulty) config_versionfor migration handling
High scores and settings persist across binary replacements/updates.
Development
Maintainer release process: RELEASING.md
Troubleshooting
- Terminal too small: resize until the warning clears (minimum baseline
40x25; some languages require wider terminals). - Display artifacts after resize: resize once more to force a full redraw.
- Missing bell/sound cue: terminal bell may be disabled by local settings.
Changelog
License
MIT. See LICENSE.