casoetan / listx

Directory Listing

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Listx

A directory listing service that lists a directory's contents and the size of it's contents. Result is ordered by size

It includes

  • a cli for running it via the command prompt
  • a flask app that exposes an api endpoint and
  • a react application

Setup

  1. Clone repository
  2. Setup a python virtualenv

CLI

  • Run the cli on a directory
python ./listx.py /User/<username>/Downloads

API

  • Install python dependences (this project uses Poetry for managing dependences)
poetry install 
  • Start application
flask run
  • Navigate to http://localhost:5000/api/listx?path=/Users/<username>/Downloads

React

  • Make sure the api is running see API Section

  • Ensure you have the latest LTS node is installed as well as yarn

  • Navigate to app and install node modules

yarn install
  • Start the application
yarn dev

Pending

  • Containerize application (using docker or kubernters :))
  • Install a production server for backend / frontend
  • Add more checks to catch errors
  • Paginate response
  • Add tests

About

Directory Listing


Languages

Language:Python 45.6%Language:TypeScript 37.1%Language:CSS 16.9%Language:JavaScript 0.4%