Commit graph

755 commits

Author SHA1 Message Date
Joey Hain
476e6baf8f
Add textobject queries for vala (#8541) 2024-03-18 00:11:28 +01:00
Leonardo Eugênio
d99b6177c2
Add blade support (#9513)
* Add php-only language config and queries

php-only is required enabling php injections like in blade templates

* Add blade templates support
2024-03-18 00:07:09 +01:00
Jonas De Vuyst
0301d01e78
Fix URL in doc chapter about Textobject queries (#5773)
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2024-03-17 23:56:17 +01:00
Dan Cardamore
3890376a23
add 'file-absolute-path' to statusline (#4535)
* feat: add 'file-abs-path' to statusline (#4434)

* cleanup implementation

* rename to be non-abbreviated names

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2024-03-17 23:55:49 +01:00
George "Riye" Hollister
e36774c2c8
Add Support for JSONC (#9906)
* Added `jsonc` language with support for comments

The `vscode-json-language-server` accepts `jsonc` as a language id.
Allowing the use of comments within JSON files.

* fix: Update `injdection-rejex` to be unique

* fix: use includes to remove redundant queries

* ci: Generate language-support docs
2024-03-17 23:54:05 +01:00
Arthur Deierlein
9ec0271873
Add support for hyprland config (#9899)
* feat: add hyprland config language

* adjust indents to helix

* adjust highlights to helix
2024-03-17 23:53:30 +01:00
Kirawi
0c51ab16d0
Add a yank diagnostic command (#9640)
* yank diagnostic command

* improve success message

* move to a typed command

* docgen
2024-03-15 17:38:22 +01:00
Matthew Toohey
e3c6c82828
add linker script language (#9835) 2024-03-09 16:59:56 +09:00
Chris
301dfb07cc
Add PowerShell highlighting (#9827) 2024-03-07 23:39:00 +01:00
Michael Davis
5ca6a448e9
Support LSP diagnostic tags (#9780) 2024-03-02 13:37:11 +09:00
Felix Zeller
062fb819a2
feat: Add markdown-oxide language server (#9758) 2024-03-01 09:10:49 -06:00
Dawid Ciężarkiewicz
44db25939c
Document embracing smart-tab navigation. (#9762)
Re #4443
2024-03-01 02:57:31 +01:00
Gabriel Dinner-David
26b3dc29be
toggling of block comments (#4718) 2024-02-27 22:36:25 +09:00
巢鹏
358ac6bc1f
add fidl support (#9713) 2024-02-27 01:41:50 +01:00
Volodymyr Chernetskyi
990378a46b
Add Groovy grammar (#9350)
* Add Groovy grammar

* Rewrite Neovim captures into Helix for Groovy

* Simplify Groovy injections

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* Remove Neovim's spell from Groovy highlights

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* Apply suggestions to languages.toml

* Escape backslash in groovy highlights.scm

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2024-02-19 18:37:02 +01:00
Jaakko Paju
ebf155d635
Add textobject queries for HCL (#9658)
* Add textobject queries for HCL

* Add to lang-support.md
2024-02-19 00:46:32 +01:00
Jaakko Paju
2dc9ce68ec
Add textobject queries for Nix (#9659)
* Add textobject queries for Nix

* Add to lang-support.md
2024-02-19 00:46:13 +01:00
Malpha
c72426cc87
Add docker-compose language (#9661)
* languages: add docker-compose language

it uses docker-compose-langserver as lsp
And yaml for syntax highlighting, indents and injections

* languages: add luajit as a shebang of lua

This helps to provide syntax highlighting and
other lua goodies when writing luajit

* book(update): run cargo xtask docgen

* since #8006 full filenames uses glob
2024-02-19 00:19:44 +01:00
AlexanderDickie
9ab3f9d01a
Scroll cursor and page together (neovim-like scrolling) (#8015)
* neovim like scroll function

* clear line annotations outside of move_vertically/_visual

* add nvim scroll function to commands

* assign nvim-scroll to C-d and C-u (half page scrolls)

* dont remove backspace and space mapping

* move non-softwrap logic to seperate function, call this in nvim-scroll fn

* Revert "move non-softwrap logic to seperate function, call this in nvim-scroll fn"

This reverts commit e4905729c338a2260e6981f1d8fac022897b4191.

* Revert "clear line annotations outside of move_vertically/_visual"

This reverts commit 1df3fefe55afc840d1ab5094b2116d1127fc363f.

* add TODO for when inline diagnostics gets merged

* move nvim-scroll logic into scroll(), dont respect scrolloff

* run cargo fmt

* run cargo clippy

* update documenation for Ctrl-d and Ctrl-u remap
2024-02-19 00:13:04 +01:00
Mark Stosberg
0516337abb
docs: Document that what the diff gutter symbol does (#9587)
Before there was no document about what the `diff` gutter is displaying
or what the colors mean.

These docs clarify it's a `git` diff and makes it easier to
cross-reference the theme if you aren't sure what the colors mean or
want to change them.
2024-02-13 01:48:10 +09:00
iko
d7c7589fd5
Add Hoon (#9190)
* Added Hoon

* Added highlights.scm

* Updated docs

* Update runtime/queries/hoon/highlights.scm

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2024-02-12 16:36:14 +01:00
ontley
6a90166d0a
Add required-root-patterns for situational lsp activation (#8696)
* Added required-root-patterns for situational lsp activation using globbing

* Replaced filter_map with flatten

* updated book to include required-root-patterns option

* fixed wrong function name for path

* Added globset to helix-core. Moved globset building to config parsing.

* Normalize implements AsRef

* cargo fmt

* Revert "cargo fmt"

This reverts commit ca8ce123e8d77d2ae8ed84d5273a9b554101b0db.
2024-02-12 02:35:25 +01:00
Jimmy Zelinskie
d9f7aaacaf
languages: add CEL, SpiceDB schema language (#9296)
* languages: add CEL language and grammar

* languages: add spicedb schema language

* chore: docgen

* runtime/queries: refine spicedb & cel highlights

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* languages: update spicedb

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2024-02-12 02:28:52 +01:00
Galen Abell
581a1ebf5d
Add glob file type support (#8006)
* Replace FileType::Suffix with FileType::Glob

Suffix is rather limited and cannot be used to match files which have
semantic meaning based on location + file type (for example, Github
Action workflow files). This patch adds support for a Glob FileType to
replace Suffix, which encompasses the existing behavior & adds
additional file matching functionality.

Globs are standard Unix-style path globs, which are matched against the
absolute path of the file. If the configured glob for a language is a
relative glob (that is, it isn't an absolute path or already starts with
a glob pattern), a glob pattern will be prepended to allow matching
relative paths from any directory.

The order of file type matching is also updated to first match on globs
and then on extension. This is necessary as most cases where
glob-matching is useful will have already been matched by an extension
if glob matching is done last.

* Convert file-types suffixes to globs

* Use globs for filename matching

Trying to match the file-type raw strings against both filename and
extension leads to files with the same name as the extension having the
incorrect syntax.

* Match dockerfiles with suffixes

It's common practice to add a suffix to dockerfiles based on their
context, e.g. `Dockerfile.dev`, `Dockerfile.prod`, etc.

* Make env filetype matching more generic

Match on `.env` or any `.env.*` files.

* Update docs

* Use GlobSet to match all file type globs at once

* Update todo.txt glob patterns

* Consolidate language Configuration and Loader creation

This is a refactor that improves the error handling for creating
the `helix_core::syntax::Loader` from the default and user language
configuration.

* Fix integration tests

* Add additional starlark file-type glob

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2024-02-11 18:24:20 +01:00
Android789515
d570c29ce3
expand upon the arch linux install instructions (#9574)
Signed-off-by: Android789515 <derflug@mailfence.com>
2024-02-09 08:29:11 -06:00
Matouš Dzivjak
d137a08231
feat(languages): pkl (#9515)
* feat(languages): pkl

Add [pkl](https://github.com/apple/pkl) language.
Official documentation: https://pkl-lang.org/

* remove branch indent
2024-02-09 11:44:46 +01:00
Tobias Hunger
a1272bdb17
slint: Update treesitter parser and queries (#9551)
* slint: Update treesitter parser and queries

* slint: Port over suggestions from nvim review
2024-02-07 19:36:29 +01:00
zetashift
6e3ed7f0fa
Update Unison tree-sitter grammar for type changes and add indent queries (#9505)
* Update Unison tree-sitter grammar for type changes

* Add indent queries for Unison

* Improve Unison indent queries
2024-02-04 02:10:20 +01:00
Novus Nota
d1054de3ce
feat: Add Tact language support (#9512)
Re-submitting
2024-02-04 02:09:11 +01:00
melted-brownie
2058b3732c
Add text object queries for dart (#9411)
* Add text object queries for dart

* Update runtime/queries/dart/textobjects.scm

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* Clean up internal capture name

---------

Co-authored-by: Sébastien Blondiau <sebastien.blondiau@iot-d.com>
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2024-01-23 18:27:09 +01:00
Pascal Kuthe
8e592a151f refactor completion and signature help using hooks 2024-01-23 11:20:19 +09:00
woojiq
52a43bcdfc
bash, make, css: highlight and indent queries improvement (#9393)
* highlights(bash): rework keywords section

* Use more specified scope when possible for keywords like @keyword.repeat.
* Add more keywords like "local" or "unsetenv".

Limitation:
* Bash doesn't allow you to have a local variable outside of a function, so maybe we need to have better queries to not highlight the local in this case.
* If we name a function with a keyword (such as unset or local), it will use the highlight scope "keyword" instead of "function".

* indents(css, make): add basic queries

* Despite the fact that queries look simple, they improve indentation in some edge cases that helix couldn't handle correctly by default.
2024-01-22 19:51:12 +01:00
JR
6ce57b7924
Fix export instructions in installation doc (#9306) 2024-01-15 21:43:23 +01:00
Michael Davis
3011df4f35
Bump tree-sitter to latest master (#9317)
* query capture names now return `&str`s rather than `String`s
* the `#any-of?` predicate is now supported
2024-01-15 15:33:26 +09:00
NitinKM
e46fb58595
Info on how to skip grammar build when building from source (#8698)
* info: no grammar compile

Added instructions on how to compile without compiling grammars

* Update book/src/install.md

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2024-01-08 03:46:53 +01:00
jw013
00d681cc69
Update goto_file docs (#8563) (#9001)
Make the pluralization of files and selections consistent to emphasize
the 1-to-1 relation between files and selections. The prior wording
with plural "files" and singular "selection" can mislead users into
thinking the command can open multiple files from a single selection.
2024-01-08 03:11:18 +01:00
Ryan Roden-Corrent
c8e58304bf
Add textobject queries for protobuf grammar. (#9184)
Given `message Foo {string s = 1;}`
- `mat` selects `message Foo {string s = 1}`
- `mit` selects `{string s = 1;}`

Given `service SearchService { rpc Search(Req) returns (Resp); }
- `mit` or `mat` selects `Req` or `Resp`
- `mif` or `maf` selects `rpc Search(Req) returns (Resp);`
- `mit` selects { rpc Search(Req) returns (Resp); }`
- `mat` selects `service SearchService { rpc Search(Req) returns (Resp); }`
2024-01-08 03:08:41 +01:00
Jaakko Paju
73deba7044
Add textobject queries for Scala (#9191) 2024-01-08 03:05:10 +01:00
Jaakko Paju
a32d537d0a
Add HOCON language support (#9203)
* Add HOCON language support

* Remove error query

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* Change include query

* Fix query error

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2024-01-08 03:04:43 +01:00
Pascal Kuthe
8653e1b02f Add config to mark diagnostic sources as persistent 2023-12-27 15:28:14 +09:00
Evan Richter
a98b8ddd1a
add smali language support (#9089) 2023-12-20 00:31:27 +01:00
ath3
9ba691cd3a
Support drawing popup frame (#4313)
Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
2023-12-19 10:17:12 +09:00
0rphee
0a83d85124
Add haskell-language-server as lsp for cabal files (#9111) 2023-12-19 10:05:55 +09:00
Novus Nota
a1a20d231f
book: Describe usage of .ignore and helix-specific ignore files in [editor.file-picker] section (#9102) 2023-12-17 22:40:29 +01:00
JJ
c56cd6ee8b
Add support for Agda (#8285)
* agda language support (wip)

* improve highlights

* disable agda-language-server

* minor addendum to documentation

* cargo xtask docgen

* oh i can just do this neat

* minor comment cleanup

* upstream updated

* imports: missed a spot

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2023-12-16 05:29:26 +01:00
TornaxO7
914c83420b
fix :indent-style crash (#9087)
* removing unreachable statement in `:indent-style`

* update checks when setting indent line and update docs

* `cargo xtask docgen`
2023-12-15 19:05:04 +01:00
Daniel Ebert
723a132bdf Simplify implementation of add_indent_level.
Increase hybrid indent heuristic attempt limit to 4.
Clarify the fallback logic in indent heuristic docs.
2023-12-15 15:59:54 +09:00
Daniel Ebert
a5acfdbf10 Add documentation for new indent computation 2023-12-15 15:59:54 +09:00
Phil
b4571c292e
Add initial support for janet-lang (#9081)
* Add initial support for janet-lang

* Use default roots for janet-lang
2023-12-15 15:54:25 +09:00
Valerii Petryniak
7c55190806
Update keymap.md: improve grammar (#9069)
* Update keymap.md: improve grammar

* Update keymap.md

Co-authored-by: David Else <12832280+David-Else@users.noreply.github.com>

---------

Co-authored-by: David Else <12832280+David-Else@users.noreply.github.com>
2023-12-13 17:37:12 +01:00