Function: bazel--buildifier-file-flags
bazel--buildifier-file-flags is a natively compiled function defined
in bazel.el.
Signature
(bazel--buildifier-file-flags TYPE FILENAME)
Documentation
Return a list of -path and -type flags for Buildifier.
TYPE should be one of the possible values of
‘bazel--buildifier-type’. Use TYPE and FILENAME to derive
appropriate flags, if possible. Otherwise, return an empty
list.
Source Code
;; Defined in /nix/store/ws8pkszjvcad1rgzqw6wja7qxacylfhn-emacs-packages-deps/share/emacs/site-lisp/elpa/bazel-20261002.1510/bazel.el
(defun bazel--buildifier-file-flags (type filename)
"Return a list of -path and -type flags for Buildifier.
TYPE should be one of the possible values of
‘bazel--buildifier-type’. Use TYPE and FILENAME to derive
appropriate flags, if possible. Otherwise, return an empty
list."
(declare (ftype (function (symbol (or string null)) (or string null))))
(cl-check-type type symbol)
(cl-check-type filename (or string null))
(append
(and filename
(when-let* ((name (bazel--repository-relative-name filename)))
(list (concat "-path=" name))))
(and type (list (concat "-type=" (symbol-name type))))))