es-analysis / plato

JavaScript source code visualization, static analysis, and complexity tool
MIT License
4.56k stars 322 forks source link

Howto clean reports #71

Open ghost opened 10 years ago

ghost commented 10 years ago

After generating too much report on one day. I'm asking myself if there's an option to clean reports?

__history = [
    {"date": "Fri, 14 Feb 2014 09:32:18 GMT", "total": {"sloc": 5016, "maintainability": 507.1061613675681}, "average": {"sloc": 1003, "maintainability": "101.42"}},
    {"date": "Fri, 14 Feb 2014 09:36:31 GMT", "total": {"sloc": 5017, "maintainability": 507.1086114591668}, "average": {"sloc": 1003, "maintainability": "101.42"}},
    {"date": "Fri, 14 Feb 2014 09:40:52 GMT", "total": {"sloc": 5017, "maintainability": 507.0997809962952}, "average": {"sloc": 1003, "maintainability": "101.42"}},
    {"date": "Fri, 14 Feb 2014 09:48:49 GMT", "total": {"sloc": 5017, "maintainability": 507.0997809962952}, "average": {"sloc": 1003, "maintainability": "101.42"}},
    {"date": "Fri, 21 Feb 2014 09:53:39 GMT", "total": {"sloc": 5017, "maintainability": 507.0997809962952}, "average": {"sloc": 1003, "maintainability": "101.42"}}
]

It would be reduce to one statistic per day, as:

__history = [
    {"date": "Fri, 14 Feb 2014 09:32:18 GMT", "total": {"sloc": 5016, "maintainability": 507.1061613675681}, "average": {"sloc": 1003, "maintainability": "101.42"}},
    {"date": "Fri, 21 Feb 2014 09:53:39 GMT", "total": {"sloc": 5017, "maintainability": 507.0997809962952}, "average": {"sloc": 1003, "maintainability": "101.42"}}
]

Have you a hint to do it automatically? Or must we edit files manually.

Great code, plato is awesome, thanks a lot!

robwalch commented 9 years ago

Being able to adjust the date range of the summary charts would allow us to view more changes over time, without being concerned about the number of or repetitive data points.

The reports loose a lot of value when I can only see the change in SLOC over the course of a day because the last 10 builds push old yet relevant history out of view.

ghost commented 9 years ago

Nice comment, I fully agree.