canola.nvim/README.md
Barrett Ruth 0d3088f57e
refactor: rename oil to canola across entire codebase (#70)
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.
2026-03-05 14:50:10 -05:00

3 KiB

canola.nvim

A refined oil.nvim — edit your filesystem like a buffer, with bug fixes and community PRs that haven't landed upstream.

Upstream tracker — full PR and issue triage against oil.nvim

https://user-images.githubusercontent.com/506791/209727111-6b4a11f4-634a-4efa-9461-80e9717cea94.mp4

Features

  • Edit directory listings as normal buffers — mutations are derived by diffing
  • Cross-directory move, copy, and rename across any adapter
  • Adapters for local filesystem, SSH, S3, and OS trash
  • File preview in split or floating window
  • Configurable columns (icon, size, permissions, timestamps)
  • Executable file highlighting and filetype-aware icons
  • Floating window and split layouts

Requirements

Installation

Install with your package manager of choice or via luarocks:

luarocks install canola.nvim

Documentation

:help canola.nvim

FAQ

Q: How do I migrate from stevearc/oil.nvim?

Change the plugin source and replace setup() with vim.g.canola in init. The configuration table is identical — only the entry point changes. For example, with lazy.nvim:

Before (stevearc/oil.nvim):

{
  'stevearc/oil.nvim',
  opts = { ... },
  config = function(_, opts)
    require('canola').setup(opts)
  end,
}

After (barrettruth/canola.nvim):

{
  'barrettruth/canola.nvim',
  init = function()
    vim.g.canola = { ... }
  end,
}

init runs before the plugin loads; config runs after. oil.nvim reads vim.g.canola at load time, so init is the correct hook. Do not use config, opts, or lazy — oil.nvim loads itself when you open a directory.

Q: Why "canola"?

From the vim-vinegar README, a quote by Drew Neil:

Split windows and the project drawer go together like oil and vinegar

Q: What are some alternatives?

Acknowledgements