Skip to content

Create a Contributing doc to explain how to generate syntax and more #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 19, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 54 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# Contributing

A large portion of the syntax file is generated using Clojure code in the
`clj/` directory. Generation of Vim code in this fashion is preferred over
hand crafting of the same.

There is an incomplete syntax test suite in `clj/test/`. Any additions and
improvements to these tests are highly appreciated.

To contribute to Clojure.vim you will need [Leiningen][].


## Update syntax files

When a new Clojure version is released, perform the following steps to update
the syntax files to add syntax highlighting for new functions, macros and
special forms.

```
$ cd clj/
$ lein repl
> (load-file "src/vim_clojure_static/generate.clj")
> (ns vim-clojure-static.generate)
> (update-project! "..")
```

### Update Unicode syntax

Update the file used to generate the Unicode character classes highlighted in Clojure
regex strings.

```sh
cd clj/
./bin/update-unicode
```

Then update the syntax files using the steps in the previous section.


## Run tests

Run the test suite using this command:

```
lein test
```


## Submit latest changes to upstream Vim

_WIP_


[Leiningen]: https://leiningen.org/#install
10 changes: 2 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -208,14 +208,8 @@ Wiki](https://github.com/clojure-vim/clojure.vim/wiki/Plugins).

## Contribute!

Pull requests are welcome!

A large portion of the syntax file is generated from Clojure code in
`clj/src/`. Generation of vim code in this fashion is preferred over hand
crafting of the same.

There is an incomplete syntax test suite in `clj/test/`. Any additions and
improvements to these tests are highly appreciated.
Pull requests are welcome! Make sure to read the
[`CONTRIBUTING.md`](CONTRIBUTING.md) for useful information.


## Acknowledgements
Expand Down