Skip to main content

A pre commit hook used to maintain license and copyright information in source files.

Project description

nssacPreCommitHook

Install

Linux and MacOS X

  • System wide installation
sudo pip install nssacPreCommitHook
  • User local installation
pip install nssacPreCommitHook --user

Windows

 pip install nssacPreCommitHook
  • User local installation (not recommeded as the script path is not in the search PATH)
pip install nssacPreCommitHook --user

Configuration

The configuration uses a JSON schema to specify the license and the copyright statements to be used.

Two examples are provided:

Enable nssacPreCommitHook for a repository

Download Example and save it.

preCommitHook.py --init -r repository -c Path_to_Example

If you saved the example as repository/.nssac.json you may ommit -c Path_to_Example

Suported file formats:

The patterns section of the example currently supports the following formats

  • C/C++ ".cpp", ".hpp", ".c", ".h", "*.h.in"
  • Java "*.java"
  • XML ".xsd", ".xml", "*.rng"
  • Shell "*.sh"
  • CMake "*.cmake", "CMakeLists.txt"
  • Python "*.py"

It is not difficult to add more file types often is is just adding another pattern to the include section of an exiting pattern.

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

nssacPreCommitHook-1.0.4.tar.gz (11.8 kB view hashes)

Uploaded Source

Built Distribution

nssacPreCommitHook-1.0.4-py3-none-any.whl (15.0 kB view hashes)

Uploaded Python 3

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