wffrg/README.md
2024-09-25 23:33:34 -07:00

41 lines
1.3 KiB
Markdown

# Weekly Fantasy Football Report Generator
## Install
Required: Python 3.8 or greater
- Clone this repository: `git clone https://forgejo.digitalhippo.tech/wffrg`
- Create a virtual environment
- `cd wffrg`
- `python -m venv .venv` or `python3 -m venv .venv`
- Activvate virtual environment
- MacOS/Linux: `. .venv/bin/active`
- Windows
- Command Prompt: `.venv\Scripts\activate.bat`
- Powershell: `.venv\Scripts\activate.ps1`
- Install requirements
- `pip install -r requirements.txt`
## Configure
Copy `.env-template` as `.env` file and enter the following items:
- `ESPN_S2`: S2 key from ESPN
- `SWID`: SWID key from ESPN
- `LEAGUE_ID`: League ID for your Fantasy League from ESPN
- `FETCH_LEAGE`: Generally, leave as `true` unless you know what you're doing
For more information on how to retrieve these details, head on over to GitHub and [review this discussion](https://github.com/cwendt94/espn-api/discussions/150).
## Execute
The following arguments are available and optional
- `-wo` or `--weekly-override`: Provide a week (as an `int`) to override data generation, default is current week.
For example, if the current week is week 10 but I want data from week 8:
- `python app.py -wo 8` or `python app.py --weekly-override 8`
Otherwise, for current week:
- `python app.py`