gpufetch 0.1.0__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.
Files changed (62) hide show
  1. gpufetch-0.1.0/.claude/settings.local.json +7 -0
  2. gpufetch-0.1.0/.gitattributes +1 -0
  3. gpufetch-0.1.0/.gitignore +25 -0
  4. gpufetch-0.1.0/PKG-INFO +48 -0
  5. gpufetch-0.1.0/README.md +40 -0
  6. gpufetch-0.1.0/pyproject.toml +17 -0
  7. gpufetch-0.1.0/src/gpufetch/__init__.py +3 -0
  8. gpufetch-0.1.0/src/gpufetch/__main__.py +5 -0
  9. gpufetch-0.1.0/src/gpufetch/ansi.py +19 -0
  10. gpufetch-0.1.0/src/gpufetch/data/wordle_valid.txt +14855 -0
  11. gpufetch-0.1.0/src/gpufetch/eightball.py +281 -0
  12. gpufetch-0.1.0/src/gpufetch/entities/__init__.py +22 -0
  13. gpufetch-0.1.0/src/gpufetch/entities/anime_girl.py +51 -0
  14. gpufetch-0.1.0/src/gpufetch/entities/arch.py +25 -0
  15. gpufetch-0.1.0/src/gpufetch/entities/base.py +80 -0
  16. gpufetch-0.1.0/src/gpufetch/entities/bible_quote.py +45 -0
  17. gpufetch-0.1.0/src/gpufetch/entities/bill_100.py +21 -0
  18. gpufetch-0.1.0/src/gpufetch/entities/crab.py +17 -0
  19. gpufetch-0.1.0/src/gpufetch/entities/debian.py +21 -0
  20. gpufetch-0.1.0/src/gpufetch/entities/dvd.py +10 -0
  21. gpufetch-0.1.0/src/gpufetch/entities/empty_wallet.py +23 -0
  22. gpufetch-0.1.0/src/gpufetch/entities/ethereum.py +27 -0
  23. gpufetch-0.1.0/src/gpufetch/entities/fedora.py +23 -0
  24. gpufetch-0.1.0/src/gpufetch/entities/ghost.py +19 -0
  25. gpufetch-0.1.0/src/gpufetch/entities/gorilla.py +25 -0
  26. gpufetch-0.1.0/src/gpufetch/entities/greeting.py +30 -0
  27. gpufetch-0.1.0/src/gpufetch/entities/grim_reaper.py +27 -0
  28. gpufetch-0.1.0/src/gpufetch/entities/jesus.py +25 -0
  29. gpufetch-0.1.0/src/gpufetch/entities/jewish_star.py +29 -0
  30. gpufetch-0.1.0/src/gpufetch/entities/marge.py +51 -0
  31. gpufetch-0.1.0/src/gpufetch/entities/maui.py +25 -0
  32. gpufetch-0.1.0/src/gpufetch/entities/nuke.py +27 -0
  33. gpufetch-0.1.0/src/gpufetch/entities/nvidia.py +23 -0
  34. gpufetch-0.1.0/src/gpufetch/entities/rxknephew.py +25 -0
  35. gpufetch-0.1.0/src/gpufetch/entities/scrooge.py +25 -0
  36. gpufetch-0.1.0/src/gpufetch/entities/shadow_wizard.py +29 -0
  37. gpufetch-0.1.0/src/gpufetch/entities/ship.py +19 -0
  38. gpufetch-0.1.0/src/gpufetch/entities/slot_machine.py +41 -0
  39. gpufetch-0.1.0/src/gpufetch/entities/stuffed_wallet.py +21 -0
  40. gpufetch-0.1.0/src/gpufetch/entities/trophy.py +25 -0
  41. gpufetch-0.1.0/src/gpufetch/entities/tux.py +12 -0
  42. gpufetch-0.1.0/src/gpufetch/entities/ufo.py +17 -0
  43. gpufetch-0.1.0/src/gpufetch/game_blackjack.py +383 -0
  44. gpufetch-0.1.0/src/gpufetch/game_dino.py +355 -0
  45. gpufetch-0.1.0/src/gpufetch/game_roulette.py +322 -0
  46. gpufetch-0.1.0/src/gpufetch/game_snake.py +395 -0
  47. gpufetch-0.1.0/src/gpufetch/game_wordle.py +623 -0
  48. gpufetch-0.1.0/src/gpufetch/main.py +1290 -0
  49. gpufetch-0.1.0/src/gpufetch/spotify.py +231 -0
  50. gpufetch-0.1.0/src/gpufetch/sysinfo.py +259 -0
  51. gpufetch-0.1.0/src/gpufetch/themes/__init__.py +24 -0
  52. gpufetch-0.1.0/src/gpufetch/themes/america.py +22 -0
  53. gpufetch-0.1.0/src/gpufetch/themes/base.py +59 -0
  54. gpufetch-0.1.0/src/gpufetch/themes/canada.py +18 -0
  55. gpufetch-0.1.0/src/gpufetch/themes/china.py +18 -0
  56. gpufetch-0.1.0/src/gpufetch/themes/christmas.py +20 -0
  57. gpufetch-0.1.0/src/gpufetch/themes/four_twenty.py +20 -0
  58. gpufetch-0.1.0/src/gpufetch/themes/halloween.py +21 -0
  59. gpufetch-0.1.0/src/gpufetch/themes/israel.py +18 -0
  60. gpufetch-0.1.0/src/gpufetch/themes/matrix.py +19 -0
  61. gpufetch-0.1.0/src/gpufetch/themes/rainbow.py +63 -0
  62. gpufetch-0.1.0/src/gpufetch/weather.py +229 -0
