/get-started

Permission modes.

Nilux can read your files, change them and run commands. A permission mode decides which of those it does on its own and which it asks you about first. The current mode is shown at the bottom of the screen.

The four modes

  • Default: Nilux reads and searches on its own, and asks before it changes a file or runs a command. Start here.
  • Accept Edits: it also changes files without asking. Commands still ask.
  • Plan: it only reads and searches. It cannot change anything; it works out a plan and shows it to you. See Plan mode below.
  • Auto: it does everything on its own, without asking. It still refuses actions that could do damage that cannot be undone (see below).

Switching modes

  • Press Shift+Tab to go through the modes in order. The new mode applies after a moment, or as soon as you send a message.
  • Or type /mode to pick one from a list, or /mode auto (also default, accept, plan) to switch straight to it.

A new session starts in Default. /resume brings back the mode the conversation had.

What always needs you

Some commands are risky enough that Nilux never runs them on its own. In Default and Accept Edits it asks every time, and no saved rule or hook can approve them. For example:

  • deleting a folder with everything in it (rm -r and the like);
  • git reset, git push, git clean, git rebase and other commands that rewrite or throw away work;
  • formatting a disk, dd, shutting the computer down;
  • dropping a database table;
  • running a script downloaded from the internet straight into the shell.

Deleting a single file (rm notes.txt) asks every time as well, and Yes, always allow… is not offered for it: a harmless first deletion must not open the door to the next one.

In Auto mode Nilux never stops to ask. Instead it refuses the actions that cannot be undone, such as force-pushing, dropping a table or wiping a disk, and tells you why. Ordinary work runs, and before deleting a few files in your project it keeps a copy, so /rewind can bring them back.

Working outside the project

Nilux works inside the folder you started it in. Before it touches a file somewhere else, it asks, except in Auto mode. To let it work in another folder without asking, add the folder:

bash
❯/add-dir ~/projects/shared-components

/add-dir alone lists the folders you added; /add-dir remove <path> takes one off.

Trusted folders

The first time you start Nilux in a folder, it asks whether you trust it. If the project contains its own Nilux rules, you see them before you answer. Answer n and Nilux exits. /trust lists the folders you trust; /trust remove <number> removes one.

Plan mode

Plan mode is for thinking before doing: Nilux studies the code and proposes a plan, and nothing changes until you agree.

  1. Enter plan mode with Shift+Tab, or Nilux may suggest it for a larger task.
  2. While planning, Nilux reads and searches but cannot change files or run commands.
  3. Review the plan. Choose Approve & implement to leave plan mode and start the work, No, keep planning to stay, or Send feedback to say what to change.
  4. If there is nothing to build (you only asked a question), Nilux just asks whether to leave plan mode.

An approved plan is saved with the project and kept even after /clear, so a long task does not lose its thread.

A different model for planning

In /config, Plan Model lets you plan with one model and do the work with another. Leave it on inherit unless you need it: switching models in the middle of a conversation makes the new model read the whole conversation again at the full price, once when planning starts and again when it ends.