Function: jinja2-indent-line
jinja2-indent-line is an interactive and natively compiled function
defined in jinja2-mode.el.
Signature
(jinja2-indent-line)
Documentation
Indent current line as Jinja code
Key Bindings
This command is not in any keymaps.
Source Code
;; Defined in /nix/store/w823rz5zs434n18ps4jcyc02giqk4dgd-emacs-packages-deps/share/emacs/site-lisp/elpa/jinja2-mode-20220117.807/jinja2-mode.el
(defun jinja2-indent-line ()
"Indent current line as Jinja code"
(interactive)
(let ((old_indent (current-indentation)) (old_point (point)))
(move-beginning-of-line nil)
(let ((indent (max 0 (jinja2-calculate-indent))))
(indent-line-to indent)
(if (< old_indent (- old_point (line-beginning-position)))
(goto-char (+ (- indent old_indent) old_point)))
indent)))