diff --git a/.editorconfig b/.editorconfig index 90cbacb..7615472 100644 --- a/.editorconfig +++ b/.editorconfig @@ -5,6 +5,6 @@ end_of_line = lf indent_style = tab indent_size = 4 -[*.{el,nix,yml}] +[*.{nix,yml}] indent_style = space indent_size = 2 \ No newline at end of file diff --git a/esv.el b/esv.el deleted file mode 100644 index ff3182a..0000000 --- a/esv.el +++ /dev/null @@ -1,53 +0,0 @@ -;;; esv.el --- read the Bible from Emacs -*- lexical-binding:t -*- - -(defgroup esv nil - "Read the Bible." - :prefix "esv-" - :group 'applications) - -(defcustom esv-columns 72 - "Length of each line output by `esv'." - :type 'natnum - :group 'esv) -(defcustom esv-mode-hook nil - "Hook run after entering `esv-mode'." - :type 'hook - :group 'esv) -(defcustom esv-process "esv" - "Name of the process created by `esv'." - :type 'string - :group 'esv) -(defcustom esv-program "esv" - "Path to or name of the program started by `esv'." - :type 'string - :group 'esv) - -(define-derived-mode esv-mode text-mode "ESV-Bible" - "Major mode used for reading the Bible with `esv'." - :group 'esv - - (read-only-mode)) - -(defun esv (book verses) - "Fetch the Bible passage identified by BOOK and VERSES. -The result will be redirected to a buffer specified by `esv-buffer'." - (interactive "MBook: \nMVerses: ") - (let ((buffer (concat book " " verses))) - (catch 'buffer-exists - (when (get-buffer buffer) - (message "Buffer `%s' already exists" buffer) - (throw 'buffer-exists nil)) - ;; execute esv - (call-process esv-program nil buffer t - ;; arguments - (format "-l%d" esv-columns) book verses) - ;; display buffer in another window - (display-buffer buffer) - ;; move point to the beginning of the buffer - (with-current-buffer buffer - (esv-mode) - (goto-char (point-min))) - (set-window-start (get-buffer-window buffer) (point-min)) - t))) - -(provide 'esv)