Commit Graph

4116 Commits (87518db1d12ea48a4d2fce7808e24852992b03ee)
 

Author SHA1 Message Date
Jared Beller 87518db1d1
dhall: additional highlight queries (#5959) 1 year ago
Erasin c71b4c5579
Update grammar for godot (#5944)
* update grammar for gdscript.
* add comment injections for gdscript.
* add indent for gdscript
* add file-type support for godot-resource
1 year ago
Mike Trinkala ef221abe83
Prevent a panic when uncommenting a line with only a comment token (#5933)
Open a new document `test.rs` and type the following:
`di//<esc><C-c>`

The margin calculation pushes the range out of bounds for the comment
marker when there are no characters (newline) after it.

thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value:
Char range out of bounds: char range 0..3,
Rope/RopeSlice char length 2', ropey-1.6.0/src/rope.rs:546:37

The debug build catches the error in the transaction: thread 'main'
panicked at 'attempt to subtract with overflow',
helix-core/src/transaction.rs:503:26
1 year ago
John DeSilva a4751db8c7 Remove outdated tutor note about increment and decrement behavior 1 year ago
Aleksey Kuznetsov 3b301a9d1d
Add comment-token to the hosts language definition (#5914) 1 year ago
Gokul Soumya 425315d752 Fix completion doc popup area calculation logic
Earlier the doc popup would draw over the compeltion popup
itself and sometimes over the cursor too.
1 year ago
Gokul Soumya 1562b5ce67 Create popup rect instead of using raw values 1 year ago
Gokul Soumya 0f844ef191 Refactor our Markdown construction in completion doc 1 year ago
Gokul Soumya 937825e8fc Rename completion doc popup area variables 1 year ago
Gokul Soumya 8e9c329952 Use early return in rendering completion doc 1 year ago
Pascal Kuthe 93c7afc4ed
Negotiate LSP Position Encoding (#5894)
So far LSP always required that `PositionEncoding.characters` is an
UTF-16 offset. Now that LSP 3.17 is available in `lsp-types` request
the server to send char offsets (UTF-32) or byte offsets (UTF-8)
instead. For compatability with old servers, UTF-16 remains as the
fallback as required by the standard.
1 year ago
Daniel S Poulin 6929a12f29
Make `m` textobject look for pairs enclosing selections (#3344)
* Make `m` textobject look for pairs enclosing selections

Right now, this textobject only looks for pairs that surround the
cursor. This ensures that the pair found encloses each selection, which
is likely to be intuitively what is expected of this textobject.

* Simplification of match code

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

* Adjust logic for ensuring surround range encloses selection

Prior, it was missing the case where the start of the selection came
before the opening brace. We also had an off-by-one error where if the
end of the selection was on the closing brace it would not work.

* Refactor to search for the open pair specifically to avoid edge cases

* Adjust wording of autoinfo to reflect new functionality

* Implement tests for surround functionality in new integration style

* Fix handling of skip values

* Fix out of bounds error

* Add `ma` version of tests

* Fix formatting of tests

* Reduce indentation levels for readability, and update comments

* Preserve each selection's direction with enclosing pair surround

* Add test case for multiple cursors resulting in overlap

* Mark known failures as TODO

* Make tests multi-threaded or they fail

* Cargo fmt

* Fix typos in integration test comments

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
1 year ago
lesleyrs af1157f37c
Add exit code to command failed msg (#5898) 1 year ago
Colton Clemmer ea3293b4da
Split modification indicator from file statusline elements (#4731) 1 year ago
ath3 1840d775c8
Added tree-sitter-hosts (#4950) 1 year ago
ath3 189c3c2ddc
Add tree-sitter-passwd (#4959) 1 year ago
Pascal Kuthe 8a3ec443f1
Fix new clippy lints (#5892) 1 year ago
Mike Trinkala 9d73a0d112
Fix the infinite loop when copying the cursor to the top of the file (#5888)
Example:
```
test
testitem
```

Select line 2 with x, then type Alt-C; Helix will go into an infinite
loop. The saturating_sub keeps the head_row and anchor_row pinned at 0,
and a selection is never made since the first line is too short.
1 year ago
Pascal Kuthe 7ebcf4e919
properly handle LSP position encoding (#5711)
* properly handle LSP position encoding

* add debug assertion to Transaction::change

* Apply suggestions from code review

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

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
1 year ago
Blaž Hrastnik 8a602995fa
Address new clippy lints 1 year ago
Pascal Kuthe e474779c87
bump msrv to 1.63 (#5570)
* bump msrv to 1.63

* resolve new complex type clippy lints
1 year ago
Pascal Kuthe bd14f5a72c
update bug report template (#5872) 1 year ago
Blaž Hrastnik 8e2eab1a6f
Also run build checks on merge queue 1 year ago
zSchoen 882fa11d17
Add `Containerfile` file-type for dockerfile language (#5873) 1 year ago
Clément Delafargue f386ff795d
Check for external file modifications when writing (#5805)
`:write` and other file-saving commands now check the file modification
time before writing to protect against overwriting external changes.

Co-authored-by: Gustavo Noronha Silva <gustavo@noronha.dev.br>
Co-authored-by: LeoniePhiline <22329650+LeoniePhiline@users.noreply.github.com>
Co-authored-by: Pascal Kuthe <pascal.kuthe@semimod.de>
1 year ago
gavincrawford 00ecc556a8
Fix Go select indenting (#5713)
* Fix Go  indenting

* Fix bracket outdent predicate

* Fix brace indenting (again)
1 year ago
Matthew Toohey 05c5207265
feat: add pem language (#5797) 1 year ago
Surendrajat fce30c0da0
xml: add mobileconfig & plist file types (#5863) 1 year ago
Mike Trinkala c704701714
Short-circuit the word and treesitter object movement commands (#5851)
The loop always iterates the number of times the user specified even
if the beginning/end of the document is reached.

For an extreme demonstration try the following commands, Helix will
hang for several seconds.
100000000w
100000000]c
1 year ago
Michael Davis 23ed8c12f1
Select change range for goto_first/last_change commands (#5206)
This matches the behavior from 42ad1a9e04
but for the first and last change. The selection rules are the same
as for goto_next/prev_change: additions and modifications select the
added and modified range while deletions are represented with a point.
1 year ago
Jesús González f71f27f804
Add Darcula Solid theme (#5778)
* Add Darcula Solid theme.

* Update darcula solid theme.

* Derive darcula-solid theme from original darcula
1 year ago
Kirawi fb149133db
Make `fleet-dark` accurate to the official theme (#5605) 1 year ago
dependabot[bot] 7f6a91fd63
build(deps): bump ropey from 1.5.1 to 1.6.0 (#5859)
Bumps [ropey](https://github.com/cessen/ropey) from 1.5.1 to 1.6.0.
- [Release notes](https://github.com/cessen/ropey/releases)
- [Changelog](https://github.com/cessen/ropey/blob/master/CHANGELOG.md)
- [Commits](https://github.com/cessen/ropey/compare/v1.5.1...v1.6.0)

---
updated-dependencies:
- dependency-name: ropey
  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>
1 year ago
dependabot[bot] 9b69f5010d
build(deps): bump anyhow from 1.0.68 to 1.0.69 (#5858)
Bumps [anyhow](https://github.com/dtolnay/anyhow) from 1.0.68 to 1.0.69.
- [Release notes](https://github.com/dtolnay/anyhow/releases)
- [Commits](https://github.com/dtolnay/anyhow/compare/1.0.68...1.0.69)

---
updated-dependencies:
- dependency-name: anyhow
  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>
1 year ago
dependabot[bot] f3f8660d36
build(deps): bump serde_json from 1.0.91 to 1.0.92 (#5857)
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.91 to 1.0.92.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.91...v1.0.92)

---
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>
1 year ago
dependabot[bot] b97462ea9b
build(deps): bump unicode-segmentation from 1.10.0 to 1.10.1 (#5856)
Bumps [unicode-segmentation](https://github.com/unicode-rs/unicode-segmentation) from 1.10.0 to 1.10.1.
- [Release notes](https://github.com/unicode-rs/unicode-segmentation/releases)
- [Commits](https://github.com/unicode-rs/unicode-segmentation/compare/v1.10.0...v1.10.1)

---
updated-dependencies:
- dependency-name: unicode-segmentation
  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>
1 year ago
dependabot[bot] 093b37d7e7
build(deps): bump cachix/install-nix-action from 18 to 19 (#5855)
Bumps [cachix/install-nix-action](https://github.com/cachix/install-nix-action) from 18 to 19.
- [Release notes](https://github.com/cachix/install-nix-action/releases)
- [Commits](https://github.com/cachix/install-nix-action/compare/v18...v19)

---
updated-dependencies:
- dependency-name: cachix/install-nix-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 year ago
Ethan Budd 9c98043c1c
Recognize .C and .H file types as cpp (#5808) 1 year ago
Jaeho Choi 0eba0db4a0
docs: Fix PowerShell runtime linking command (#5822) 1 year ago
Skyler Hawthorne b2e83f81e1
enable rendering in integration tests (#5819)
This will allow testing more of the code base, as well as enable UI-
specific testing.

Debug mode builds are prohibitively slow for the tests, mostly
because of the concurrency write tests. So there is now a profile for
integration tests that sets the optimization level to 2 for a few helix
crates, and lowers the number of rounds of concurrent writes to 1000.
1 year ago
Alex d6e2434f73
Add `ui.virtual.wrap` to theme docs (#5823) 1 year ago
Aleksey Kuznetsov 7b46a6cada
Add Podfile and *.podspec to the file types for ruby (#5811) 1 year ago
William Etheredge f7bd7b5eaf
Add :character-info command (#4000) 1 year ago
Brett Lyons d8f482e11e
Add MSBuild language based on XML grammar (#5793) 1 year ago
LeoniePhiline 30412366be
feat: Update `tree-sitter-sql` and migrate `highlights.scm` to match grammar (#5772)
* Sort buildin functions alphabetically

* fix: Query float type like other numeric types

* Update tree-sitter-sql and update highlights.scm to match grammar
1 year ago
Cemal Okten 10fee815c4
Add Jellybeans theme (#5719) 1 year ago
Pascal Kuthe 350535208f
always commit to history when pasting (#5790) 1 year ago
Skyler Hawthorne a5233cf5ad disable lsp in integration tests 1 year ago
Skyler Hawthorne 06d095f31c provide option to completely disable lsp 1 year ago
Skyler Hawthorne 0e038fb80c make clipboard message debug 1 year ago