************************************* Contribution to the documentation ************************************* .. contents:: Documentation: :local: About documentation ------------------------ * yfinance documentation is written in reStructuredText (rst) and built using Sphinx. * The documentation file is in `doc/source/..`. * Most of the notes under API References read from class and methods docstrings. These documentations, found in `doc/source/reference/api` is autogenerated by Sphinx and not included in git. Building documentation locally ------------------------------- To build the documentation locally, follow these steps: 1. **Install Required Dependencies**: * Make sure `Sphinx` and any other dependencies are installed. If a `requirements.txt` file is available, you can install dependencies by running: .. code-block:: console pip install -r requirements.txt 2. **Build with Sphinx**: * After dependencies are installed, use the sphinx-build command to generate HTML documentation. * Go to `doc/` directory Run: .. code-block:: console make clean && make html 3. **View Documentation Locally**: * Open `doc/build/html/index.html` in the browser to view the generated documentation. Building documentation on main ------------------------------- The documentation updates are built on merge to `main` branch. This is done via GitHub Actions workflow based on `/yfinance/.github/workflows/deploy_doc.yml`. 1. Reivew the changes locally and push to `dev`. 2. When `dev` gets merged to `main`, GitHub Actions workflow is automated to build documentation.