aboutsummaryrefslogtreecommitdiff
path: root/util.lua
Commit message (Collapse)AuthorAgeFilesLines
* fix the line number detection with tabsFlorian Fischer2025-06-081-0/+25
| | | | | If a line includes tabs add the visually added space for each tab stop to the line length in order to detect a wrapped line.
* Merge branch 'sel_to_pos_v2' into 'main'Florian Fischer2025-05-151-0/+73
|\ | | | | | | | | | | | | Change vis_sel_to_pos to vis internals or to count lines itself Closes #38 See merge request muhq/vis-lspc!58
| * calculate the positions for multiple selections at onceFlorian Fischer2025-02-141-8/+35
| |
| * move file location converters functions into util moduleFlorian Fischer2025-02-141-0/+46
| | | | | | | | Use the the internal vis logic as fast path if available.
* | fix vis:pipe buffer support detectionFlorian Fischer2025-04-101-1/+1
|/ | | | | | Check a vis:pipe function call like we would call it in vis_pipe. Omitting the fullscreen parameter causes the pcall to succeed, although vis does not support using a string as data source.
* Fix find_upwardsMichiel van den Heuvel2025-02-021-2/+3
| | | | | | | | | | | - Use `util.vis_pipe` instead of `vis:pipe` as this does not work on the current release of vis. - Quote the path to the find-upwards script. It resides in `~/Library/Application Support` on my macOS setup, and while not very common, paths in other users' configurations might have the same issue. - At least during testing, `out` was nil in some cases. `find_upwards` checks it now.
* handle special cases in util.dirnamedetect-rootFlorian Fischer2025-01-111-1/+21
|
* make universal root detection opt-inFlorian Fischer2025-01-111-0/+7
|
* extract the upwards find code into the util moduleFlorian Fischer2025-01-091-0/+17
|
* fix used quotes and remove old code in commentsFlorian Fischer2024-09-151-1/+1
|
* move helper code into the util moduleFlorian Fischer2024-09-151-0/+164