Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/mattt-b/flycheck-odin

Emacs Flycheck integration for the Odin language
https://github.com/mattt-b/flycheck-odin

emacs flycheck odin-lang odin-programming-language

Last synced: 18 days ago
JSON representation

Emacs Flycheck integration for the Odin language

Awesome Lists containing this project

README

        

# flycheck-odin
[Flycheck](https://www.flycheck.org/en/latest/) for [Odin](https://github.com/odin-lang/Odin)

## Setup
```elisp
(eval-after-load 'flycheck
'(add-hook 'flycheck-mode-hook #'flycheck-odin-setup))
```

#### Default behavior
This is a wrapper around `odin check $LOCATION -vet`. With no changes on the users' part, the default
behavior is is to run `odin check $CURRENT_DIRECTORY -vet` (where '$CURRENT_DIRECTORY' is the directory of the current buffer).

#### Changing behavior
This exposes the following variables that can be customized globally or with [.dir-locals.el](https://www.gnu.org/software/emacs/manual/html_node/emacs/Directory-Variables.html)

*flycheck-odin-project-path*
Change the $LOCATION in `odin check $LOCATION -vet`. This can be a directory or a file.

*flycheck-odin-error-filters*
A list of Emacs regexes of errors to ignore.

*flycheck-odin-command-arguments*
A list of [compiler flags](https://github.com/odin-lang/Odin/wiki/Compiler-Flags). Defaults to `("-vet")`

An example configuration might look something like this:
```
((odin-mode
(flycheck-odin-project-path . "~/code/project/src")
(flycheck-odin-error-filters . ("^[^[:blank:]]*/Odin/core/"
"^[^[:blank:]]*/Odin/shared/some_library/"
"foobar"))))

```