Commit graph

326 commits

Author SHA1 Message Date
Steven Arcangeli
3c2de37acc debug: include shell command in error message 2024-11-25 09:10:33 -08:00
Steven Arcangeli
da93d55e32 fix: work around performance issue with treesitter, folds, and large directories 2024-11-24 15:04:00 -08:00
Foo-x
99ce32f4a2
feat: config option to customize filename highlight group (#508)
* feat: highlight config

Refs #402

* perf: minimize perf impact when option not provided

* doc: regenerate documentation

* fix: symbolic link rendering

* refactor: simplify conditional

---------

Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
2024-11-22 10:23:08 -08:00
Ezekiel Warren
60e68967e5
feat: highlight groups for hidden files (#459)
* feat: hidden highlights

* feat: OilHidden for hidden highlights instead of Comment

* fix: add the new combinatoric highlight groups

* perf: get rid of a call to is_hidden_file

* fix: tweak the default highlight group links

* fix: update function call in unit tests

---------

Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
2024-11-22 08:55:55 -08:00
Foo-x
740b8fd425
feat: add highlight group for orphaned links (#502)
* feat: add highlight for orphan links

Closes #501

* feat: add OilOrphanLinkTarget highlight group

---------

Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
2024-11-22 08:17:50 -08:00
Steven Arcangeli
3fa3161aa9 feat: config option to disable previewing a file 2024-11-21 17:36:40 -08:00
Steven Arcangeli
5acab3d8a9 fix: image.nvim previews with preview_method=scratch 2024-11-21 17:36:22 -08:00
cdmill
81cc9c3f62
feat: option to quite vim if oil is closed as last buffer (#491)
* feat: auto-quit vim if oil is closed as last buffer

* rename auto_close_vim to auto_close_last_buffer

* rework actions.close to be more like actions.cd

* fix: configure close action correctly

* add type annotation, future proofing

* fix: typo

* fix: typo

* refactor: better type annotations and backwards compatibility

---------

Co-authored-by: Steven Arcangeli <506791+stevearc@users.noreply.github.com>
2024-11-20 21:06:09 -08:00
Jalal El Mansouri
21705a1deb
feat: use scratch buffer for file previews (#467)
* Initial implementation of scratch based preview

* Fix call to buf is valid in loop

* Fixing call to be made only from the main event loop

* Improve handling of large files from @pkazmier

* Better error handling and simplifying the code

* Default to old behavior

* Add documentation

* Fix readfile

* Fix the configuration

* refactor: single config enum and load real buffer on BufEnter

* doc: regenerate documentation

---------

Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
2024-11-19 17:24:24 -08:00
Steven Arcangeli
8ea40b5506 fix: cursor sometimes does not hover previous file 2024-11-14 22:21:11 -08:00
Steven Arcangeli
c96f93d894 perf: optimize rendering cadence 2024-11-14 19:29:22 -08:00
Steven Arcangeli
792f0db6ba perf: only sort entries after we have them all 2024-11-14 19:29:22 -08:00
Steven Arcangeli
4de30256c3 perf: replace vim.endswith and vim.startswith with string.match 2024-11-14 19:29:22 -08:00
Steven Arcangeli
01b0b9d8ef perf: change default view_options.natural_order behavior to disable on large directories 2024-11-14 19:29:22 -08:00
Steven Arcangeli
0472d9296a lint: fix typechecking for new LuaLS version 2024-11-13 08:58:16 -08:00
Micah Halter
bbeed86bde
feat: add win_options to preview_win (#514) 2024-11-12 10:38:35 -08:00
Steve Walker
c23fe08e05
feat: disable preview for large files (#511)
* feat: disable preview for large files

fix: update oil.PreviewWindowConfig

* refactor: remove unnecessary shim in config.lua

* refactor: revert changes to shim

---------

Co-authored-by: Steve Walker <65963536+etherswangel@users.noreply.github.com>
Co-authored-by: Steven Arcangeli <506791+stevearc@users.noreply.github.com>
2024-11-12 08:24:39 -08:00
Steven Arcangeli
2f5d4353ee doc: improve type annotations for oil.open_preview 2024-11-10 16:07:29 -08:00
Steven Arcangeli
eb5497f0ac refactor: rename 'preview' config to 'preview_win' 2024-11-10 15:57:31 -08:00
Steven Arcangeli
1f5b002270 refactor: rename action preview window to 'confirmation' window 2024-11-10 15:57:27 -08:00
Steven Arcangeli
621f8ba4fa fix: guard against nil keymaps 2024-11-09 22:31:35 -08:00
Steven Arcangeli
709403ccd6 fix: don't deep merge keymaps (#510) 2024-11-09 22:28:24 -08:00
Foo-x
52cc8a1fb3
fix: sort keymap help entries by description (#506)
Closes #376
2024-10-30 08:53:36 -07:00
Foo-x
42333bb46e
fix: add trailing slash to directories on yank_entry (#504)
* feat: add trailing slash on yank_entry

Closes #503

* style: format
2024-10-28 10:55:25 -07:00
Yu Guo
cca1631d5e
fix: actions.preview accepts options (#497)
* fix: pass opts to actions.preview

* add opts type to action.preview

* run generate.py script
2024-10-25 09:08:39 -07:00
Philipp Oeschger
5d2dfae655
feat: config option to customize floating window title (#482)
* replace cwd path in actual path

* move get_title to utils

* add documentation

* rename

* add method doc

* add comment

* fallback to 0 for winid

* add missing property definition for relative_win_title

* only replace when at the start of the path

* simplify

* minor change

* add entry point to customize floating window title for oil-buffer

* remove config parameter

* cleanup

* add documentation

* move get_win_title to top and pass winid as parameter

* add get_win_title to type definition for oil.setup

* remove empty line

* adjust comment

---------

Co-authored-by: Philipp Oeschger <philippoeschger@Philipps-Air.fritz.box>
2024-10-15 22:22:31 -04:00
staticssleever668
ccab9d5e09
fix: only map ~ for normal mode (#484)
Allows to switch character case with ~ (tilde) in visual mode while
preserving existing ~ :tcd functionality.
Related to [1].

[1]: https://github.com/stevearc/oil.nvim/issues/397 "bug: ~ not respected"
2024-10-03 20:51:55 -07:00
Éric NICOLAS
9e6fb844fe
doc: Update links to FreeDesktop's Trash spec (#490)
Keeping it pinned to 1.0

Fixes #489
2024-09-30 22:11:09 -07:00
Steven Arcangeli
581c729805 doc: disable some type warnings from new LuaLS release 2024-09-30 22:10:36 -07:00
Steven Arcangeli
1360be5fda lint: stricter type checking 2024-09-17 13:00:48 -07:00
csponge
f60bb7f793
feat: config option to disable lsp file methods (#477)
* added config option to enable or disable lsp_file_methods

* refactor: rename enable -> enabled

---------

Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
2024-09-11 19:41:46 -07:00
Steven Arcangeli
b05374428e fix: wrap git rm callback in schedule_wrap (#475) 2024-09-10 11:44:15 -07:00
Steven Arcangeli
1fe476daf0 doc: more and better type annotations 2024-08-30 17:50:09 -07:00
csponge
30e0438ff0
fix: ensure win_options are being set on correct window (#469)
* Added check for filetype before setting win_options in initialize

* refactor: use nvim_buf_call to set window options

---------

Co-authored-by: Steven Arcangeli <506791+stevearc@users.noreply.github.com>
2024-08-28 17:54:03 -07:00
Micah Halter
0fcd1263a2
perf(view): avoid running is_hidden_file when show_hidden is set (#471) 2024-08-28 17:13:57 -07:00
Steven Arcangeli
70337eb77f fix: gracefully handle trashing file that does not exist 2024-08-25 20:51:27 -07:00
Steven Arcangeli
349bca8c3e fix: process deletes in dir before moving dir 2024-08-25 20:46:46 -07:00
Julian
b39a78959f
fix: add compatibility for Lua 5.1 (#456)
Some architectures don't support LuaJIT.
Remove the goto's from the code to be compatible
with Neovim built without LuaJIT.

Signed-off-by: Julian Ruess <julianonline+github@posteo.de>
2024-08-16 21:33:59 -07:00
Steven Arcangeli
fcca212c2e fix: handle rare case where file watcher outlives buffer 2024-07-29 17:12:25 -07:00
Anna Arad
71c972fbd2
fix: Force standard C locale when getting ls input for parsing in SSH (#455) 2024-07-22 21:17:38 -07:00
Anna Arad
a6cea1a5b9
fix: Handle users and groups with spaces over SSH (#448) 2024-07-21 16:07:10 -07:00
sleeptightAnsiC
cc2332599f
feat: allow bufnr optional parameter for get_current_dir function (#440)
This allows for using get_current_dir in cases where currently hovered
buffer is not the desired Oil buffer (e.g. displaying directories for
multiple different Oil buffers)
2024-07-06 16:24:33 -07:00
Micah Halter
d5e56574f8
fix: correctly check if mini.icons is actually setup (#441)
This leaves the `pcall` just so (1) we load the plugin if it is lazy
loaded by the user and (2) we get LSP completion/validation with that
type as well.
2024-07-06 16:20:44 -07:00
Micah Halter
a543ea598e
feat: add support for mini.icons (#439) 2024-07-05 15:13:10 -07:00
Steven Arcangeli
b5a1abfde0 fix: cursor sometimes disappears after making changes (#438) 2024-07-03 18:14:52 -07:00
icefed
b15e4c1e64
feat: disable cursor in preview window (#433) 2024-07-02 10:31:26 -07:00
icefed
b0a6cf9898
fix: set floating window win_options when buffer changes (#432)
* fix: set floating window win_options when buffer changes

* fix: set win options even when float border is "none"

---------

Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
2024-07-02 10:03:08 -07:00
Philipp Oeschger
2077cc3358
feat: case insensitive sorting (#429)
* check for sorting option in netrw

* documentation

* refactor: remove sort_ prefix

---------

Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
2024-07-01 11:41:04 -07:00
Steven Arcangeli
c7c7ce5bd4 feat: rename experimental_watch_for_changes -> watch_for_changes
I've been using this for a while now and haven't seen any issues. We can
take "experimental" out of the name.
2024-07-01 11:34:04 -07:00
DerpDays
65c53dbe4f
fix: correctly check group permissions in unix (#428)
* fix: set modifiable when user in group

* feat: add mode caching, fallback to previous, and better checking of permissions

* fix: make is_modifiable check group permissions even if the user is owner of the directory

* refactor: simplify group ID caching

---------

Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
2024-06-21 09:07:03 -04:00