summaryrefslogtreecommitdiff
path: root/nba_scores.egg-info/PKG-INFO
blob: 9e5fcd88d796da0e3f520b7e127fa83ae2682824 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
Metadata-Version: 2.4
Name: nba-scores
Version: 0.2.2
Summary: A CLI interface to get current NBA scores and standings.
Author-email: Christian Cleberg <[email protected]>
License-Expression: GPL-3.0-or-later
Project-URL: Homepage, https://git.cleberg.net/nba-scores.git
Project-URL: Issues, https://git.cleberg.net/nba-scores.git
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: nba_api
Requires-Dist: tabulate
Requires-Dist: argparse
Requires-Dist: textual<7.0,>=0.89.1
Dynamic: license-file

# NBA

![](./screenshots/preview.png)

NBA is a Python package that provides a command-line interface to current NBA
scores, standings, statistical leaders, playoff picture, and live box scores.
It supports both a static one-shot mode and an interactive TUI with
auto-refresh.

# Table of Contents

- [Installation](#installation)
- [Usage](#usage)
  - [Interactive TUI](#interactive-tui)
  - [Static output](#static-output)
- [Contributing](#contributing)

# Installation

[Back to top](#table-of-contents)

```shell
git clone https://git.cleberg.net/nba-scores.git
cd nba-scores
pipx install .
```

# Usage

[Back to top](#table-of-contents)

## Interactive TUI

Launch the full interactive terminal UI:

```shell
nba --tui
```

Optional flags:

| Flag               | Description                                            |
|--------------------|--------------------------------------------------------|
| `--tui`            | Launch the interactive TUI                             |
| `--scores`         | Open TUI on the Scores tab (default)                   |
| `--standings`      | Open TUI on the Standings tab                          |
| `--refresh N`      | Auto-refresh interval in seconds (default: 60, min: 10)|

### TUI tabs

| Tab             | Key | Description                                              |
|-----------------|-----|----------------------------------------------------------|
| Scores          | `s` | Today's games with live scores and status                |
| Standings       | `t` | East / West conference standings, side by side           |
| Leaders         | `l` | Top 25 players by stat category                          |
| Playoff Picture | `p` | Conference seeding with clinch and elimination status    |
| Bracket         | `k` | Playoff series matchups and series records               |
| Box Score       | `b` | Per-player live stats for a selected game                |

### TUI key bindings

| Key     | Action                                         |
|---------|------------------------------------------------|
| `1`–`9` | Load box score for game N from the Scores tab  |
| `,`     | Cycle to the previous leaders stat category    |
| `.`     | Cycle to the next leaders stat category        |
| `r`     | Refresh all data immediately                   |
| `q`     | Quit                                           |

### Leaders stat categories

Cycles through: Points, Rebounds, Assists, Steals, Blocks, Efficiency, FG%, FT%, 3P%

## Static output

Print scores or standings directly to the terminal without launching the TUI:

| Argument      | Shortcut | Description                       |
|---------------|----------|-----------------------------------|
| `--scores`    | `-sc`    | Print today's scoreboard          |
| `--standings` | `-st`    | Print current conference standings|

```shell
nba --scores
nba --standings
```

# Contributing

[Back to top](#table-of-contents)

Any and all contributions are welcome. Feel free to fork the project,
add features, and submit a pull request.