{"id":21660262,"url":"https://github.com/purescript-contrib/purescript-vim","last_synced_at":"2025-12-07T11:03:58.390Z","repository":{"id":2935752,"uuid":"20981644","full_name":"purescript-contrib/purescript-vim","owner":"purescript-contrib","description":"Syntax highlighting and indentation for PureScript","archived":false,"fork":false,"pushed_at":"2023-02-06T09:16:13.000Z","size":92,"stargazers_count":154,"open_issues_count":16,"forks_count":35,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-03-27T16:53:26.476Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Vim Script","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/purescript-contrib.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-06-18T23:41:32.000Z","updated_at":"2025-03-04T10:53:42.000Z","dependencies_parsed_at":"2023-02-19T05:55:19.748Z","dependency_job_id":null,"html_url":"https://github.com/purescript-contrib/purescript-vim","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/purescript-contrib/purescript-vim","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/purescript-contrib%2Fpurescript-vim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/purescript-contrib%2Fpurescript-vim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/purescript-contrib%2Fpurescript-vim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/purescript-contrib%2Fpurescript-vim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/purescript-contrib","download_url":"https://codeload.github.com/purescript-contrib/purescript-vim/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/purescript-contrib%2Fpurescript-vim/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":27567222,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-12-07T02:00:07.896Z","response_time":53,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-25T09:32:35.622Z","updated_at":"2025-12-07T11:03:58.362Z","avatar_url":"https://github.com/purescript-contrib.png","language":"Vim Script","funding_links":[],"categories":["Vim Script"],"sub_categories":[],"readme":"# purescript-vim\n\n[PureScript][] language support for Vim and Neovim providing syntax highlighting and indentation based on based on [idris-vim][] and [haskell-vim][].\n\nSee [purescript-language-server][] for details on how to set up language server support for [PureScript][].\n\n## License\n\nThis project is licensed under The 2-Clause BSD License ([BSD-2-Clause](https://opensource.org/licenses/BSD-2-Clause)) — see the LICENSE file in this project for details.\n\n## Installation\n\n### Manual Installation (no plugin manager)\n\nCopy content of this repository into your `~/.vim` directory (or `%HOME%\\vimfiles` on Windows).\n\nBe sure that the following lines are in your `.vimrc`\n```vim\nsyntax on\nfiletype on\nfiletype plugin indent on\n```\n\n### Vim 8 packages\n\nIf you have Vim version 8 (`vim --version | head -n1`), you can install plugins with the native pack system:\n\n```sh-session\n$ mkdir -p ~/.vim/pack/plugins/start/\n$ cd ~/.vim/pack/plugins/start/\n$ git clone https://github.com/purescript-contrib/purescript-vim.git\n```\n\n### Pathogen\n\nIf you are using [Pathogen][], clone this repo into your `~/.vim/bundle` directory and you are ready to go.\n\n```sh-session\n$ cd ~/.vim/bundle\n$ git clone https://github.com/purescript-contrib/purescript-vim.git\n```\n### vim-plug\n\nIf you are using [vim-plug][], add the following line in between your `plug#begin` and `plug#end` calls for your Vim config file:\n\n```vim\nPlug 'purescript-contrib/purescript-vim'\n```\n\nSave and restart (Neo)Vim and run `:PlugInstall`.\n\n## Configuration\n\n### Indentation\n\nTo configure indentation in `purescript-vim` you can use the following variables:\n\n#### g:purescript_disable_indent\n\nDisable indentation altogether.\n\n```vim\nlet g:purescript_disable_indent = 1\n```\n\n#### g:purescript_indent_case\n\n```vim\nlet g:purescript_indent_case = 5\n```\n\n```purescript\n        case xs of\n        \u003e\u003e\u003e\u003e\u003e[]     -\u003e ...\n        \u003e\u003e\u003e\u003e\u003e(y:ys) -\u003e ...\n```\n\n#### g:purescript_indent_let\n\n```vim\nlet g:purescript_indent_let = 4\n```\n\n```purescript\n        let x = 0 in\n        \u003e\u003e\u003e\u003ex\n```\n\n#### g:purescript_indent_in\n\n```vim\nlet g:purescript_indent_in = 1\n```\n\n```purescript\n        let x = 0\n        \u003ein x\n```\n\n#### g:purescript_indent_where\n\n```vim\nlet g:purescript_indent_where = 6\n```\n\n```purescript\n        where f :: Int -\u003e Int\n        \u003e\u003e\u003e\u003e\u003e\u003ef x = x\n```\n\n#### g:purescript_indent_do\n\n```vim\nlet g:purescript_indent_do = 3\n```\n\n```purescript\n        do x \u003c- a\n        \u003e\u003e\u003ey \u003c- b\n```\n\n#### g:purescript_indent_dot\n\n```vim\nlet g:purescript_indent_dot = 1\n```\n\n```purescript\n  unsnoc\n    :: forall a\n    \u003e. List a\n    -\u003e Maybe (List a, a)\n```\n\n## Unicode conceal\n\nIf you wish to have some symbols concealed for their Unicode equivalents, you may use these options. Each setting will conceal the following ASCII code block for an example output.\n\n```purescript\nsum :: forall a f. Foldable f =\u003e Semiring a =\u003e f a -\u003e a\nsum = foldl (\\a b -\u003e a + b) zero\n\nsumMod2 :: forall f. Foldable f =\u003e f Int -\u003e Int\nsumMod2 xs = mod (sum xs) 2\n\nisSumEven :: forall f. Foldable =\u003e f Int -\u003e Boolean\nisSumEven = (==) 0 \u003c\u003c\u003c sumMod2\n```\n\n### g:purescript_unicode_conceal_enable\n\n```vim\nlet g:purescript_unicode_conceal_enable = 1\n```\n\nEnables concealing. Conceals as:\n\n```purescript\nsum ∷ ∀ a f. Foldable f ⇒ Semiring a ⇒ f a → a\nsum = foldl (λa b → a + b) zero\n\nsumMod2 ∷ ∀ f. Foldable f ⇒ f Int → Int\nsumMod2 xs = mod (sum xs) 2\n\nisSumEven ∷ ∀ f. Foldable ⇒ f Int → Boolean\nisSumEven = (≡) 0 ∘ sumMod2\n```\n\n### g:purescript_unicode_conceal_disable_common\n\n```vim\nlet g:purescript_unicode_conceal_disable_common = 1\n```\n\nDisables concealing common symbols and just uses ones the compiler supports. Concealed as:\n\n```purescript\nsum ∷ ∀ a f. Foldable f ⇒ Semiring a ⇒ f a → a\nsum = foldl (\\a b → a + b) zero\n\nsumMod2 ∷ ∀ f. Foldable f ⇒ f Int → Int\nsumMod2 xs = mod (sum xs) 2\n\nisSumEven ∷ ∀ f. Foldable ⇒ f Int → Boolean\nisSumEven = (==) 0 \u003c\u003c\u003c sumMod2\n```\n\n### g:purescript_unicode_conceal_enable_discretionary\n\n```vim\nlet g:purescript_unicode_conceal_enable_discretionary = 1\n```\n\nEnables discretionary symbols concealing less common symbols that deviate further from the written code. Concealed as:\n\n```purescript\n∑ ∷ ∀ a f. Foldable f ⇒ Semiring a ⇒ f a → a\n∑ = foldl (λa b → a + b) ∅\n\nsumMod2 ∷ ∀ f. Foldable f ⇒ f ℤ → ℤ\nsumMod2 xs = mod (∑ xs) 2\n\nisSumEven ∷ ∀ f. Foldable ⇒ f ℤ → 𝔹\nisSumEven = (≡) 0 ∘ sumMod2\n```\n\n## Developing\n\nGrab the suggested Git config by including with\n\n```sh-session\n$ git config --local include.path ../.gitconfig\n```\n\nThis includes [`.git-blame-ignore-revs`](https://git-scm.com/docs/git-blame#Documentation/git-blame.txt---ignore-revs-fileltfilegt).\n\nEnter Nix dev shell ([enable Flakes](https://nixos.wiki/wiki/Flakes) if needed)\n\n```sh-session\n$ nix develop\n```\n\nOr you can get an automatic shell via [`direnv`](https://direnv.net/)\n\n```sh-session\n$ echo \"use flake\" \u003e .envrc\n$ direnv allow\n```\n\n## Contributing\n\nYou can contribute to purescript-vim in several ways:\n\n1. If you encounter a problem or have a question, please open an [issue](https://github.com/purescript-contrib/purescript-vim/issues) or post to the [mailing list](https://lists.sr.ht/~toastal/purescript-vim). We’ll do our best to work with you to resolve or answer it.\n\n2. If you would like to contribute code, tests, or documentation, please read the [contributor guide](./CONTRIBUTING.md). It’s a short, helpful introduction to contributing to this library, including development instructions.\n\n3. If you have written a library, tutorial, guide, or other resource based on this package, please share it on the [PureScript Discourse](https://discourse.purescript.org/)! Writing libraries and learning resources are a great way to help this library succ:eed.\n\n[PureScript]: http://www.purescript.org\n[Pathogen]: https://github.com/tpope/vim-pathogen\n[idris-vim]: https://github.com/idris-hackers/idris-vim\n[haskell-vim]: https://github.com/raichoo/haskell-vim\n[vim-plug]: https://github.com/junegunn/vim-plug\n[purescript-language-server]: https://github.com/nwolverson/purescript-language-server#vimcoc\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpurescript-contrib%2Fpurescript-vim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpurescript-contrib%2Fpurescript-vim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpurescript-contrib%2Fpurescript-vim/lists"}