2021-01-08 15:50:15 +03:00
|
|
|
|
# Editor Daml Language Integration
|
2019-04-04 11:33:38 +03:00
|
|
|
|
|
|
|
|
|
## Vim
|
|
|
|
|
|
|
|
|
|
In order to enable vim syntax highlighting for our DSLs, execute the following
|
2019-04-04 12:34:15 +03:00
|
|
|
|
two lines in your terminal (assuming `~/dev` is where you've checked out digital-asset/daml)
|
2019-04-04 11:33:38 +03:00
|
|
|
|
|
|
|
|
|
```
|
|
|
|
|
mkdir -p ~/.vim/syntax
|
|
|
|
|
ln -s ~/dev/dotfiles/vim/syntax/*.vim ~/.vim/syntax/
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
You also want to make sure that you are sourcing the `.vimrc_da` file in
|
|
|
|
|
your `~/.vimrc`.
|
|
|
|
|
|
|
|
|
|
## VS Code
|
|
|
|
|
|
2021-01-08 15:50:15 +03:00
|
|
|
|
Follow the Daml Studio installation instructions in the Daml user guide.
|
2019-04-04 11:33:38 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
## Update Keywords
|
|
|
|
|
|
|
|
|
|
The instructions on how to update the syntax highlighting of keywords in all our
|
|
|
|
|
supported editors is in `pkgs/da-hs-daml-base/src/DA/Daml/ReservedNames.hs`
|
|
|
|
|
(see documentation for `printEditorKeywords`).
|
|
|
|
|
## Stylish Haskell
|
|
|
|
|
|
|
|
|
|
Copy the `stylish-haskell.yaml` file either to `~/.stylish-haskell.yaml` or to
|
|
|
|
|
`~/dev/.stylish-haskell.yaml`. If you are using vim you can use the plugin
|
|
|
|
|
`jasperdvdj/stylish-haskell` to automatically style your code on write.
|