Skip to content

command-line tool that analyzes and reports on the file system structure and usage on a Linux system.

License

Notifications You must be signed in to change notification settings

lkabuci/File-System-Analyzer

Repository files navigation

File-System-Analyzer

command-line tool that analyzes and reports on the file system structure and usage on a Linux system.

Installation

Key FeaturesHow To UseDownloadCreditsRelatedLicense

file.analyzer.demo.mov

Key Features

  • List all files inside a given directory
  • Classify files into categories (e.g. images, documents, code, etc.)
  • Calculate and display the total size for each file type category.
  • Generate a report of files with unusual permission settings (e.g., world-writable files).
  • Identify and list files above a certain size threshold.
  • Delete reported files if the user chooses to do so.
  • Log the output of the program to a file.
  • Ability to choose the size unit (e.g., KB, MB, GB, etc.)
  • The CLI configuration in one file.
  • Run the program in a Docker container.
  • Integrated with GitHub Actions for CI/CD.

Installation

To clone and run this application, you'll need the following installed on your computer.

prerequisites

# Clone this repository
$ git clone https://github.com/kaboussi/File-System-Analyzer

# Go into the repository
$ cd File-System-Analyzer

# Create and setup virtual environment
$ make venv

# Run the app
$ ./.env/bin/python3 main.py [PATH] [OPTIONS]

Usage

  • To get help Help flag
Get reports of files inside a directory

List files

  • Delete reported files
Delete reported files

Delete files

  • Log the output of the program to a file
 python3 main.py . --size '10 MiB' -l file.log
  • Run unittests inside a Docker container
make test
Run the program in a Docker container

Docker

  • Or just simply use the configuration file
python3 main.py . --config config.conf

Credits

This software uses the following open source packages:

License

MIT


GitHub @kaboussi  ·  Twitter @kaboussi_

About

command-line tool that analyzes and reports on the file system structure and usage on a Linux system.

Resources

License

Stars

Watchers

Forks

Packages

No packages published