Variable: bazel-mode-abbrev-table

bazel-mode-abbrev-table is a variable defined in bazel.el.

Value

#<obarray n=1>

Documentation

Abbrev table for bazel-mode.

Source Code

;; Defined in /nix/store/ws8pkszjvcad1rgzqw6wja7qxacylfhn-emacs-packages-deps/share/emacs/site-lisp/elpa/bazel-20261002.1510/bazel.el
(define-derived-mode bazel-mode prog-mode "Bazel"
  "Major mode for editing Bazel files with Starlark-like syntax.
This is the parent mode for the more specific modes
‘bazel-build-mode’, ‘bazel-workspace-mode’, ‘bazel-module-mode’,
‘bazel-repo-mode’, ‘bazel-vendor-mode’, and ‘bazel-starlark-mode’."
  ;; Almost all Starlark code in existence uses 4 spaces for indentation.
  ;; Buildifier also enforces this style.
  (setq-local tab-width 4)
  (setq-local python-indent-offset 4)
  (setq-local python-indent-guess-indent-offset nil)
  (setq-local indent-tabs-mode nil)
  ;; Take over some syntactic constructs from ‘python-mode’.
  (setq-local comment-start "# ")
  (setq-local comment-start-skip (rx (+ ?#) (* (syntax whitespace))))
  (setq-local comment-end "")
  (setq-local comment-use-syntax t)
  (setq-local parse-sexp-ignore-comments t)
  (setq-local forward-sexp-function #'python-nav-forward-sexp)
  (setq-local font-lock-defaults '((bazel-font-lock-keywords
                                    bazel-font-lock-keywords-1
                                    bazel-font-lock-keywords-2
                                    bazel-font-lock-keywords-3)))
  (setq-local syntax-propertize-function python-syntax-propertize-function)
  (setq-local indent-line-function #'python-indent-line-function)
  (setq-local indent-region-function #'python-indent-region)
  (setq-local electric-indent-inhibit t)
  (setq-local prettify-symbols-alist python-prettify-symbols-alist)
  ;; Adapt some Python indentation style variables for Bazel.
  (setq-local python-indent-def-block-scale 1)
  ;; Treat magic comments as being separate paragraphs for filling.
  (setq-local paragraph-start
              (rx (or (seq (* (syntax whitespace)) (regexp comment-start-skip)
                           (regexp bazel--magic-comment-regexp))
                      (regexp paragraph-start))))
  (setq-local fill-paragraph-function #'python-fill-paragraph)
  (setq-local normal-auto-fill-function #'python-do-auto-fill)
  (add-hook 'before-save-hook #'bazel--buildifier-before-save-hook nil :local)
  (add-hook 'flymake-diagnostic-functions #'bazel-mode-flymake nil :local)
  (add-hook 'xref-backend-functions #'bazel-mode-xref-backend nil :local)
  (add-hook 'completion-at-point-functions #'bazel-completion-at-point
            nil :local)
  (when-let* ((filename buffer-file-name))
    ;; Initialize filename cache.
    (bazel--repository-relative-name filename))
  nil)