**noil** is a structured, text-buffer-based file operation tool – think of it
like [`oil.nvim`](https://github.com/stevearc/oil.nvim), but for any editor,
terminal, or automated process.
**noil** is a structured, text-buffer-based file operation tool – think of it like [`oil.nvim`](https://github.com/stevearc/oil.nvim), but for any editor, terminal, or automated process.
Edit filesystem operations like it's plain text, and then apply them in a
controlled, explicit way.
Edit filesystem operations like it's plain text, and then apply them in a controlled, explicit way.

@@ -13,19 +10,17 @@ controlled, explicit way.
## Interactive Mode (TBA)
I am planning an interactive TUI mode, where you don't have to care about tags,
like in `oil`. For now the normal editor is quite useful though, and allows all
types of editors to easily move, edit files and so on.
I am planning an interactive TUI mode, where you don't have to care about tags, like in `oil`. For now the normal editor is quite useful though, and allows all types of editors to easily move, edit files and so on.
---
## ✨ Features
- Edit your file tree like a normal buffer
- Preview, format, and apply changes
- Integrates with `$EDITOR`
- CLI first, editor agnostic
- No surprises: nothing is applied until you say so
* Edit your file tree like a normal buffer
* Preview, format, and apply changes
* Integrates with `$EDITOR`
* CLI first, editor agnostic
* No surprises: nothing is applied until you say so
# Optional extra command Space + o will open noil allowing edits and the OPEN command
[keys.normal.space]
o=[
":sh rm -f /tmp/unique-file-kjuulh",
# DISCLAIMER: Until noil has a proper interactive mode, we cannot ask for confirmation, as such we always commit changes, you don't get to have a preview unlike the normal cli option
When using `noil edit .` a few additional options are available
-`--chooser-file`: A chooser file is a newline delimited file where each line
corresponds to a relative file to be opened or manipulated by the user. Only
items with `OPEN` command will be added to the file
-`--commit`: commit files without asking for confirmation
-`--quiet`: don't print results
---
## 🔒 Safety First
@@ -155,9 +123,7 @@ You will be prompted before anything is modified.
## 🧠 Philosophy
noil gives you full control over file operations in a composable and
editor-friendly way. Think Git index, but for actual file moves and deletions —
human-editable, patchable, and grep-able.
noil gives you full control over file operations in a composable and editor-friendly way. Think Git index, but for actual file moves and deletions — human-editable, patchable, and grep-able.
---
@@ -169,6 +135,7 @@ human-editable, patchable, and grep-able.
.ok_or(anyhow::anyhow!("parent doesn't exist for file"))?;
ifparent_path.display().to_string()==""{
returnOk(PathBuf::from("."));
}
returnOk(parent_path);
.ok_or(anyhow::anyhow!("parent doesn't exist for file"));
}
Ok(path.clone())
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.