https://github.com/mathieumarthy/bonsize
https://github.com/mathieumarthy/bonsize
Last synced: 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/mathieumarthy/bonsize
- Owner: MathieuMarthy
- License: wtfpl
- Created: 2026-02-26T11:24:53.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2026-04-14T13:08:30.000Z (2 months ago)
- Last Synced: 2026-04-14T13:33:22.470Z (2 months ago)
- Language: Rust
- Size: 678 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# bonsize 🐢
A CLI tool to display directory tree sizes.
## Description
`bonsize` allows you to quickly analyze and display the size of directories and files in a tree structure, making it easy to identify which files and folders are taking up the most disk space.
## Usage
```bash
bonsize [OPTIONS] [PATH]
```
### Arguments
- `[PATH]` - The directory path to analyze (default: current directory `.`)
### Options
- `-F, --file` - Show files in the output
- `-D, --directory` - Show only directories
- `-d, --depth ` - Maximum depth to traverse
- `-s, --sorted []` - Sort output (possible values: `asc`, `desc`)
- `--csv []` - Export results to CSV format
- `-c, --cache` - Use caching for improved performance
- `-q, --quiet` - Suppress non-essential output
- `-h, --help` - Print help information
- `-V, --version` - Print version information
### Examples
```bash
$ bonsize /folder
📂 - folder 109.15MB
📂 - folder/videos 104.79MB
📂 - folder/videos/2026 87.19MB
📄 - folder/videos/2026/vacation_2026_02.mp4 87.19MB
📂 - folder/videos/2025 17.60MB
📄 - folder/videos/2025/Replay_2026-03-12_20-05-46.mp4 17.60MB
📂 - folder/turtle pictures 4.36MB
📄 - folder/turtle pictures/image_2.png 4.32MB
📄 - folder/turtle pictures/image_1.jpg 40.00KB
📄 - folder/letter.txt 4.00KB
```
```bash
# Show only directories, sorted by size
$ bonsize -D -s desc
# Limit depth and use cache
$ bonsize -d 3 -c
```
## Installation
### Windows
Download the Windows installer (`.exe`) from the [GitHub releases](https://github.com/MathieuMarthy/bonsize/releases).
### Debian/Ubuntu
Download the `.deb` package from the [GitHub releases](https://github.com/MathieuMarthy/bonsize/releases) and install it:
```bash
sudo dpkg -i bonsize_*.deb
```
### From source
If you have Rust installed, you can compile from source:
```bash
cargo install --path .
```
## License
This project is licensed under the WTFPL, see the [license file](./LICENSE) for more details.