Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/codesuki/bazel-mode
Basic Bazel support for Emacs
https://github.com/codesuki/bazel-mode
bazel bazel-mode bazel-support emacs skylark workspace
Last synced: about 1 month ago
JSON representation
Basic Bazel support for Emacs
- Host: GitHub
- URL: https://github.com/codesuki/bazel-mode
- Owner: codesuki
- License: mit
- Created: 2017-12-21T05:36:34.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2019-11-10T22:28:45.000Z (about 5 years ago)
- Last Synced: 2024-10-28T17:39:29.775Z (about 2 months ago)
- Topics: bazel, bazel-mode, bazel-support, emacs, skylark, workspace
- Language: Emacs Lisp
- Size: 7.81 KB
- Stars: 16
- Watchers: 4
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-bazel - codesuki/bazel-mode
README
# bazel-mode
Basic Bazel support for EmacsFor now this mode gives you python syntax highlighting for `WORKSPACE`, `BUILD.bazel` and `.bzl` files. Formatting is supported by running `buildifier`.
## Installing buildifier
Buildifier needs Go to compile and install. Follow the directions in [1] or install by running the following command.```
go get -u github.com/bazelbuild/buildtools/buildifier
```[1] https://github.com/bazelbuild/buildtools/blob/master/buildifier/README.md
## Formatting Bazel files manually
`C-c C-f` runs `bazel-format` on the current buffer.## Formatting Bazel files automatically before saving
Add the following to your Emacs config.
```
(add-hook 'bazel-mode-hook (lambda () (add-hook 'before-save-hook #'bazel-format nil t)))
```