Commit Graph

20 Commits (f49b18d157f5122dc8b5e3569ea3c5d6e598b0c4)

Author SHA1 Message Date
rhogenson 5717aa8e35
Fix Rope.starts_with. (#11739)
Co-authored-by: Rose Hogenson <rosehogenson@posteo.net>
2 months ago
Blaž Hrastnik 0929704699 stdx: ...and this cast is now unnecessary 3 months ago
Blaž Hrastnik 7d017d8fd6 stdx: PSID now sits under Win32::Foundation 3 months ago
RoloEdits 86aecc96a1
chore: clean up clippy lints (#11377)
Using clippy 1.80.0. Also cleans up some that were windows only.
4 months ago
Kirawi e5372b04a1
Fix writing hardlinks (#11340)
* don't use backup files with hardlinks

* check if the inodes remain the same in the test

* move funcs to faccess and use AsRawHandle

* use a copy as a backup for hardlinks

* delete backup after copy
4 months ago
Pascal Kuthe 8444f52e9a
correctly handle opening helix inside symlinked directory (#10728)
* correctly handle opening helix inside symlinked directory

* Update helix-stdx/src/env.rs

---------

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
6 months ago
Pascal Kuthe 73d26d0d97
don't manually grapheme align ts highlights (#10310) 7 months ago
Kirawi 88d455afeb
Use a temporary file for writes (#9236)
Co-authored-by: Pascal Kuthe <pascalkuthe@pm.me>
8 months ago
Mo 1d1087822a
Use the OS path separator instead of / (#10000) 8 months ago
mo8it 0f5430ab9e Optimize get_truncated_path 8 months ago
mo8it e91ec8e880 Optimize getting a relative path 8 months ago
mo8it 6ed93b6e49 Optimize fold_home_dir 8 months ago
mo8it 6607938bf8 Call as_ref only once 8 months ago
Gabriel Dinner-David 26b3dc29be
toggling of block comments (#4718) 9 months ago
Pascal Kuthe cd02976fa3
switch to regex-cursor (#9422) 9 months ago
Mo 6db666fce1
Optimization of tilde expansion (#9709)
* Use next and avoid a redundant prefix strip

* Avoid allocations

Especially when `expand_tilde` is claled on a path
that doesn't contain a tilde.

* Add a test

* Use Into<Cow<…>>

* Put the expand_tilde test at the end of the file

* Remove unused importsw
9 months ago
Michael Davis cb25d13028 Improve error handling for `which::which` failures
Co-authored-by: Pascal Kuthe <pascalkuthe@pm.me>
10 months ago
Michael Davis 6d724a8f33 Re-export `which` from `helix-stdx::env`
We use `which::which` in many crates, so `which` was a separate
dependency across all of them. We can centralize `which` into the
stdx crate so it's easy for all crates to depend on it.

I also moved the rest of `helix-view/src/env.rs` into helix-stdx's
`env` module since it only contained a thin wrapper around `which`
and `std::env`.
10 months ago
Pascal Kuthe 8e592a151f refactor completion and signature help using hooks 10 months ago
Michael Davis 1f916e65cf Create helix-stdx crate for stdlib extensions
helix-stdx is meant to carry extensions to the stdlib or low-level
dependencies that are useful in all other crates. This commit starts
with all of the path functions from helix-core and the CWD tracking that
lived in helix-loader.

The CWD tracking in helix-loader was previously unable to call the
canonicalization functions in helix-core. Switching to our custom
canonicalization code should make no noticeable difference though
since `std::env::current_dir` returns a canonicalized path with
symlinks resolved (at least on unix).
10 months ago