GithubHelp home page GithubHelp logo

kraymer / treeage Goto Github PK

View Code? Open in Web Editor NEW
38.0 3.0 2.0 125 KB

Expose aging code by listing contents of repository in a tree-like format with eye-catching age metric.

License: MIT License

Python 100.00%
ls code-quality git-blame

treeage's Introduction

image

image

image

image

image

treeage

/'trēˌāj/

1. n. a process in which things are ranked in terms of importance or priority.
2. n. software that lists contents of directories in a tree-like format with age metric indicated for each file

treeage is typically used to shed some light on antiquated parts1 of a codebase and identify candidates for a refactoring.

Install

treeage is written for Python 3.6+, install with pip via pip3 install treeage command.

Usage

Usage: treeage.py [OPTIONS] DIRECTORY  

  Lists contents of directories in a tree-like format with age metric
  indicated for each file.  

Options:
  --maxdepth LEVELS    Descend at most LEVELS (a non-negative integer) levels
                       of directories below the seed DIRECTORY
  -i, --include GLOB   List only files whose base name matches GLOB (using
                       wildcard matching)
  -e, --exclude GLOB   Exclude files whose base name matches GLOB (using
                       wildcard matching)
  --before DATE        List only files whose age is older than DATE
  --after DATE         List only files whose age is lower than DATE
  -v, --verbosity LVL  Either CRITICAL, ERROR, WARNING, INFO or DEBUG
  --version            Show the version and exit.
  -h, --help           Show this message and exit.  

  Examples:
  treeage --maxdepth 2 --before "01 jan 2018"../qifqif
  treeage --include "*.py" --after "3 month ago" .

Screenshot

image


Footnotes


  1. file age is computed by averaging last modification date of its lines

treeage's People

Contributors

kraymer avatar qianyan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

forcelliami

treeage's Issues

Add flag(s) to filter by date

Add flags to list only files anterior/posterior to a given date.
The date should be parsed using dateparser lib.

Examples of possible uses :

treeage --include *.py -- after "3 months ago" . 
treeage --include *.py -- before "29/02/2016" . 

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.