Skip to main content

SCM mining utility classes

Project description

PyPi version Python compatibility Build Status Documentation Test coverage Codacy

Code Metrics

Mine your SCM for insight on your software. A work of love inspired by Adam Tornhill’s books.

Code metrics is a simple Python module that leverage pandas and your source control management (SCM) tool togenerate insight on your code base.

  • pandas: for data munching.

  • lizard: for code complexity calculation.

  • cloc.pl (script): for line counts from cloc

  • For now, only Subversion and git are supported.

Installation

To install codemetrics, simply use pip:

pip install codemetrics

Usage

This is a simple tool that makes it easy to retrieve information from your Source Control Management (SCM) repository and hopefully gain insight from it.

import codemetrics as cm
import cm.git

log_df = cm.git.get_git_log()
ages_df = cm.get_ages(log_df)

See module documentation for more advanced functions.

License

Licensed under the term of MIT License. See attached file LICENSE.txt.

Credits

History

0.8.1 (2019-02-26)

  • Added svn.get_diff_stats to retrieve line changes stats per diff.

0.8 (2019-02-13)

  • Integrated lizard to calculate average and function level cyclomatic complexity.

0.7 (2019-01-09)

  • Function oriented interface.

  • Visualization via Vega, Altair.

  • Documentation.

0.6

  • Alpha work.

0.5 (2018-05-12)

  • First release on PyPI.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

codemetrics-0.8.2.tar.gz (44.2 kB view details)

Uploaded Source

File details

Details for the file codemetrics-0.8.2.tar.gz.

File metadata

  • Download URL: codemetrics-0.8.2.tar.gz
  • Upload date:
  • Size: 44.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.31.1 CPython/3.7.0

File hashes

Hashes for codemetrics-0.8.2.tar.gz
Algorithm Hash digest
SHA256 21818e677aa3bd1d5bfcc17f5d7d4e69604d19a0671a51a501a017927b25c70e
MD5 db2a2cb3cfc11c48337404db01d4410c
BLAKE2b-256 e5871f01ca38271c82129849a006528d71eac72030970a4f0fc449693eab9387

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page