git404hub

what is nclean fr?

p0nczek/nclean — explained in plain English

Analysis updated 2026-05-18

16PythonAudience · developerComplexity · 2/5LicenseSetup · easy

tl;dr

A terminal tool for NixOS that lists old system generations and lets you mark and delete the ones you no longer need.

vibe map

mindmap
  root((nclean))
    What it does
      Lists NixOS generations
      Marks and deletes generations
      Runs garbage collection
    Tech stack
      Python
      curses TUI
      nh command
    Use cases
      Free disk space
      Manage generation history
      Background refresh
    Audience
      NixOS users
      Developers

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

what do people make with this?

VIBE 1

Browse a list of NixOS system generations with build date, version, and disk usage.

VIBE 2

Mark and delete multiple old generations at once to free up disk space.

VIBE 3

Automatically run garbage collection right after deleting old generations.

VIBE 4

Run nclean once without installing it, or add it permanently to your Nix profile.

what's the stack?

PythonNixcurses

how it stacks up fr

p0nczek/nclean920linjerry-stack/capital-studioadya84/ha-world-cup-2026
Stars161616
LanguagePythonPythonPython
Setup difficultyeasyeasyeasy
Complexity2/53/52/5
Audiencedeveloperresearchergeneral

Figures from each repo's GitHub metadata at analysis time.

how do i run it?

Difficulty · easy time til it works · 5min

Requires the nh tool on PATH and sudo access for nix-env and nix-collect-garbage.

MIT, use freely for any purpose, including commercial use, as long as you keep the copyright notice.

in plain english

nclean is a small terminal application for NixOS users that helps you browse and delete old system generations. NixOS keeps a history of every configuration you have ever built, called generations, and over time these can pile up and take a lot of disk space. Instead of running commands by hand, nclean gives you a simple text based interface, built with the curses library, where you can see all your generations at a glance along with their build date, NixOS version, kernel, and how much disk space each one takes up. Inside the interface, you move up and down the list with the arrow keys, mark individual generations you want to remove, or mark everything below your current position at once. Once you have made your selections, pressing a key deletes them after asking for confirmation, using the standard sudo nix-env delete generations command under the hood. There is also an option to automatically run a garbage collection step after deleting, which frees up the actual disk space rather than just removing the generation record. The list refreshes automatically every thirty seconds, and you can also force a refresh manually, all while the interface keeps working in the background since the refresh runs on a separate thread. Your current, active generation can never be accidentally marked or deleted. To install it, you need the nh tool available on your system, along with sudo access to run the relevant Nix commands. If you use Nix, you can either run nclean once without permanently installing it, or add it to your Nix profile so the nclean command is always available in your terminal. It can also be added as an input to a NixOS or home-manager configuration. The README notes this project was built with AI assistance and that the author is not a professional developer, though they say it has been reviewed and tested. It asks anyone who finds bugs, especially anything involving sudo, to open an issue or pull request, and it is released under the MIT license.

prompts (copy fr)

prompt 1
Help me install nclean using nix profile add on my NixOS system.
prompt 2
Explain what happens when I press d to delete marked generations in nclean.
prompt 3
Walk me through adding nclean as a flake input to my home-manager configuration.
prompt 4
Show me how nclean's background refresh thread keeps the interface from freezing.

Frequently asked questions

what is nclean fr?

A terminal tool for NixOS that lists old system generations and lets you mark and delete the ones you no longer need.

What language is nclean written in?

Mainly Python. The stack also includes Python, Nix, curses.

What license does nclean use?

MIT, use freely for any purpose, including commercial use, as long as you keep the copyright notice.

How hard is nclean to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is nclean for?

Mainly developer.

peek the repo → explain another one

This repo across BitVibe Labs

double-check against the repo, no cap.