Commit Graph

2508 Commits (a7ee9f74f771a486f99dca9e7a6084f74f19eb46)
 

Author SHA1 Message Date
Michael Davis 7bce91556a
add tree-sitter-iex (#1576)
* add tree-sitter-iex

* run docgen task

* fix url for iex submodule
2 years ago
dependabot[bot] ed03be1450
build(deps): bump which from 4.2.2 to 4.2.4 (#1577)
Bumps [which](https://github.com/harryfei/which-rs) from 4.2.2 to 4.2.4.
- [Release notes](https://github.com/harryfei/which-rs/releases)
- [Commits](https://github.com/harryfei/which-rs/compare/4.2.2...4.2.4)

---
updated-dependencies:
- dependency-name: which
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2 years ago
dependabot[bot] 5c007c2248
build(deps): bump clipboard-win from 4.3.0 to 4.4.1 (#1578)
Bumps [clipboard-win](https://github.com/DoumanAsh/clipboard-win) from 4.3.0 to 4.4.1.
- [Release notes](https://github.com/DoumanAsh/clipboard-win/releases)
- [Commits](https://github.com/DoumanAsh/clipboard-win/commits)

---
updated-dependencies:
- dependency-name: clipboard-win
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2 years ago
Eric Crosson 0ad7561135
Enable tree-sitter for .zshenv and zsh files (#1574)
This commit builds on #1460, #1571, and others, adding the .zshenv
file and all files with the zsh extension to the file-types using
bash syntax-highlighting.
2 years ago
VuiMuich 1bcff796e5
[theme] Serika light and dark (#1566)
* add theme `serika` in light and dark variant

* add `markup.*`s
2 years ago
chunghha a4fffaed9f
Enable tree-sitter for .bash_profile (#1571) 2 years ago
CossonLeo d49e5323f9
Use markup scopes for the Markdown component (#1363) 2 years ago
Benjamin 4044c70eb2
Fix picker won't scroll down when it hits the bottom #1544 (#1567) 2 years ago
Ivan Tham 759b850859
Allow specifying file start position (#445)
Like helix-term/src/commands.rs:3426:15
2 years ago
Blaž Hrastnik 7d510429c5 Enable tree-sitter for .zshrc and .bashrc
Closes #1460
2 years ago
Omnikar f064894e57
Fix Clippy lints in tests (#1563)
Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
2 years ago
Blaž Hrastnik e2d2f19fd0
Merge pull request #1154 from sudormrfbin/cursor-shape-new
Change cursor shape on mode change
2 years ago
Kyra a8e69e12f4
Add haskell-language-server-wrapper --lsp to default `languages.toml` (#1556)
After the changes to upgrade and reenable tree-sitter-haskell #1417
for the purpose of enabling Haskell syntax highlighting #1384, we
might as well take the final step.
2 years ago
Blaž Hrastnik 4080341977 cargo fmt + clippy lint 2 years ago
Blaž Hrastnik 7c9ebd05b8 Remove some TODOs 2 years ago
Blaž Hrastnik 80e920ba36 Update dependencies (includes tree-sitter 0.20.3) 2 years ago
Blaž Hrastnik ac81b47a41 Don't calculate symbol width twice
This is potentially costly so we should avoid calling width()
2 years ago
Blaž Hrastnik 66a8612351 cleanup 2 years ago
Blaž Hrastnik 2302869836 fix: ensure_grapheme_boundary_next_byte needs to index at valid char 2 years ago
Blaž Hrastnik add3be8528 Slicing micro-optimization 2 years ago
Blaž Hrastnik df0d58e9f7 Set flags necessary for cargo-flamegraph 2 years ago
Blaž Hrastnik 11c3ba9350 Speed up ensure_next_boundary during render
This code:

    let start = ensure_grapheme_boundary_next(text, text.byte_to_char(start));
    let end = ensure_grapheme_boundary_next(text, text.byte_to_char(end));

Would convert byte to char index, but then internally immediately convert back
to byte index, operate on it, then convert it to char index.

This change reduces the amount of time spent in ensure_grapheme_boundary from
29% to 2%.
2 years ago
Blaž Hrastnik 9d41113ae0 Make Layer::parse take &mut tree_sitter::Parser 2 years ago
Blaž Hrastnik e22dbf102f Use filter_map rather than flat_map 2 years ago
Blaž Hrastnik 2f4a9fea03 Set byte range on cursor again 2 years ago
Blaž Hrastnik 24314bd844 Only call scopes.load() once 2 years ago
Blaž Hrastnik 4b0205f690 Resolve some outdated comments 2 years ago
Blaž Hrastnik 9508684031 fix: Skip modifying the root layer range, it always covers 0..max 2 years ago
Blaž Hrastnik 7315f6f3e4 Update range markers so we can determine which layers can be reused 2 years ago
Blaž Hrastnik 8a53e34e66 Try to reuse an existing layer based on layer.ranges 2 years ago
Blaž Hrastnik 72eb2ce1f1 Ignore layers without highlight captures, avoid cloning ranges 2 years ago
Blaž Hrastnik 5135fa37eb Reuse the source slice between layers 2 years ago
Blaž Hrastnik 53d881f172 Store theme scopes on the loader, this way theme isn't passed around 2 years ago
Blaž Hrastnik 6728e44490 syntax: Split parsing and highlighting 2 years ago
NNB 83bde1004d
Add markup support (#1525)
* Add markup support for all Base16 themes

* Fix rose_pine `markup.link.text` attribute misname

* Add basic default markup support for all themes

* Fix cursor change color on Base16 terminal and default

* Remove old markup monokai_pro support and fix Onedark `markup.link.text` attribute misname

* Remove old markup dracula support
2 years ago
Daniel Flanagan b8cafee9f5
docs: Fix typo in book (#1537)
* docs: Fix typo in book

* Update book/src/usage.md

Co-authored-by: Eric Crosson <EricCrosson@users.noreply.github.com>

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
Co-authored-by: Eric Crosson <EricCrosson@users.noreply.github.com>
2 years ago
Rohan Jain 1c747674b6
Add `tag` to gruvbox theme (#1555)
Missed in the commit 943fca332e.
2 years ago
Sebastian Zivota 5c1a06d28e
dracula theme: add markup support (#1554) 2 years ago
Jared Ramirez 0b55b21f30
feat(languages): GraphQL (#1515)
* Add Graphql language support

* Fix docs gen

* Add JS Graphql injection query

* Updates based on PR feedback

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
2 years ago
Michael Davis f453f8724d
change show_subtree command into ':tree-sitter-subtree' typable command (#1524)
* add default keymap for show_subtree command

* remove space+t keymap

* add a typable command ':show-subtree'

* generate documentation for ':show-subtree'

* remove non-typable show_subtree command

* ':show-subtree'->':tree-sitter-subtree'
2 years ago
WindSoilder 4563832318
add markup support for monokai pro themes (#1553) 2 years ago
Michael Davis 392dfa0841
add select_next_sibling and select_prev_sibling commands (#1495)
* add select_next_sibling and select_prev_sibling commands

* refactor objects to use higher order functions

* address clippy feedback

* move selection cloning into commands

* add default keybindings under left/right brackets

* use [+t,]+t for selecting sibling syntax nodes

* setup Alt-{j,k,h,l} default keymaps for syntax selection commands

* reduce boilerplate of select_next/prev_sibling in commands

* import tree-sitter Node type in commands
2 years ago
Mathis Brossier fd7080498e
tree sitter comments injections (#1527)
* tree sitter comments injections

* trailing newlines & julia fix

* Update runtime/queries/julia/injections.scm

Co-authored-by: Michael Davis <michael.davis@nfiindustries.com>

Co-authored-by: Michael Davis <michael.davis@nfiindustries.com>
2 years ago
Jared Ramirez b2c8aa1ee7
feat(languages): Elm (#1514)
* Add Elm language support

* Fix docs gen

* Updates based on PR feedback
2 years ago
Ivan Tham 440d4ae9df
Add terminal emulator to bug report (#1535) 2 years ago
dependabot[bot] 22b728d1eb
build(deps): bump libloading from 0.7.2 to 0.7.3 (#1530)
Bumps [libloading](https://github.com/nagisa/rust_libloading) from 0.7.2 to 0.7.3.
- [Release notes](https://github.com/nagisa/rust_libloading/releases)
- [Commits](https://github.com/nagisa/rust_libloading/commits/0.7.3)

---
updated-dependencies:
- dependency-name: libloading
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2 years ago
dependabot[bot] 89eb22525b
build(deps): bump serde_json from 1.0.74 to 1.0.75 (#1531)
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.74 to 1.0.75.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.74...v1.0.75)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2 years ago
dependabot[bot] ed45d380eb
build(deps): bump smallvec from 1.7.0 to 1.8.0 (#1532)
Bumps [smallvec](https://github.com/servo/rust-smallvec) from 1.7.0 to 1.8.0.
- [Release notes](https://github.com/servo/rust-smallvec/releases)
- [Commits](https://github.com/servo/rust-smallvec/compare/v1.7.0...v1.8.0)

---
updated-dependencies:
- dependency-name: smallvec
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2 years ago
Skyler Hawthorne 96d4ca5f73
Dependabot/cargo/pulldown cmark 0.9.1 (#1533)
* build(deps): bump pulldown-cmark from 0.8.0 to 0.9.1

Bumps [pulldown-cmark](https://github.com/raphlinus/pulldown-cmark) from 0.8.0 to 0.9.1.
- [Release notes](https://github.com/raphlinus/pulldown-cmark/releases)
- [Commits](https://github.com/raphlinus/pulldown-cmark/compare/v0.8.0...v0.9.1)

---
updated-dependencies:
- dependency-name: pulldown-cmark
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* cmark 0.9 fixes

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2 years ago
Skyler Hawthorne 56a9ce5d83
fix(auto_pairs): fix auto pairs with crlf (#1470)
Auto pairs were resulting in incorrect ranges in the resulting when the
line terminators are CRLF (i.e. Windows). It turns out this is because
when we were checking if the selection was a single-width cursor, it
incorrectly assumed that this would be a single char. This is not the
case, as a cursor can cover a multi-code point grapheme. Therefore,
we must instead explicitly work with and check graphemes to determine
if the cursor should move or extend the selection.

Fixes #1436
2 years ago