rift-tui 1.0.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- rift_tui-1.0.1/.gitignore +31 -0
- rift_tui-1.0.1/PKG-INFO +128 -0
- rift_tui-1.0.1/README.md +100 -0
- rift_tui-1.0.1/pyproject.toml +45 -0
- rift_tui-1.0.1/src/rift_tui/__init__.py +7 -0
- rift_tui-1.0.1/src/rift_tui/__main__.py +6 -0
- rift_tui-1.0.1/src/rift_tui/main.py +2172 -0
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
|
|
2
|
+
# dependencies
|
|
3
|
+
/node_modules
|
|
4
|
+
/.pnp
|
|
5
|
+
.pnp.*
|
|
6
|
+
.yarn/*
|
|
7
|
+
!.yarn/patches
|
|
8
|
+
!.yarn/plugins
|
|
9
|
+
!.yarn/releases
|
|
10
|
+
!.yarn/versions
|
|
11
|
+
|
|
12
|
+
# testing
|
|
13
|
+
/coverage
|
|
14
|
+
|
|
15
|
+
accounts.json
|
|
16
|
+
app_settings.json
|
|
17
|
+
|
|
18
|
+
venv/
|
|
19
|
+
|
|
20
|
+
# production
|
|
21
|
+
/build
|
|
22
|
+
|
|
23
|
+
# misc
|
|
24
|
+
.DS_Store
|
|
25
|
+
*.pem
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
# env files (can opt-in for committing if needed)
|
|
29
|
+
.env*
|
|
30
|
+
|
|
31
|
+
|
rift_tui-1.0.1/PKG-INFO
ADDED
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: rift-tui
|
|
3
|
+
Version: 1.0.1
|
|
4
|
+
Summary: A terminal-based League of Legends stats tracker built with Textual
|
|
5
|
+
Project-URL: Homepage, https://github.com/rileriaaa/rift-tui
|
|
6
|
+
Project-URL: Repository, https://github.com/rileriaaa/rift-tui
|
|
7
|
+
Project-URL: Issues, https://github.com/rileriaaa/rift-tui/issues
|
|
8
|
+
Author: rileria
|
|
9
|
+
License: MIT
|
|
10
|
+
Keywords: league-of-legends,riot-api,terminal,textual,tui
|
|
11
|
+
Classifier: Environment :: Console
|
|
12
|
+
Classifier: Intended Audience :: End Users/Desktop
|
|
13
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
14
|
+
Classifier: Operating System :: OS Independent
|
|
15
|
+
Classifier: Programming Language :: Python :: 3
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
19
|
+
Classifier: Topic :: Games/Entertainment
|
|
20
|
+
Classifier: Topic :: Terminals
|
|
21
|
+
Requires-Python: >=3.10
|
|
22
|
+
Requires-Dist: httpx>=0.27.0
|
|
23
|
+
Requires-Dist: platformdirs>=4.0.0
|
|
24
|
+
Requires-Dist: pyperclip>=1.8.0
|
|
25
|
+
Requires-Dist: python-dotenv>=1.0.0
|
|
26
|
+
Requires-Dist: textual>=0.50.0
|
|
27
|
+
Description-Content-Type: text/markdown
|
|
28
|
+
|
|
29
|
+
# rift-tui
|
|
30
|
+
|
|
31
|
+
A terminal-based League of Legends stats tracker built with Python and [Textual](https://github.com/Textualize/textual). Three-panel dashboard — rank, recent form, champion mastery, match history, top champions, and full per-match breakdowns (runes, spells, items, objectives, gold/XP diff over time) — all live from Riot's API.
|
|
32
|
+
|
|
33
|
+
## Features
|
|
34
|
+
|
|
35
|
+
- **Live profile tracking** — rank, LP, recent-form sparkline, champion mastery, last 10 matches, top champions
|
|
36
|
+
- **Match detail** — full scoreboard both teams, bans, objectives, runes, summoner spells, multikill badges, kill participation / damage-per-minute, item builds, and a gold/XP/damage timeline chart per match
|
|
37
|
+
- **Search any player** — region-aware, arrow-key platform picker (no need to know Riot's routing codes)
|
|
38
|
+
- **Bookmarks** — save favorite Riot IDs, jump to them with one keypress
|
|
39
|
+
- **Multi-account** — track a main + smurfs, switch between them
|
|
40
|
+
- **Compare mode** — side-by-side stat comparison against a searched player
|
|
41
|
+
- **Queue filter** — Solo / Flex / ARAM
|
|
42
|
+
- **Champion filter** — filter your match list down to one champion
|
|
43
|
+
- **In-app settings** — manage tracked accounts, bookmarks, refresh interval, and your Riot API key, all without touching a config file
|
|
44
|
+
- **Copy Riot ID to clipboard** — one key, no manual selecting
|
|
45
|
+
- **Scrollable, resizable panels** — Tab to focus a panel, arrow keys or mouse wheel to scroll
|
|
46
|
+
- **Built-in help overlay** — full keybind reference, one key away
|
|
47
|
+
|
|
48
|
+
## Requirements
|
|
49
|
+
|
|
50
|
+
- Python 3.10+
|
|
51
|
+
- A free Riot Developer API key ([get one here](https://developer.riotgames.com/)) — personal dev keys expire every 24h, this is normal Riot behavior, not a bug
|
|
52
|
+
- A terminal that properly supports ANSI/VT input. **On Windows, use [Windows Terminal](https://apps.microsoft.com/detail/9n0dx20hk701)** — legacy `cmd.exe` and the old PowerShell console host don't handle keyboard input correctly for full-screen terminal apps like this one. If you're on Windows 10 LTSC (no Microsoft Store), grab the portable build from [Terminal's GitHub releases](https://github.com/microsoft/terminal/releases), or use [WezTerm](https://wezfurlong.org/wezterm/) / [Alacritty](https://alacritty.org/) instead.
|
|
53
|
+
|
|
54
|
+
## Installation
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
pipx install rift-tui
|
|
58
|
+
rift-tui
|
|
59
|
+
```
|
|
60
|
+
[pipx](https://pipx.pypa.io/) installs it in its own isolated environment and puts the `rift-tui` command on your PATH. If you don't have pipx yet:
|
|
61
|
+
```bash
|
|
62
|
+
python -m pip install --user pipx
|
|
63
|
+
pipx ensurepath
|
|
64
|
+
```
|
|
65
|
+
(restart your terminal after that last command)
|
|
66
|
+
|
|
67
|
+
**From source (for development):**
|
|
68
|
+
```bash
|
|
69
|
+
git clone https://github.com/rileriaaa/rift-tui.git
|
|
70
|
+
cd rift-tui
|
|
71
|
+
pip install -e .
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
## First run
|
|
75
|
+
|
|
76
|
+
On first launch, rift-tui walks you through setup — no config files to hand-edit:
|
|
77
|
+
|
|
78
|
+
1. **Paste your Riot API key** when prompted (or press `Esc` to skip and add it later with `K`)
|
|
79
|
+
2. **Enter your Riot ID** (e.g. `YourName#TAG`) and pick your region with `←`/`→` (or skip and add it later with `A`)
|
|
80
|
+
|
|
81
|
+
That's it — your account and key are saved locally and reused on every future launch.
|
|
82
|
+
|
|
83
|
+
## Keybinds
|
|
84
|
+
|
|
85
|
+
| Key | Action |
|
|
86
|
+
|---|---|
|
|
87
|
+
| `/` | Search for a player |
|
|
88
|
+
| `1`–`9`, `0` | Open match 1–10 detail |
|
|
89
|
+
| `Esc` | Back / close whatever's open |
|
|
90
|
+
| `Tab` | Switch panel focus |
|
|
91
|
+
| `↑` `↓` | Scroll the focused panel (or browse recent searches / recent bookmarks while typing) |
|
|
92
|
+
| `←` `→` | Change region while searching or adding a player |
|
|
93
|
+
| `R` | Refresh now |
|
|
94
|
+
| `I` | Cycle auto-refresh interval |
|
|
95
|
+
| `T` | Cycle queue type (Solo / Flex / ARAM) |
|
|
96
|
+
| `F` | Filter match list by champion |
|
|
97
|
+
| `A` | Manage tracked accounts (add/remove) |
|
|
98
|
+
| `N` | Switch to next tracked account |
|
|
99
|
+
| `B` | Bookmarks — open list / add current or new player |
|
|
100
|
+
| `C` | Toggle compare mode (while viewing a searched player) |
|
|
101
|
+
| `Y` | Copy the currently viewed Riot ID to clipboard |
|
|
102
|
+
| `K` | Add or update your Riot API key — no `.env` editing needed |
|
|
103
|
+
| `?` | Show the help overlay |
|
|
104
|
+
| `Q` | Quit |
|
|
105
|
+
|
|
106
|
+
## Where your data lives
|
|
107
|
+
|
|
108
|
+
Nothing is stored next to the installed package. rift-tui uses your OS's proper per-user data folder (via `platformdirs`) — e.g. `%LOCALAPPDATA%\rift-tui` on Windows, `~/.local/share/rift-tui` on Linux:
|
|
109
|
+
|
|
110
|
+
- `accounts.json` — your tracked accounts
|
|
111
|
+
- `bookmarks.json` — saved players
|
|
112
|
+
- `app_settings.json` — refresh interval and your API key
|
|
113
|
+
|
|
114
|
+
## Troubleshooting
|
|
115
|
+
|
|
116
|
+
- **"Rate limited by Riot API (429)"** — personal dev keys are capped at 20 requests/second and 100 requests/2 minutes. Wait a moment and retry.
|
|
117
|
+
- **"Invalid or expired Riot API key"** — dev keys expire every 24 hours. Press `K` in-app to paste a fresh one, no restart needed.
|
|
118
|
+
- **"Player not found"** — double check the exact Riot ID (`name#tag`), and try a different region with `←`/`→` — Riot IDs are region-locked to wherever the account actually plays.
|
|
119
|
+
- **Keys not responding on Windows** — see the terminal note under Requirements above.
|
|
120
|
+
- **Screen looks broken on a small window** — `Tab` to focus a panel, then scroll it with arrow keys or your mouse wheel.
|
|
121
|
+
|
|
122
|
+
## A note on API keys
|
|
123
|
+
|
|
124
|
+
This project uses a **bring-your-own-key** model: each user gets their own free personal Riot API key rather than the app shipping with one baked in. This isn't a limitation — Riot's developer terms explicitly prohibit embedding any API key (personal or production) in software you distribute to others, and personal keys are specifically meant for exactly this kind of individual-use tool.
|
|
125
|
+
|
|
126
|
+
## License
|
|
127
|
+
|
|
128
|
+
MIT
|
rift_tui-1.0.1/README.md
ADDED
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
# rift-tui
|
|
2
|
+
|
|
3
|
+
A terminal-based League of Legends stats tracker built with Python and [Textual](https://github.com/Textualize/textual). Three-panel dashboard — rank, recent form, champion mastery, match history, top champions, and full per-match breakdowns (runes, spells, items, objectives, gold/XP diff over time) — all live from Riot's API.
|
|
4
|
+
|
|
5
|
+
## Features
|
|
6
|
+
|
|
7
|
+
- **Live profile tracking** — rank, LP, recent-form sparkline, champion mastery, last 10 matches, top champions
|
|
8
|
+
- **Match detail** — full scoreboard both teams, bans, objectives, runes, summoner spells, multikill badges, kill participation / damage-per-minute, item builds, and a gold/XP/damage timeline chart per match
|
|
9
|
+
- **Search any player** — region-aware, arrow-key platform picker (no need to know Riot's routing codes)
|
|
10
|
+
- **Bookmarks** — save favorite Riot IDs, jump to them with one keypress
|
|
11
|
+
- **Multi-account** — track a main + smurfs, switch between them
|
|
12
|
+
- **Compare mode** — side-by-side stat comparison against a searched player
|
|
13
|
+
- **Queue filter** — Solo / Flex / ARAM
|
|
14
|
+
- **Champion filter** — filter your match list down to one champion
|
|
15
|
+
- **In-app settings** — manage tracked accounts, bookmarks, refresh interval, and your Riot API key, all without touching a config file
|
|
16
|
+
- **Copy Riot ID to clipboard** — one key, no manual selecting
|
|
17
|
+
- **Scrollable, resizable panels** — Tab to focus a panel, arrow keys or mouse wheel to scroll
|
|
18
|
+
- **Built-in help overlay** — full keybind reference, one key away
|
|
19
|
+
|
|
20
|
+
## Requirements
|
|
21
|
+
|
|
22
|
+
- Python 3.10+
|
|
23
|
+
- A free Riot Developer API key ([get one here](https://developer.riotgames.com/)) — personal dev keys expire every 24h, this is normal Riot behavior, not a bug
|
|
24
|
+
- A terminal that properly supports ANSI/VT input. **On Windows, use [Windows Terminal](https://apps.microsoft.com/detail/9n0dx20hk701)** — legacy `cmd.exe` and the old PowerShell console host don't handle keyboard input correctly for full-screen terminal apps like this one. If you're on Windows 10 LTSC (no Microsoft Store), grab the portable build from [Terminal's GitHub releases](https://github.com/microsoft/terminal/releases), or use [WezTerm](https://wezfurlong.org/wezterm/) / [Alacritty](https://alacritty.org/) instead.
|
|
25
|
+
|
|
26
|
+
## Installation
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
pipx install rift-tui
|
|
30
|
+
rift-tui
|
|
31
|
+
```
|
|
32
|
+
[pipx](https://pipx.pypa.io/) installs it in its own isolated environment and puts the `rift-tui` command on your PATH. If you don't have pipx yet:
|
|
33
|
+
```bash
|
|
34
|
+
python -m pip install --user pipx
|
|
35
|
+
pipx ensurepath
|
|
36
|
+
```
|
|
37
|
+
(restart your terminal after that last command)
|
|
38
|
+
|
|
39
|
+
**From source (for development):**
|
|
40
|
+
```bash
|
|
41
|
+
git clone https://github.com/rileriaaa/rift-tui.git
|
|
42
|
+
cd rift-tui
|
|
43
|
+
pip install -e .
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## First run
|
|
47
|
+
|
|
48
|
+
On first launch, rift-tui walks you through setup — no config files to hand-edit:
|
|
49
|
+
|
|
50
|
+
1. **Paste your Riot API key** when prompted (or press `Esc` to skip and add it later with `K`)
|
|
51
|
+
2. **Enter your Riot ID** (e.g. `YourName#TAG`) and pick your region with `←`/`→` (or skip and add it later with `A`)
|
|
52
|
+
|
|
53
|
+
That's it — your account and key are saved locally and reused on every future launch.
|
|
54
|
+
|
|
55
|
+
## Keybinds
|
|
56
|
+
|
|
57
|
+
| Key | Action |
|
|
58
|
+
|---|---|
|
|
59
|
+
| `/` | Search for a player |
|
|
60
|
+
| `1`–`9`, `0` | Open match 1–10 detail |
|
|
61
|
+
| `Esc` | Back / close whatever's open |
|
|
62
|
+
| `Tab` | Switch panel focus |
|
|
63
|
+
| `↑` `↓` | Scroll the focused panel (or browse recent searches / recent bookmarks while typing) |
|
|
64
|
+
| `←` `→` | Change region while searching or adding a player |
|
|
65
|
+
| `R` | Refresh now |
|
|
66
|
+
| `I` | Cycle auto-refresh interval |
|
|
67
|
+
| `T` | Cycle queue type (Solo / Flex / ARAM) |
|
|
68
|
+
| `F` | Filter match list by champion |
|
|
69
|
+
| `A` | Manage tracked accounts (add/remove) |
|
|
70
|
+
| `N` | Switch to next tracked account |
|
|
71
|
+
| `B` | Bookmarks — open list / add current or new player |
|
|
72
|
+
| `C` | Toggle compare mode (while viewing a searched player) |
|
|
73
|
+
| `Y` | Copy the currently viewed Riot ID to clipboard |
|
|
74
|
+
| `K` | Add or update your Riot API key — no `.env` editing needed |
|
|
75
|
+
| `?` | Show the help overlay |
|
|
76
|
+
| `Q` | Quit |
|
|
77
|
+
|
|
78
|
+
## Where your data lives
|
|
79
|
+
|
|
80
|
+
Nothing is stored next to the installed package. rift-tui uses your OS's proper per-user data folder (via `platformdirs`) — e.g. `%LOCALAPPDATA%\rift-tui` on Windows, `~/.local/share/rift-tui` on Linux:
|
|
81
|
+
|
|
82
|
+
- `accounts.json` — your tracked accounts
|
|
83
|
+
- `bookmarks.json` — saved players
|
|
84
|
+
- `app_settings.json` — refresh interval and your API key
|
|
85
|
+
|
|
86
|
+
## Troubleshooting
|
|
87
|
+
|
|
88
|
+
- **"Rate limited by Riot API (429)"** — personal dev keys are capped at 20 requests/second and 100 requests/2 minutes. Wait a moment and retry.
|
|
89
|
+
- **"Invalid or expired Riot API key"** — dev keys expire every 24 hours. Press `K` in-app to paste a fresh one, no restart needed.
|
|
90
|
+
- **"Player not found"** — double check the exact Riot ID (`name#tag`), and try a different region with `←`/`→` — Riot IDs are region-locked to wherever the account actually plays.
|
|
91
|
+
- **Keys not responding on Windows** — see the terminal note under Requirements above.
|
|
92
|
+
- **Screen looks broken on a small window** — `Tab` to focus a panel, then scroll it with arrow keys or your mouse wheel.
|
|
93
|
+
|
|
94
|
+
## A note on API keys
|
|
95
|
+
|
|
96
|
+
This project uses a **bring-your-own-key** model: each user gets their own free personal Riot API key rather than the app shipping with one baked in. This isn't a limitation — Riot's developer terms explicitly prohibit embedding any API key (personal or production) in software you distribute to others, and personal keys are specifically meant for exactly this kind of individual-use tool.
|
|
97
|
+
|
|
98
|
+
## License
|
|
99
|
+
|
|
100
|
+
MIT
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "rift-tui"
|
|
7
|
+
version = "1.0.1"
|
|
8
|
+
description = "A terminal-based League of Legends stats tracker built with Textual"
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
requires-python = ">=3.10"
|
|
11
|
+
license = { text = "MIT" }
|
|
12
|
+
authors = [
|
|
13
|
+
{ name = "rileria" },
|
|
14
|
+
]
|
|
15
|
+
keywords = ["league-of-legends", "riot-api", "tui", "textual", "terminal"]
|
|
16
|
+
classifiers = [
|
|
17
|
+
"Environment :: Console",
|
|
18
|
+
"Intended Audience :: End Users/Desktop",
|
|
19
|
+
"License :: OSI Approved :: MIT License",
|
|
20
|
+
"Programming Language :: Python :: 3",
|
|
21
|
+
"Programming Language :: Python :: 3.10",
|
|
22
|
+
"Programming Language :: Python :: 3.11",
|
|
23
|
+
"Programming Language :: Python :: 3.12",
|
|
24
|
+
"Operating System :: OS Independent",
|
|
25
|
+
"Topic :: Games/Entertainment",
|
|
26
|
+
"Topic :: Terminals",
|
|
27
|
+
]
|
|
28
|
+
dependencies = [
|
|
29
|
+
"textual>=0.50.0",
|
|
30
|
+
"httpx>=0.27.0",
|
|
31
|
+
"python-dotenv>=1.0.0",
|
|
32
|
+
"platformdirs>=4.0.0",
|
|
33
|
+
"pyperclip>=1.8.0",
|
|
34
|
+
]
|
|
35
|
+
|
|
36
|
+
[project.urls]
|
|
37
|
+
Homepage = "https://github.com/rileriaaa/rift-tui"
|
|
38
|
+
Repository = "https://github.com/rileriaaa/rift-tui"
|
|
39
|
+
Issues = "https://github.com/rileriaaa/rift-tui/issues"
|
|
40
|
+
|
|
41
|
+
[project.scripts]
|
|
42
|
+
rift-tui = "rift_tui.__main__:main"
|
|
43
|
+
|
|
44
|
+
[tool.hatch.build.targets.wheel]
|
|
45
|
+
packages = ["src/rift_tui"]
|