From b81a312fe1b7cb3e9c6ad65564a30ba0e3101e31 Mon Sep 17 00:00:00 2001 From: tomasvana10 Date: Mon, 29 Apr 2024 17:32:35 +1000 Subject: [PATCH] chore: Update README.md and add requirements.txt --- README.md | 27 +++++++++++++-------------- requirements.txt | 3 +++ 2 files changed, 16 insertions(+), 14 deletions(-) create mode 100644 requirements.txt diff --git a/README.md b/README.md index e83fc38..127ff97 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # commits2pdf -Visualise a GitHub repo's commit history in PDF form via the command-line +Visualise a GitHub repository's commit history in PDF form via the command-line

## Dependencies `pycairo`
@@ -14,16 +14,20 @@ Make a virtual environment (recommended) pip install virtualenv OR pip3 install virtualenv python -m venv venv OR python3 -m venv venv ON MACOS/UNIX: source venv/bin/activate -ON WINDOW: venv\scripts\activate +ON WINDOWS: venv\scripts\activate ``` -Install the package: +Install the package in your system directory/virtual environment: ``` -pip install commits2pdf OR pip3 install commits2pdf +pip install -U commits2pdf OR pip3 install -U commits2pdf ``` -**Scroll down for usage information**. +OR, install the package in your home directory (good if you aren't using a virtual environment): +``` +pip install --user -U commits2pdf +``` + -If you encounter errors with building `pycairo`, click [here](https://stackoverflow.com/a/76175684/23245953) +**If you encounter errors with building `pycairo`, click [here](https://stackoverflow.com/a/76175684/23245953)**

## Command-line parameters ``` @@ -67,21 +71,18 @@ If you encounter errors with building `pycairo`, click [here](https://stackoverf
## Usage -**See usage info in the command-line**: -Run `c2p -h` - -
**Simple usage**: +
**Simple usage - what you will be using the most**: ``` c2p -O tomasvana10 ``` -_Explanation_: Run the commmits2pdf cli tool in the current directory (assuming it is a repository). The owner name must be provided in all cases. +_Explanation_: Run the CLI tool in the current directory (assuming it is a Git repository). The owner name must be provided in all cases.
**Advanced usage example #1**: ``` c2p -O tomasvana10 -rp ../seriescalculator_sdd -a person@email.com,other_person@gmail.com -s 2024-11-30 -e 2024-12-30 -b other_branch -d ``` _Explanation_: -1. Override the default repository path with the ``seriescalculator_sdd`` folder in the parent directory +1. Override the default repository path (``-rp ..\seriescalculator_sdd``) with a folder in the parent directory. 2. Look for specific commit emails (separated by commas) 3. Search for commits from the -s date until the -e date 4. Search for commits only made to `other_branch` @@ -160,5 +161,3 @@ _Explanation_: Create the repo you have specified and make the PDF. This repo is **gen2 commit page in dark mode**
gen2 pdf commit page dark - - diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..5e67339 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,3 @@ +fpdf==1.7.2 +GitPython==3.1.43 +pycairo==1.26.0 \ No newline at end of file