Skip to content

kamarada/gnome-hearts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GNOME Hearts

This repo hosts GNOME Hearts, an old (2013) GTK2/libglade2/Python2 Hearts card game; hearts/, a from-scratch modern rewrite of it; the infrastructure to keep the original running on modern systems; and a git submodule of GNOME's actively-maintained Aisleriot card game collection, used as a build/architecture reference for both.

  • gnome-hearts-0.3.1/ — the original upstream source (autotools, C core + embedded Python2 AI scripts). See docs/user/ and docs/developer/ for its archived documentation.
  • hearts/ — a from-scratch rewrite of the same game in Python, GTK4 and libadwaita, built and run natively (no container). Implements the Standard ruleset only — see hearts/README.md for exact scope.
  • aisleriot/ — git submodule, GNOME's modern GTK3/Meson solitaire collection, used as an architecture reference and as the source of the anglo.svg card art reused by hearts/.
  • ansible/ — one playbook per buildable component.

Building and running

Hearts (native, recommended)

The modern rewrite, playable against 3 AI opponents.

ansible-playbook ansible/hearts.yml

or manually:

cd hearts
meson setup build
meson compile -C build
meson test -C build        # engine unit tests (pure Python, no display needed)
sudo ninja -C build install
hearts

To run without installing:

cd hearts
PYTHONPATH="$PWD" meson devenv -C build python3 -m hearts.main

Requires the aisleriot submodule checked out (git submodule update --init aisleriot) for its card art, plus Meson, Ninja, Python 3, and PyGObject with the GTK4/libadwaita/Rsvg typelibs. See hearts/README.md and ansible/README.md for details and exact package names per distribution.

GNOME Hearts (legacy, containerized)

The original game. Requires GTK2/libglade2/libgnomeui/Python2, none of which are installable on a modern host, so it's built inside a distrobox container and exported to the host as a normal desktop app.

ansible-playbook ansible/gnome-hearts.yml

Requires Docker (running, user in the docker group) and distrobox already installed. Run manually inside the container:

distrobox enter -n gnome-hearts -- gnome-hearts

Aisleriot

ansible-playbook ansible/aisleriot.yml

or manually:

cd aisleriot
meson setup build -Dtheme_kde=false -Dtheme_pysol=false --prefix=/usr/local
ninja -C build
sudo ninja -C build install
sol

Requires the aisleriot submodule checked out and Meson/Ninja installed.

See ansible/README.md for full requirements and options for all three playbooks.

About

GNOME Hearts - the classic Hearts card game for GNOME, packaged to build and run on modern Linux via distrobox

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors