A simple command line tool to count files by extension.
Copy the executable file to your $PATH
and run:
bash
count-files /path/to/target_dir
Output sample:
bash
Done in 0 seconds.
+-----------+-------+
| File type | Count |
+===================+
| jpg | 29 |
|-----------+-------|
| jpeg | 7 |
|-----------+-------|
| txt | 6 |
|-----------+-------|
| gz | 4 |
|-----------+-------|
| png | 2 |
+-----------+-------+
count-files is written in Rust, you need to install Rust to compile it.
To build:
bash
git clone https://github.com/yinguobing/count-files.git
cd count-files
cargo build --release