Problem: the canola rename creates unnecessary friction for users
migrating from stevearc/oil.nvim — every `require('oil')` call and
config reference must change.
Solution: revert all module paths, URL schemes, autocmd groups,
highlight groups, and filetype names back to `oil`. The repo stays
`canola.nvim` for identity; the code is a drop-in replacement.
Problem: the codebase still used the upstream \`oil\` naming everywhere —
URL schemes, the \`:Oil\` command, highlight groups, user events, module
paths, filetypes, buffer/window variables, LuaCATS type annotations,
vimdoc help tags, syntax groups, and internal identifiers.
Solution: mechanical rename of every reference. URL schemes now use
\`canola://\` (plus \`canola-ssh://\`, \`canola-s3://\`, \`canola-sss://\`,
\`canola-trash://\`, \`canola-test://\`). The \`:Canola\` command replaces
\`:Oil\`. All highlight groups, user events, augroups, namespaces,
filetypes, require paths, type annotations, help tags, and identifiers
follow suit. The \`upstream\` remote to \`stevearc/oil.nvim\` has been
removed and the \`vim.g.oil\` deprecation shim dropped.
* build: replace luacheck with selene
Problem: luacheck is unmaintained (last release 2018) and required
suppressing four warning classes to avoid false positives. It also
lacks first-class vim/neovim awareness.
Solution: switch to selene with std='vim' for vim-aware linting.
Replace the luacheck CI job with selene, update the Makefile lint
target, and delete .luacheckrc.
* build: add nix devshell and pre-commit hooks
Problem: oil.nvim had no reproducible dev environment. The .envrc
set up a Python venv for the now-removed docgen pipeline, and there
were no pre-commit hooks for local formatting checks.
Solution: add flake.nix with stylua, selene, and prettier in the
devshell. Replace the stale Python .envrc with 'use flake'. Add
.pre-commit-config.yaml with stylua and prettier hooks matching
other plugins in the repo collection.
* fix: format with stylua
* build(selene): configure lints and add inline suppressions
Problem: selene fails on 5 errors and 3 warnings from upstream code
patterns that are intentional (mixed tables in config API, unused
callback parameters, identical if branches for readability).
Solution: globally allow mixed_table and unused_variable (high volume,
inherent to the codebase design). Add inline selene:allow directives
for the 8 remaining issues: if_same_then_else (4), mismatched_arg_count
(1), empty_if (2), global_usage (1). Remove .envrc from tracking.
* build: switch typecheck action to mrcjkb/lua-typecheck-action
Problem: oil.nvim used stevearc/nvim-typecheck-action, which required
cloning the action repo locally for the Makefile lint target. All
other plugins in the collection use mrcjkb/lua-typecheck-action.
Solution: swap to mrcjkb/lua-typecheck-action@v0 for consistency.
Remove the nvim-typecheck-action git clone from the Makefile and
.gitignore. Drop LuaLS from the local lint target since it requires
a full language server install — CI handles it.
* feat: support vim.g.oil declarative configuration
Problem: oil.nvim requires an imperative require("oil").setup(opts)
call to initialize. The Neovim ecosystem is moving toward vim.g.plugin
as a declarative config source that works without explicit setup calls.
Solution: fall back to vim.g.oil in config.setup() when no opts are
passed, and add plugin/oil.lua to auto-initialize when vim.g.oil is
set. Explicit setup(opts) calls still take precedence. Update docs
and add tests for the new resolution order.
Closes: barrettruth/oil.nvim#1
* build: remove release-please pipeline
Problem: the release-please action creates automated releases that
are not needed for this fork's workflow.
Solution: remove the release job from tests.yml and the
release-please branch exclusion from the review request workflow.
* fix(doc): improve readme phrasing
* doc: minor phrasing "improvements"
* ci: add luarocks release on tag push
Problem: there is no automated way to publish oil.nvim to luarocks
when a new version is tagged.
Solution: add a luarocks workflow that triggers on v* tag pushes,
runs the test suite via workflow_call, then publishes via
luarocks-tag-release. Add workflow_call trigger to tests.yml so it
can be reused.
Problem: files were always created with mode 0644 and directories
with 0755, hardcoded in fs.touch and uv.fs_mkdir. Users who need
different defaults (e.g. 0600 for security) had no config option.
Solution: add new_file_mode (default 420 = 0644) and new_dir_mode
(default 493 = 0755) config options, passed through to fs.touch and
uv.fs_mkdir in the files and mac trash adapters. The fs.touch
signature accepts an optional mode parameter with backwards
compatibility (detects function argument to support old callers).
Local cache directories (SSH, S3) continue using standard system
permissions rather than the user-configured mode.
Based on: stevearc/oil.nvim#537
Problem: the is_hidden_file and is_always_hidden config callbacks
only received (name, bufnr), making it impossible to filter by entry
type, permissions, or other metadata without reimplementing entry
lookup.
Solution: pass the full oil.Entry as a third argument to both
callbacks. Existing configs that only accept (name, bufnr) are
unaffected since Lua silently ignores extra arguments. The internal
should_display function signature changes from (name, bufnr) to
(bufnr, entry) to reflect its new contract.
Cherry-picked from: stevearc/oil.nvim#644
Problem: user keymap overrides like <c-t> failed to replace the
default <C-t> because the keys were compared as raw strings during
merge, leaving both entries in the table.
Solution: use nvim_replace_termcodes to compare keymap keys by their
internal representation, removing any default entry that normalizes
to the same key as the user-provided one before inserting it.
Closes#692
Cherry-picked from: stevearc/oil.nvim#725
* Added s3 support
* Save work
* Various bug fixes
* Minor cleanup
* Minor bug fixes
* Fix typo
* Update following feedback + minor bug fix
* Fix CI
* Cleanup and remove bucket entry_type
* Make suggested changes
* Better aws existence check
* Fix typo
* refactor: don't bother caching aws executable status
---------
Co-authored-by: Steven Arcangeli <506791+stevearc@users.noreply.github.com>
Neovim 0.11 introduced the winborder option, which serves the same purpose. By defaulting the border to nil, we will use whatever value the user has configured with winborder.
---------
Co-authored-by: Steven Arcangeli <506791+stevearc@users.noreply.github.com>
* 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>
* 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>
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"
* implement floating window
* reset width on closing window
* use gap from new config parameter
* use minimal style for preview in floating
* lower z-index
* add configuration of preview position in floating window
* fix in verions earlier than nvim 0.10
* close preview on opening floating window
Close the any existing preview because otherwise strange errors happen when the preview is open and the floating window is opened at the same time.
* reset formatting changes
* remove empty line
* change z-index of preview window to floating window z-index
* add configurations to oil.txt
* formatting
* add auto configuration
* update oil doc
* refactor: move logic into layout.lua and eliminate flicker
* fix: floating preview window title is file name
* doc: clarify default_file_explorer
* refactor: don't need a preview_gap option
* refactor: only find preview win in current tabpage
---------
Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
* Adding in SCP options configuration
This changeset adds in additional SCP options to the config. This allows
the user to specify a list of flags to send to the SCP command that will
be expanded into each shell command.
The primary driver for this is from newe boxes SSHing into pre 9 openSSH
boxes. New openSSH uses sftp server under the hood, rather than the
older SCP protocol. If you go into a system that does not have these
changes, SCP fails to work. The '-O' command line flag was introduced to
resolve this.
Using this change, the user can now pass in `extra_scp_options = {"-O"}`
to resolve the issue.
* Replacing table.unpack with global unpack
* lint: apply stylua
* refactor: change option name and shuffle config around
---------
Co-authored-by: Eric Guinn <eric_guinn@selinc.com>
Co-authored-by: Steven Arcangeli <stevearc@stevearc.com>
* feat(windows-trash): support for deleting to windows trash
* feat(windows-trash): add support for view, restore and purge
* fix(windows-trash): undefined path on M.list
* chore(windows-trash): modify comments
* fix(windows-trash): show correct original_path
* fix(windows-trash): add self to powershell_date_grammar
* fix(windows-trash-support): parse deleted date as number
* fix(fs): do not add innecesary \\ on Windows
* feat: extend windows trash adapter
* perf(windows-trash): powershell -> libuv (move, purge and copy)
* fix: don't prompt to save when opening trashed file
* lint: fix luacheck error
* lint: fix luacheck errors
* lint: luacheck error
---------
Co-authored-by: Steven Arcangeli <506791+stevearc@users.noreply.github.com>
* save buffers changed by will_rename_files
* prevent closing already open buffers
* chore: move to config option
* chore: fixes
* fix: a crash and some formatting
---------
Co-authored-by: Steven Arcangeli <506791+stevearc@users.noreply.github.com>