cl-wordle: init at 0.1.2

This commit is contained in:
legendofmiracles 2022-02-06 13:23:08 -06:00
parent 7f715c21db
commit c0217caf80
No known key found for this signature in database
GPG key ID: 19B082B3DEFE5451
3 changed files with 39 additions and 0 deletions

View file

@ -0,0 +1,24 @@
{ lib, rustPlatform, fetchCrate }:
rustPlatform.buildRustPackage rec {
pname = "cl-wordle";
version = "0.1.2";
src = fetchCrate {
inherit pname version;
sha256 = "sha256-mcPC2Lj+Vsytfl3+ghYn74QRfM6U4dQLUybtCqkjKlk=";
};
cargoSha256 = "sha256-3Ef8gLFWIAYpKdPixvILvDee5Gezh68hc9TR5+zRX0I=";
patches = [ ./rust-1-57.diff ];
meta = with lib; {
description = "Wordle TUI in Rust";
homepage = "https://github.com/conradludgate/wordle";
# repo has no license, but crates.io says it's MIT
license = licenses.mit;
maintainers = with maintainers; [ lom ];
mainProgram = "wordle";
};
}

View file

@ -0,0 +1,13 @@
diff --git a/src/bin/wordle/game.rs b/src/bin/wordle/game.rs
index 8500732..6f26e2a 100644
--- a/src/bin/wordle/game.rs
+++ b/src/bin/wordle/game.rs
@@ -235,7 +235,7 @@ impl Display for GameShare {
score = self.score
)?;
for m in &self.matches {
- write!(f, "\n{m}")?;
+ write!(f, "\n{}", m)?;
}
Ok(())
}

View file

@ -29908,6 +29908,8 @@ with pkgs;
wofi-emoji = callPackage ../applications/misc/wofi-emoji { };
cl-wordle = callPackage ../games/cl-wordle { };
wordnet = callPackage ../applications/misc/wordnet {
inherit (darwin.apple_sdk.frameworks) Cocoa;
};