From: Tim Vaughan Date: Thu, 11 Apr 2019 21:35:33 +0000 (+0200) Subject: Initial commit. X-Git-Tag: v1.0.0~90 X-Git-Url: https://thelambdalab.xyz/gitweb/index.cgi?a=commitdiff_plain;h=bbf9cbcd501121d594712ef84ff61b4ebfb676dc;p=elpher.git Initial commit. --- bbf9cbcd501121d594712ef84ff61b4ebfb676dc diff --git a/betty.el b/betty.el new file mode 100644 index 0000000..e339739 --- /dev/null +++ b/betty.el @@ -0,0 +1,40 @@ +;;; betty.el --- gopher client + +;;; Commentary: + +;; Simple gopher client in elisp. + +;;; Code: + +(defvar betty-mode-map nil "Keymap for gopher client.") +(define-key betty-mode-map (kbd "p") 'betty-quit) + +(define-derived-mode betty-mode special-mode "betty" + "Major mode for betty, an elisp gopher client. + + \\{betty-mode-map}") + +(defun betty () + "Start gopher client." + (interactive) + (switch-to-buffer "*betty*") + (betty-mode) + (let ((inhibit-read-only t) + (make-process + :name "ls" + :command "ls -l" + :filter)) + + ;; (address (read-from-minibuffer "Address of gopher server: "))) + (message "Connecting to '%s' ..." address) + (erase-buffer) + (insert (propertize "Hello, world." 'face '(foreground-color . "red"))) + (newline) + (insert (propertize "Hello, Tim." 'face '(foreground-color . "yellow"))))) + +(defun betty-quit () + (interactive) + (kill-buffer "*betty*")) + + +;;; betty.el ends here