Variable: majutsu-op-log-columns
majutsu-op-log-columns is a customizable variable defined in
majutsu-op.el.
Value
Large value
((:field op-id-short :module heading :template
[:label "id short" [:id :short]] :face t)
(:field root-marker :module heading :template
[:if [:root] [:label "root" "root()"] ""] :face t)
(:field user :module heading :template
[:if [:root] "" [:label "user" [:user]]] :face t)
(:field workspace :module heading :template
[:if [:root] "" [:label "workspace_name" [:workspace_name]]]
:face t)
(:field time-range :module heading :template
[:if [:root] ""
[:concat
[:label "time end ago" [:method [:time :end] :ago]]
[:label "time" ", lasted "]
[:label "time duration" [:method [:time] :duration]]]]
:face t)
(:field description :module body :template
[:if [:root] ""
[:label "description first_line"
[:method [:description] :first_line]]]
:face t)
(:field attributes :module body :template
[:if [:root] ""
[:label "attributes"
[:method [:attributes] :replace "\n" ""]]]
:face t)
(:field op-id :module metadata :template [:id] :face nil :post
majutsu-op--row-machine-field)
(:field op-id-short :module metadata :template [:id :short] :face nil
:post majutsu-op--row-machine-field)
(:field kind :module metadata :template
[:if [:root] "root" [:if [:snapshot] "snapshot" "op"]] :face
nil :post majutsu-op--row-machine-field)
(:field current :module metadata :template
[:if [:current_operation] "t" ""] :face nil :post
majutsu-op--row-machine-field)
(:field user :module metadata :template [:user] :face nil)
(:field workspace :module metadata :template [:workspace_name] :face
nil)
(:field time :module metadata :template
[:method [:time :end] :format "%Y-%m-%d %H:%M:%S"] :face nil)
(:field time-ago :module metadata :template
[:method [:time :end] :ago] :face nil)
(:field duration :module metadata :template
[:method [:time] :duration] :face nil)
(:field description :module metadata :template
[:method [:description] :first_line] :face nil)
(:field attributes :module metadata :template
[:method [:attributes] :replace "\n" ""] :face nil))
Documentation
Flat columns for a native compact operation row.
The visible modules mirror jj's compact formatter. Canonical metadata is transported separately, with complete encoded attributes as the last field.
Source Code
;; Defined in /nix/store/jagqw3nms546pad0gxi5f3wsckk6pji7-emacs-packages-deps/share/emacs/site-lisp/majutsu-op.el
(defcustom majutsu-op-log-columns
'((:field op-id-short :module heading
:template [:label "id short" [:id :short]] :face t)
(:field root-marker :module heading
:template [:if [:root] [:label "root" "root()"] ""] :face t)
(:field user :module heading
:template [:if [:root] "" [:label "user" [:user]]] :face t)
(:field workspace :module heading
:template [:if [:root]
""
[:label "workspace_name" [:workspace_name]]]
:face t)
(:field time-range :module heading
:template [:if [:root]
""
[:concat
[:label "time end ago" [:method [:time :end] :ago]]
[:label "time" ", lasted "]
[:label "time duration" [:method [:time] :duration]]]]
:face t)
(:field description :module body
:template [:if [:root]
""
[:label "description first_line"
[:method [:description] :first_line]]]
:face t)
(:field attributes :module body
:template [:if [:root]
""
[:label "attributes"
[:method [:attributes] :replace "\n" "\x1f"]]]
:face t)
(:field op-id :module metadata :template [:id]
:face nil :post majutsu-op--row-machine-field)
(:field op-id-short :module metadata :template [:id :short]
:face nil :post majutsu-op--row-machine-field)
(:field kind :module metadata
:template [:if [:root]
"root"
[:if [:snapshot] "snapshot" "op"]]
:face nil :post majutsu-op--row-machine-field)
(:field current :module metadata
:template [:if [:current_operation] "t" ""]
:face nil :post majutsu-op--row-machine-field)
(:field user :module metadata :template [:user] :face nil)
(:field workspace :module metadata :template [:workspace_name] :face nil)
(:field time :module metadata
:template [:method [:time :end] :format "%Y-%m-%d %H:%M:%S"]
:face nil)
(:field time-ago :module metadata
:template [:method [:time :end] :ago] :face nil)
(:field duration :module metadata
:template [:method [:time] :duration] :face nil)
(:field description :module metadata
:template [:method [:description] :first_line] :face nil)
(:field attributes :module metadata
:template [:method [:attributes] :replace "\n" "\x1f"] :face nil))
"Flat columns for a native compact operation row.
The visible modules mirror jj's compact formatter. Canonical metadata is
transported separately, with complete encoded attributes as the last field."
:type 'sexp
:group 'majutsu
:set (lambda (symbol value)
(set-default symbol value)
(setq majutsu-op-log--compiled-template-cache nil)))