@@ -0,0 +1,7 @@
1
+ {
2
+ "permissions": {
3
+ "allow": [
4
+ "Bash(python3:*)"
5
+ ]
6
+ }
7
+ }
@@ -0,0 +1 @@
1
+ demo.gif filter=lfs diff=lfs merge=lfs -text
@@ -0,0 +1,25 @@
1
+ # Build artifacts
2
+ dist/
3
+ *.egg-info/
4
+ build/
5
+
6
+ # Python cache
7
+ __pycache__/
8
+ *.pyc
9
+ *.pyo
10
+ *.pyd
11
+ .python-version
12
+
13
+ # Virtual environments
14
+ .venv/
15
+ venv/
16
+ env/
17
+
18
+ # uv
19
+ .uv/
20
+
21
+ # Editors
22
+ .idea/
23
+ .vscode/
24
+ *.swp
25
+ *~
@@ -0,0 +1,48 @@
1
+ Metadata-Version: 2.4
2
+ Name: gpufetch
3
+ Version: 0.1.0
4
+ Summary: GPU monitor TUI with ASCII art, games, and widgets
5
+ License: MIT
6
+ Requires-Python: >=3.11
7
+ Description-Content-Type: text/markdown
8
+
9
+ # lsgpu
10
+
11
+ Minimal CLI tool for displaying connected GPUs
12
+
13
+ ## Installing
14
+ uv:
15
+ ```
16
+ uv tool install gpufetch
17
+ ```
18
+ pipx:
19
+ ```
20
+ pipx install gpufetch
21
+ ```
22
+
23
+ ## Usage
24
+ ```
25
+ :: ~/ » gpufetch --help
26
+ usage: gpufetch [-h] [--theme NAME] [--entities a,b,c] [--entities-random N] [--fire] [--connect-spotify] [--spotify] [--sysinfo] [--weather] [--eightball] [--play GAME]
27
+
28
+ List connected GPUs
29
+
30
+ options:
31
+ -h, --help show this help message and exit
32
+ --theme NAME display theme (default: default)
33
+ --entities a,b,c comma-separated entity names to bounce on screen
34
+ --entities-random N spawn N randomly chosen entities
35
+ --fire enable fire animation along the bottom of the screen
36
+ --connect-spotify run Spotify OAuth flow and save credentials, then exit
37
+ --spotify show Spotify now-playing widget
38
+ --sysinfo show CPU/memory usage widget
39
+ --weather show weather widget for Rochester, NY
40
+ --eightball show Magic 8-ball widget
41
+ --play GAME jump straight into a game: wordle, snake, roulette
42
+
43
+ themes: default, america, canada, china, christmas, 420, halloween, israel, matrix, rainbow
44
+ entities: anime_girl, arch, bible_quote, bill_100, crab, debian, dvd, empty_wallet, ethereum, fedora, ghost, gorilla, greeting, grim_reaper, jesus, jewish_star, maui, nuke, nvidia, rxknephew, scrooge, shadow_wizard, ship, slot_machine, stuffed_wallet, trophy, tux, ufo
45
+ games: wordle, snake, roulette
46
+
47
+ TUI keys: / → command prompt q → quit /help → command list
48
+ ```
@@ -0,0 +1,40 @@
1
+ # lsgpu
2
+
3
+ Minimal CLI tool for displaying connected GPUs
4
+
5
+ ## Installing
6
+ uv:
7
+ ```
8
+ uv tool install gpufetch
9
+ ```
10
+ pipx:
11
+ ```
12
+ pipx install gpufetch
13
+ ```
14
+
15
+ ## Usage
16
+ ```
17
+ :: ~/ » gpufetch --help
18
+ usage: gpufetch [-h] [--theme NAME] [--entities a,b,c] [--entities-random N] [--fire] [--connect-spotify] [--spotify] [--sysinfo] [--weather] [--eightball] [--play GAME]
19
+
20
+ List connected GPUs
21
+
22
+ options:
23
+ -h, --help show this help message and exit
24
+ --theme NAME display theme (default: default)
25
+ --entities a,b,c comma-separated entity names to bounce on screen
26
+ --entities-random N spawn N randomly chosen entities
27
+ --fire enable fire animation along the bottom of the screen
28
+ --connect-spotify run Spotify OAuth flow and save credentials, then exit
29
+ --spotify show Spotify now-playing widget
30
+ --sysinfo show CPU/memory usage widget
31
+ --weather show weather widget for Rochester, NY
32
+ --eightball show Magic 8-ball widget
33
+ --play GAME jump straight into a game: wordle, snake, roulette
34
+
35
+ themes: default, america, canada, china, christmas, 420, halloween, israel, matrix, rainbow
36
+ entities: anime_girl, arch, bible_quote, bill_100, crab, debian, dvd, empty_wallet, ethereum, fedora, ghost, gorilla, greeting, grim_reaper, jesus, jewish_star, maui, nuke, nvidia, rxknephew, scrooge, shadow_wizard, ship, slot_machine, stuffed_wallet, trophy, tux, ufo
37
+ games: wordle, snake, roulette
38
+
39
+ TUI keys: / → command prompt q → quit /help → command list
40
+ ```
@@ -0,0 +1,17 @@
1
+ [build-system]
2
+ requires = ["hatchling"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "gpufetch"
7
+ version = "0.1.0"
8
+ description = "GPU monitor TUI with ASCII art, games, and widgets"
9
+ readme = "README.md"
10
+ requires-python = ">=3.11"
11
+ license = { text = "MIT" }
12
+
13
+ [project.scripts]
14
+ gpufetch = "gpufetch.main:main"
15
+
16
+ [tool.hatch.build.targets.wheel]
17
+ packages = ["src/gpufetch"]
@@ -0,0 +1,3 @@
1
+ """lsgpu — GPU monitor TUI with ASCII art, games, and widgets."""
2
+
3
+ __version__ = "0.1.0"
@@ -0,0 +1,5 @@
1
+ """Allow running as ``python -m gpufetch``."""
2
+
3
+ from gpufetch.main import main
4
+
5
+ main()
@@ -0,0 +1,19 @@
1
+ """Shared ANSI escape code constants and helpers."""
2
+
3
+ import re
4
+
5
+ RESET = "\033[0m"
6
+ BOLD = "\033[1m"
7
+ DIM = "\033[2m"
8
+ GREEN = "\033[32m"
9
+ CYAN = "\033[36m"
10
+ YELLOW = "\033[33m"
11
+ RED = "\033[31m"
12
+ BLUE = "\033[34m"
13
+ MAGENTA = "\033[35m"
14
+ WHITE = "\033[37m"
15
+
16
+ _ANSI_RE = re.compile(r"\033\[[0-9;]*m")
17
+
18
+ def strip_ansi(s: str) -> str:
19
+ return _ANSI_RE.sub("", s)