Skip to content

BalaBoi/dirinfo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Dirinfo

dirinfo is a simple command-line tool written in Rust that provides information about the number of files in a specified directory. If no directory path is provided, it defaults to analyzing the current directory.

Features

  • Accepts a directory path as input and returns the number of files within it.
  • Defaults to the current directory if no path is provided.
  • Efficiently handles directory traversal.

Installation

To install the tool, you need to have Rust installed on your system. Once Rust is installed, you can build the tool using cargo:

# Clone the repository
$ git clone https://github.com/BalaBoi/dirinfo

# Navigate into the project directory
$ cd dirinfo

# Install the tool
$ cargo install --path .

# Check the tool is installed
$ dirinfo --help

Usage

Run the dirinfo command with or without a directory path:

Examples

  1. Analyze the current directory:

    $ dirinfo
    Number of files: 42
  2. Analyze a specific directory:

    $ dirinfo /path/to/directory
    Number of files: 128

Future Enhancements

  • Calculate the total size of files in the directory.
  • Provide detailed statistics (e.g., file types, subdirectory counts).
  • Add recursive or non-recursive options.

Contributing

Contributions are welcome! Feel free to open an issue or submit a pull request.

License

This project is licensed under the MIT License. See the LICENSE file for details.


About

A command line tool to display general directory information

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages