Metadata-Version: 2.0
Name: flowtool-githooks-demo
Version: 0.7.23
Summary: Trivial demo tasks for git users.
Home-page: https://github.com/isnok/py-flowlib
Author: Konstantin Martini
Author-email: k@tuxcode.org
License: UNKNOWN
Keywords: git,flow,shell,local,example,demo,commandline
Platform: Debian/GNU Linux
Classifier: Development Status :: 3 - Alpha
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
Classifier: Topic :: System :: Software Distribution
Classifier: Topic :: System :: Systems Administration
Classifier: Topic :: Utilities
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: System Administrators
Classifier: Operating System :: POSIX
Classifier: Operating System :: Unix
Classifier: Environment :: Console
Requires-Dist: flowtool-base (>=0.7.56)
Requires-Dist: flowtool-git (>=0.7.23)
Requires-Dist: flowtool-githooks (>=0.7.43)
Requires-Dist: pylint (>=1.5.5)
Requires-Dist: yamllint (>=1.2.1)

[![PyPI Python Versions](https://img.shields.io/pypi/pyversions/flowtool-githooks-demo.svg)](https://pypi.python.org/pypi/flowtool-githooks-demo)
[![PyPI Latest Version](https://img.shields.io/pypi/v/flowtool-githooks-demo.svg)](https://pypi.python.org/pypi/flowtool-githooks-demo)
[![PyPI Distribution Format](https://img.shields.io/pypi/format/flowtool-githooks-demo.svg)](https://pypi.python.org/pypi/flowtool-githooks-demo)

# flowtool-githooks-demo

This package contains some example git hooks.

The hooks are made runnable via `console_scripts` entry points.
The hooks are also recognized by the `flowtool-githooks` management via entry points.
That just means for a user of this tool, that the hooks will show up in the
`ft githooks-scripts` menu automatically, and can also be run via their name from
the command line.

## Setting things up

```shell
$ pip install flowtool-githooks-demo
```
Then you can install the hook runner and set up the demo hook by using these commands:

```shell
$ flowtool githooks-install
$ flowtool githooks-scripts --hook pre-commit --add _flowtool_githooks.demo
$ flowtool githooks-scripts --hook commit-msg --add _flowtool_githooks.demo
$ flowtool githooks-scripts --hook pre-push --add _flowtool_githooks.demo
```

To configure the hooks interactively:

```shell
$ flowtool githooks-scripts --help
$ flowtool githooks-scripts
```

To unistall the hooks use:

```shell
$ flowtool githooks-scripts --hook pre-commit --remove _flowtool_githooks.demo
$ flowtool githooks-wipe
```

## _flowtool_githooks.demo

A git hook to showcase the possibilities of git hooks.
It prints its (command line) arguments and various information
that may or may not be interesting to someone developing a hook
for his own purposes.

As one main feature, it reads it's standard input non-blocking
and outputs it if there is anything, since only some hooks get
additional information passed in via stdin.

## _flowtool_githooks.demo_fail

A git hook that will always fail.

Good to test what a non-zero exit status will do for certain hooks.


## _flowtool_githooks.shellcheck

A step towards a collection of git hooks, that wrap code checkers.
This one wraps [shellcheck](https://github.com/koalaman/shellcheck),
a shell script syntax, style and security checker.

## _flowtool_githooks.yamllint

One more step towards a collection of useful git hooks.
This one wraps [yamllint](https://github.com/adrienverge/yamllint), a yaml linter.

## _flowtool_githooks.markdownlint

One more step towards a collection of useful git hooks.
This one wraps [pymarkdownlint](https://github.com/jorisroovers/pymarkdownlint), a markdown linter.


