An itch I had,
Scratch it I did.
Listen, listener, for here is my story…
Since time’s dawn I’ve enjoyed playing scrabble, then I moved far east. While in Việt Nam my usual, some might say traditional, playing partners went amiss and withdrawal started to show its head. FOSS, as always, came to the rescue and first brought the ancestral xscrabble, then eliot, and lastly scribble. Lovingly I packaged these gifts for my BFF Slackware @ https://github.com/cycojesus/slackbuilds/tree/master/y
But still, user interaction with xscrabble and eliot is far from ideal, requiring a lot of clicks. Scribble is near perfect (if for the lack of a french dictionary…) but where, might you ask, is the Emacs love‽ I too wondered and finally commited this:
(defun cyco:scribble (level)
(interactive "sLevel(easy:1..9:hard): ")
(make-term "Scribble-Scrabble" "/usr/games/scribble" nil level)
(global-set-key (kbd "C-c s") 'cyco:scribble)
et voilà, nice and neat.
But, what if I start a game, get distracted to another buffer, forget the on-going game, later want again to play and would be pleasantly surprised to have an on-going game? Glad you asked, so there you go:
(if (eq nil (get-buffer "*Scribble-Scrabble*"))
(let ((level (read-string "sLevel(easy:1..9:hard): " "1")))
(make-term "Scribble-Scrabble" "/usr/games/scribble" nil level)))
(global-set-key (kbd "C-c s") 'cyco:run-or-resume-scribble)
mission accomplished, procrastinating goal achieved.
[my full emacs’ config is @ https://github.com/cycojesus/emacs]