diff --git a/.travis.yml b/.travis.yml index 6f94072..f8fca72 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,6 +1,8 @@ language: python sudo: false cache: pip +git: + depth: 100000 addons: apt: packages: @@ -37,6 +39,7 @@ matrix: - python: pypy3 before_install: - pip install tox codecov 'sphinx>=1.5.1' + - ./doc/generate_authors.sh --check script: - tox - codecov diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index 9d5de8b..ad16384 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -12,6 +12,15 @@ The pull requests and issues will be prefilled with templates. Please fill in yo This project uses `semantic versioning `_ and tries to adhere to the proposed rules as well as possible. +Author-list +----------- + +This project keeps a list of authors. This can be auto-generated by calling `./doc/generate-authors.sh`. +When contributing the first time, please include a commit with the output of this script in place. +Otherwise the integration-check will fail. + +When you change your username or mail-address, please also update the `.mailmap` and the authors-list. + Style-Guide ----------- diff --git a/doc/generate_authors.sh b/doc/generate_authors.sh new file mode 100755 index 0000000..b93e920 --- /dev/null +++ b/doc/generate_authors.sh @@ -0,0 +1,14 @@ +#!/bin/sh + +GENLIST=$(git shortlog -s -n | cut -f2 | sort) +AUTHORSFILE="$(dirname $0)/../AUTHORS" +TEMPAUTHORSFILE="/tmp/python-escpos-authorsfile" + +if [ "$#" -eq 1 ] + then + echo "$GENLIST">$TEMPAUTHORSFILE + diff -q --from-file $AUTHORSFILE $TEMPAUTHORSFILE + else + echo "$GENLIST">$AUTHORSFILE +fi + diff --git a/generate_authors.sh b/generate_authors.sh deleted file mode 100755 index 6ab31c4..0000000 --- a/generate_authors.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh - -git shortlog -s -n | cut -f2 | sort