Skip to content

Commit

Permalink
Documentation adjustments, move hooks to examples
Browse files Browse the repository at this point in the history
  • Loading branch information
psss committed Sep 4, 2015
1 parent 10c0294 commit b99e0a9
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 37 deletions.
77 changes: 40 additions & 37 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,20 @@ Gather status report data for given date range.

Description
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Comfortably gather status report data (e.g. list of committed
changes) for given week, month, quarter, year or selected date
range. By default all available stats for this week are reported.


Examples
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Generate all stats for current week::

Gather all stats for current week::

status-report

Generate stats for the last week::
Gather stats for the last week::

status-report last week

Expand All @@ -28,6 +30,7 @@ See status-report --help for complete list of available stats.

Installation
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Install directly from Fedora/Copr repository or use PIP::

# Basic dependencies for buiding/installing pip packages
Expand All @@ -48,12 +51,11 @@ To build and execute in a docker container, run::

make run_docker

See LINKS section below for more docker resources.


Configuration
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The config file ~/.status-report is used to store both general

The config file ``~/.status-report`` is used to store both general
settings and configuration of individual reports::

[general]
Expand Down Expand Up @@ -88,62 +90,63 @@ config file. Use environment variable ``STATUS_REPORT_CONFIG`` to
override the default config file location.


Git Commit Hooks
Contributing
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you're planning to make commits to this project, please enable
the following git hooks::

# UPDATE according to the correct absolute git path
PATH = ~/status-report/git-hooks
ln -s $(PATH)/pre-commit.py .git/hooks/pre-commit
ln -s $(PATH)/commit-msg.py .git/hooks/commit-msg
If you're planning to contribute to this project consider copying
the following hooks into your git config::

GIT=~/git/status-report # update to your actual path
cp $GIT/examples/pre-commit.py $GIT/.git/hooks/pre-commit

This comment has been minimized.

Copy link
@calmrat

calmrat Sep 4, 2015

I suggest linking because then if anyone makes commits to those files in the future it won't be necessary to re-copy; symbolic links will just point to the most recent version in the _githooks/ path.

This comment has been minimized.

Copy link
@psss

psss Sep 4, 2015

Author Owner

I see. That makes sense. On the other hand it does not look very nice from the security point of view... I like to know what's happening exactly in those hooks. And I believe contributors could have similar preference.

This comment has been minimized.

Copy link
@calmrat

calmrat Sep 5, 2015

"it does not look very nice from the security point of view." I clearly hadn't thought about that. Won't people see that _githooks get updated before the run a new commit which would execute the updated hooks? I mean, before using the hooks for the first time one will review them if they are concerned. They will see everything looks ok, enable. Then later someone commits to master a change to the hook. When pulling master in other repos it will be clear that the hooks are updated. The security conscious person will then review the code before making a future commit...

Not to say this justifies it, but I just checked, i'm not the only one using this technique.

http://codeinthehole.com/writing/tips-for-using-a-git-pre-commit-hook/
http://alert-manager.readthedocs.org/en/latest/README/

This comment has been minimized.

Copy link
@psss

psss Sep 8, 2015

Author Owner

OK, you've convinced me. It's always option to copy or if
concerned one can always double check git log or git fetch
summary to see whether hooks have been updated. 19a99f8

cp $GIT/examples/commit-msg.py $GIT/.git/hooks/commit-msg

Tests
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To run tests using pytest::

# sudo required if not in a virtualenv
pip install pytest coveralls
coverage run --source=status_report -m py.test source/tests
coverage report

Install pytest and coverage using yum::

Links
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Project page:
http://psss.fedorapeople.org/status-report/
yum install pytest python-coverage

Release notes:
http://psss.fedorapeople.org/status-report/notes.html
or pip::

Examples:
http://psss.fedorapeople.org/status-report/examples/
# sudo required if not in a virtualenv
pip install pytest coveralls

Download:
http://psss.fedorapeople.org/status-report/download/

Copr repo:
http://copr.fedoraproject.org/coprs/psss/status-report/
Links
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Git repo:
Git:
https://github.com/psss/status-report

PIP repo:
https://pypi.python.org/pypi/status_report/
Docs:
http://status-report.readthedocs.org

Issues:
https://github.com/psss/status-report/issues

Docker Guides:
https://fedoraproject.org/wiki/Docker
Releases:
https://github.com/psss/status-report/releases

Copr:
http://copr.fedoraproject.org/coprs/psss/status-report

PIP:
https://pypi.python.org/pypi/status_report


Authors
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Petr Šplíchal, Karel Šrot, Lukáš Zachar, Matěj Cepl, Ondřej Pták
and Chris Ward.

Petr Šplíchal, Karel Šrot, Lukáš Zachar,
Matěj Cepl, Ondřej Pták and Chris Ward.


Copyright
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Copyright (c) 2015 Red Hat, Inc. All rights reserved.

This program is free software; you can redistribute it and/or
Expand All @@ -170,5 +173,5 @@ Status
.. image:: https://img.shields.io/pypi/l/status-report.svg
:target: https://pypi.python.org/pypi/status_report/

.. image:: https://landscape.io/github/psss/status-report/master/landscape.svg
:target: https://landscape.io/github/psss/status-report/master
.. image:: https://readthedocs.org/projects/status-report/badge/
:target: https://readthedocs.org/projects/status-report/
10 changes: 10 additions & 0 deletions docs/docker.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@


======================
Docker Docs
======================

A couple of useful resources:

* https://fedoraproject.org/wiki/Docker
* https://fedoraproject.org/wiki/Getting_started_with_docker
File renamed without changes.
File renamed without changes.

0 comments on commit b99e0a9

Please sign in to comment.