semi-automated generating of PKUP report
PKUP stands for Podwyższone Koszty Uzyskania Przychodu in Polish language. Every month every employee of my current company needs to generate PKUP report. It's legal issue, which allows to pay lower income taxes due to creative work. Preparing such report is boring & repeatable work, which can be automated. That's why this project was created. Read more in the article on the blog.
- unix shell
brew install python3
sudo apt-get install python python-pip(on other Linux distros simply use another package manager)
- MS Windows: this solution wasn't tested on MS Windows, but it should work with Python and Cygwin. Here's a good resource regarding this topic: https://www.davidbaumgold.com/tutorials/set-up-python-windows/. Free VMs with Windows for non-Windows users, who want to perform tests, can be downloaded here: https://developer.microsoft.com/en-us/microsoft-edge/tools/vms/.
Assuming you have
git installed, run the following commands:
git clone https://github.com/pwittchen/pkup.git cd pkup ./install.sh
~/.pkup.conf file to personalize your future reports. Remember that pkup script also takes into consideration your user name in
.gitconfig file and it should be in format:
If you have problem with installing dependencies via installation script, try to install them manually via
pip in the following way:
pip install -r requirements.txt
pip install python-docx
If it doesn't work, try to call
pip3 instead of
Parameters of the
pkup script are as follows:
-h shows help -m "<message for the report>" generates a report with a provided message -g generates a report with an empty message
exemplary usage of the script is as follows:
pkup -m "<message with description of your work>"
This command will generate
*.diff files with changes made by user in defined repositories and appropriate report in
*.docx file. Location of the reports and
*.diff files is defined in
.pkup.conf file and can be adjusted to user's needs.
You can also use script with
-g parameter, which will generate report with an empty message and fill in the
*.docx document later:
To show help, type:
To update scripts, type:
cd pkup git pull ./install.sh
To uninstall scripts, type:
To run python tests, type:
Please note: Tests are quite poor right now and require improvements.