Function: majutsu-blob-mode

majutsu-blob-mode is an interactive and natively compiled function defined in majutsu-file.el.

Signature

(majutsu-blob-mode &optional ARG)

Documentation

Enable Majutsu features in blob buffers.

When called directly from a file buffer, open the @ blob for that file.

This is a minor mode. If called interactively, toggle the Majutsu-Blob mode mode. If the prefix argument is positive, enable the mode, and if it is zero or negative, disable the mode.

If called from Lisp, toggle the mode if ARG is toggle. Enable the mode if ARG is nil, omitted, or is a positive number. Disable the mode if ARG is a negative number.

To check whether the minor mode is enabled in the current buffer, evaluate the variable majutsu-blob-mode(var)/majutsu-blob-mode(fun).

The mode's hook is called both when the mode is enabled and when it is disabled.

         majutsu-edit-changeset
C-c m majutsu-blob-visit-magit
C-x C-q majutsu-blob-edit-start
V majutsu-blob-visit-file
b majutsu-annotate-addition
e majutsu-blob-edit-start
g revert-buffer
n majutsu-blob-next
p majutsu-blob-previous
q majutsu-bury-or-kill-buffer

Key Bindings

This command is not in any keymaps.

Source Code

;; Defined in /nix/store/jagqw3nms546pad0gxi5f3wsckk6pji7-emacs-packages-deps/share/emacs/site-lisp/majutsu-file.el
(define-minor-mode majutsu-blob-mode
  "Enable Majutsu features in blob buffers.

When called directly from a file buffer, open the @ blob for that file."
  :keymap majutsu-blob-mode-map
  (when (and majutsu-blob-mode
             (not (and majutsu-buffer-blob-root
                       majutsu-buffer-blob-path)))
    (let ((file buffer-file-name))
      (setq majutsu-blob-mode nil)
      (if file
          (let* ((root (majutsu-file--root))
                 (path (majutsu-file--relative-path root file)))
            (majutsu-find-file "@" path))
        (user-error "Buffer is not visiting a file")))))