- 📚 Table of Contents
- 📍Overview
- ⚙️ Project Structure
- 🧩 Modules
- 🏎💨 Getting Started
- 🤝 Contributing
- 🪪 License
Lichess-readme is a GitHub project designed to help authors of GitHub repositories easily create lichess elo rating badges on their github readme page.
repo
├── app.py
├── LICENSE
├── lichess.yml
├── __pycache__
│ ├── app.cpython-311.pyc
│ └── app.cpython-39.pyc
├── README.md
├── requirements.txt
├── templates
│ └── card.html.j2
└── vercel.json
2 directories, 9 files
Root
File | Summary | Module |
---|---|---|
app.py | This code creates a Flask application that uses the Lichess API to generate an SVG card with the user 's rating for a given time control . The time control is set in an environment variable and the user 's rating is retrieved from the Lichess | app.py |
Templates
File | Summary | Module |
---|---|---|
card.html.j2 | This code creates an SVG graphic with two rectangles , one in # 555 and one in # 007ec6 , and two text elements displaying the values of the variables " time_control " and " elo " . The graphic is 139x20 | templates/card.html.j2 |
Before you begin, ensure that you have the following prerequisites installed:
Register a Vercel account
- Fork the lichess-readme repository:
- Go to vercel, create a project using the forked github repo
- Provide environment variables including username and time_control, time_control options are bullet, blitz and rapid.
- Deploy and enjoy
<img src="link-to-your-vercel-app/?">
Contributions are always welcome! Please follow these steps:
- Fork the project repository. This creates a copy of the project on your account that you can modify without affecting the original project.
- Clone the forked repository to your local machine using a Git client like Git or GitHub Desktop.
- Create a new branch with a descriptive name (e.g.,
new-feature-branch
orbugfix-issue-123
).
git checkout -b new-feature-branch
- Make changes to the project's codebase.
- Commit your changes to your local branch with a clear commit message that explains the changes you've made.
git commit -m 'Implemented new feature.'
- Push your changes to your forked repository on GitHub using the following command
git push origin new-feature-branch
- Create a pull request to the original repository. Open a new pull request to the original project repository. In the pull request, describe the changes you've made and why they're necessary. The project maintainers will review your changes and provide feedback or merge them into the main branch.
This project is licensed under the MIT
License. See the LICENSE file for additional info.