Skip to content

Commit

Permalink
docs: usage updated
Browse files Browse the repository at this point in the history
  • Loading branch information
dundee committed Apr 21, 2024
1 parent a3ad561 commit 059ac66
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 32 deletions.
2 changes: 1 addition & 1 deletion .tool-versions
Original file line number Diff line number Diff line change
@@ -1 +1 @@
golang 1.22.1
golang 1.22.2
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ Flags:
-m, --max-cores int Set max cores that GDU will use. 8 cores available (default 8)
-c, --no-color Do not use colorized output
-x, --no-cross Do not cross filesystem boundaries
--no-delete Disable write operations
--no-delete Do not allow deletions
-H, --no-hidden Ignore hidden directories (beginning with dot)
--no-mouse Do not use mouse
--no-prefix Show sizes as raw numbers without any prefixes (SI or binary) in non-interactive mode
Expand All @@ -71,16 +71,17 @@ Flags:
-v, --version Print version
--write-config Write current configuration to file (default is $HOME/.gdu.yaml)
In interactive mode:
Basic list of actions in interactive mode (show help modal for more):
↑ or k Move cursor up
↓ or j Move cursor down
→ or Enter Go to highlighted directory
→ or Enter or l Go to highlighted directory
← or h Go to parent directory
d Delete the selected file or directory
e Empty the selected directory
n Sort by name
s Sort by size
c Show number of items in directory
? Show help modal
```

## Examples
Expand Down Expand Up @@ -189,7 +190,7 @@ To enable:
echo "delete-in-background: true" >> ~/.gdu.yaml
```

Directory items can be also deleted in parallel, which can increase the speed of deletion.
Directory items can be also deleted in parallel, which might increase the speed of deletion.
To enable:

```
Expand Down
40 changes: 15 additions & 25 deletions gdu.1
Original file line number Diff line number Diff line change
@@ -1,36 +1,17 @@
.\" Automatically generated by Pandoc 3.0
.\" Automatically generated by Pandoc 3.1.7
.\"
.\" Define V font for inline verbatim, using C font in formats
.\" that render this, and otherwise B font.
.ie "\f[CB]x\f[]"x" \{\
. ftr V B
. ftr VI BI
. ftr VB B
. ftr VBI BI
.\}
.el \{\
. ftr V CR
. ftr VI CI
. ftr VB CB
. ftr VBI CBI
.\}
.TH "gdu" "1" "2023-02-06" "" ""
.hy
.TH "gdu" "1" "2024-04-21" "" ""
.SH NAME
.PP
gdu - Pretty fast disk usage analyzer written in Go
.SH SYNOPSIS
.PP
\f[B]gdu [flags] [directory_to_scan]\f[R]
.SH DESCRIPTION
.PP
Pretty fast disk usage analyzer written in Go.
.PP
Gdu is intended primarily for SSD disks where it can fully utilize
parallel processing.
However HDDs work as well, but the performance gain is not so huge.
.SH OPTIONS
.PP
\f[B]-h\f[R], \f[B]--help\f[R][=false] help for gdu
.PP
\f[B]-i\f[R], \f[B]--ignore-dirs\f[R]=[/proc,/dev,/sys,/run] Absolute
Expand Down Expand Up @@ -71,6 +52,9 @@ non-interactive mode
.PP
\f[B]-a\f[R], \f[B]--show-apparent-size\f[R][=false] Show apparent size
.PP
\f[B]-C\f[R], \f[B]--show-item-count\f[R][=false] Show number of items
in directory
.PP
\f[B]--si\f[R][=false] Show sizes with decimal SI prefixes (kB, MB, GB)
instead of binary prefixes (KiB, MiB, GiB)
.PP
Expand All @@ -79,11 +63,12 @@ prefixes (SI or binary) in non-interactive mode
.PP
\f[B]--no-mouse\f[R][=false] Do not use mouse
.PP
\f[B]-f\f[R], \f[B]-\[em]input-file\f[R] Import analysis from JSON file.
\f[B]--no-delete\f[R][=false] Do not allow deletions
.PP
\f[B]-f\f[R], \f[B]--input-file\f[R] Import analysis from JSON file.
If the file is \[dq]-\[dq], read from standard input.
.PP
\f[B]-o\f[R], \f[B]-\[em]output-file\f[R] Export all info into file as
JSON.
\f[B]-o\f[R], \f[B]--output-file\f[R] Export all info into file as JSON.
If the file is \[dq]-\[dq], write to standard output.
.PP
\f[B]--config-file\f[R]=\[dq]$HOME/.gdu.yaml\[dq] Read config from file
Expand All @@ -97,9 +82,14 @@ collection during analysis with constant level set by GOGC
\f[B]--enable-profiling\f[R][=false] Enable collection of profiling data
and provide it on http://localhost:6060/debug/pprof/
.PP
\f[B]--use-storage\f[R][=false] Use persistent key-value storage for
analysis data (experimental)
.PP
\f[B]-r\f[R], \f[B]--read-from-storage\f[R][=false] Read analysis data
from persistent key-value storage
.PP
\f[B]-v\f[R], \f[B]--version\f[R][=false] Print version
.SH FILE FLAGS
.PP
Files and directories may be prefixed by a one-character flag with
following meaning:
.TP
Expand Down
12 changes: 10 additions & 2 deletions gdu.1.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,15 +56,19 @@ non-interactive mode

**-a**, **\--show-apparent-size**\[=false\] Show apparent size

**-C**, **\--show-item-count**\[=false\] Show number of items in directory

**\--si**\[=false\] Show sizes with decimal SI prefixes (kB, MB, GB) instead of binary prefixes (KiB, MiB, GiB)

**\--no-prefix**\[=false\] Show sizes as raw numbers without any prefixes (SI or binary) in non-interactive mode

**\--no-mouse**\[=false\] Do not use mouse

**-f**, **\----input-file** Import analysis from JSON file. If the file is \"-\", read from standard input.
**\--no-delete**\[=false\] Do not allow deletions

**-f**, **\--input-file** Import analysis from JSON file. If the file is \"-\", read from standard input.

**-o**, **\----output-file** Export all info into file as JSON. If the file is \"-\", write to standard output.
**-o**, **\--output-file** Export all info into file as JSON. If the file is \"-\", write to standard output.

**\--config-file**=\"$HOME/.gdu.yaml\" Read config from file

Expand All @@ -74,6 +78,10 @@ non-interactive mode

**\--enable-profiling**\[=false\] Enable collection of profiling data and provide it on http://localhost:6060/debug/pprof/

**\--use-storage**\[=false\] Use persistent key-value storage for analysis data (experimental)

**-r**, **\--read-from-storage**\[=false\] Read analysis data from persistent key-value storage

**-v**, **\--version**\[=false\] Print version

# FILE FLAGS
Expand Down

0 comments on commit 059ac66

Please sign in to comment.