No description
Find a file
Eric Joldasov c83159f076
fix new "var never mutated" error on Zig 0.12.0-dev.1663+6b1a823b2
Fixes these errors (introduced in https://github.com/ziglang/zig/pull/18017
and 6b1a823b2b ):

```
src/main.zig:290:13: error: local variable is never mutated
        var line_ = line_fbs.getWritten();
            ^~~~~
src/main.zig:290:13: note: consider using 'const'
src/main.zig:450:17: error: local variable is never mutated
            var path = std.fs.path.joinZ(allocator, &.{p, "ncdu", "config"}) catch unreachable;
                ^~~~
src/main.zig:450:17: note: consider using 'const'

...
```

Will be included in future Zig 0.12, this fix is backward compatible:
ncdu still builds and runs fine on Zig 0.11.0.

Signed-off-by: Eric Joldasov <bratishkaerik@getgoogleoff.me>
2023-11-20 14:45:02 +06:00
LICENSES Add REUSE-compliant copyright headers 2021-07-18 11:50:50 +02:00
src fix new "var never mutated" error on Zig 0.12.0-dev.1663+6b1a823b2 2023-11-20 14:45:02 +06:00
.gitignore Add REUSE-compliant copyright headers 2021-07-18 11:50:50 +02:00
build.zig replace ncurses_refs.c workaround with pure Zig workaround 2023-11-19 14:37:52 +06:00
ChangeLog Version 2.3 2023-08-04 16:05:31 +02:00
Makefile replace ncurses_refs.c workaround with pure Zig workaround 2023-11-19 14:37:52 +06:00
ncdu.pod Add --(enable|disable)-natsort options 2023-03-05 08:31:31 +01:00
README.md Update to Zig 0.11.0 2023-08-04 14:41:49 +06:00

ncdu-zig

Description

Ncdu is a disk usage analyzer with an ncurses interface. It is designed to find space hogs on a remote server where you don't have an entire graphical setup available, but it is a useful tool even on regular desktop systems. Ncdu aims to be fast, simple and easy to use, and should be able to run in any minimal POSIX-like environment with ncurses installed.

See the ncdu 2 release announcement for information about the differences between this Zig implementation (2.x) and the C version (1.x).

Requirements

  • Zig 0.11.0
  • Some sort of POSIX-like OS
  • ncurses libraries and header files

Install

You can use the Zig build system if you're familiar with that.

There's also a handy Makefile that supports the typical targets, e.g.:

make
sudo make install PREFIX=/usr