codehydra 2026.1.13__py3-none-any.whl

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.
codehydra/__init__.py ADDED
@@ -0,0 +1,102 @@
1
+ #!/usr/bin/env python3
2
+ """CodeHydra launcher for PyPI - Downloads and caches the appropriate binary from GitHub Releases."""
3
+
4
+ import os
5
+ import platform
6
+ import stat
7
+ import subprocess
8
+ import sys
9
+ import zipfile
10
+ from importlib.metadata import version as get_version
11
+ from pathlib import Path
12
+ from urllib.request import Request, urlopen
13
+
14
+ REPO = "stefanhoelzl/codehydra"
15
+
16
+ ASSET_MAP = {
17
+ ("Linux", "x86_64"): "CodeHydra-linux-x64.AppImage",
18
+ ("Darwin", "x86_64"): "CodeHydra-darwin-x64.zip",
19
+ ("Darwin", "arm64"): "CodeHydra-darwin-arm64.zip",
20
+ ("Windows", "AMD64"): "CodeHydra-win-portable-x64.zip",
21
+ }
22
+
23
+
24
+ def get_cache_dir(pkg_version: str) -> Path:
25
+ """Get the platform-specific cache directory."""
26
+ system = platform.system()
27
+ if system == "Linux":
28
+ base = Path(os.environ.get("XDG_DATA_HOME", Path.home() / ".local" / "share"))
29
+ return base / "codehydra" / "releases" / pkg_version
30
+ elif system == "Darwin":
31
+ return Path.home() / "Library" / "Application Support" / "Codehydra" / "releases" / pkg_version
32
+ elif system == "Windows":
33
+ base = Path(os.environ.get("LOCALAPPDATA", Path.home() / "AppData" / "Local"))
34
+ return base / "Codehydra" / "releases" / pkg_version
35
+ raise RuntimeError(f"Unsupported platform: {system}")
36
+
37
+
38
+ def get_asset_name() -> str:
39
+ """Get the GitHub release asset name for the current platform."""
40
+ key = (platform.system(), platform.machine())
41
+ asset = ASSET_MAP.get(key)
42
+ if not asset:
43
+ raise RuntimeError(f"Unsupported platform: {key[0]}-{key[1]}")
44
+ return asset
45
+
46
+
47
+ def get_binary_path(cache_dir: Path, asset_name: str) -> Path:
48
+ """Get the path to the executable binary."""
49
+ system = platform.system()
50
+ if system == "Windows":
51
+ return cache_dir / "CodeHydra-win-portable-x64" / "CodeHydra.exe"
52
+ elif system == "Darwin":
53
+ app_name = asset_name.replace(".zip", "")
54
+ return cache_dir / app_name / "CodeHydra.app" / "Contents" / "MacOS" / "CodeHydra"
55
+ return cache_dir / asset_name
56
+
57
+
58
+ def download(url: str, dest_path: Path, pkg_version: str) -> None:
59
+ """Download a file from URL to destination path."""
60
+ tmp_path = dest_path.with_suffix(dest_path.suffix + ".tmp")
61
+ request = Request(url, headers={"User-Agent": f"codehydra-pypi/{pkg_version}"})
62
+ with urlopen(request) as response:
63
+ with open(tmp_path, "wb") as f:
64
+ while chunk := response.read(8192):
65
+ f.write(chunk)
66
+ tmp_path.rename(dest_path)
67
+
68
+
69
+ def main() -> None:
70
+ """Main entry point for the launcher."""
71
+ pkg_version = get_version("codehydra")
72
+ cache_dir = get_cache_dir(pkg_version)
73
+ asset_name = get_asset_name()
74
+ binary_path = get_binary_path(cache_dir, asset_name)
75
+
76
+ if not binary_path.exists():
77
+ print(f"Downloading CodeHydra {pkg_version}...")
78
+ cache_dir.mkdir(parents=True, exist_ok=True)
79
+
80
+ download_url = f"https://github.com/{REPO}/releases/download/v{pkg_version}/{asset_name}"
81
+ download_path = cache_dir / asset_name
82
+ download(download_url, download_path, pkg_version)
83
+
84
+ if asset_name.endswith(".zip"):
85
+ print("Extracting...")
86
+ with zipfile.ZipFile(download_path, "r") as zf:
87
+ zf.extractall(cache_dir)
88
+ download_path.unlink()
89
+
90
+ if platform.system() != "Windows":
91
+ binary_path.chmod(binary_path.stat().st_mode | stat.S_IXUSR | stat.S_IXGRP | stat.S_IXOTH)
92
+
93
+ print("Done!\n")
94
+
95
+ if platform.system() == "Windows":
96
+ sys.exit(subprocess.run([str(binary_path)] + sys.argv[1:]).returncode)
97
+ else:
98
+ os.execv(str(binary_path), [str(binary_path)] + sys.argv[1:])
99
+
100
+
101
+ if __name__ == "__main__":
102
+ main()
@@ -0,0 +1,66 @@
1
+ Metadata-Version: 2.4
2
+ Name: codehydra
3
+ Version: 2026.1.13
4
+ Summary: Multi-workspace IDE for parallel AI agent development
5
+ Keywords: ai,agent,ide,vscode,git,worktree
6
+ Author: Stefan Hoelzl
7
+ License-Expression: MIT
8
+ Classifier: Development Status :: 4 - Beta
9
+ Classifier: Environment :: Console
10
+ Classifier: Intended Audience :: Developers
11
+ Classifier: License :: OSI Approved :: MIT License
12
+ Classifier: Operating System :: MacOS
13
+ Classifier: Operating System :: Microsoft :: Windows
14
+ Classifier: Operating System :: POSIX :: Linux
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: Programming Language :: Python :: 3.13
20
+ Requires-Python: >=3.10
21
+ Project-URL: Homepage, https://github.com/stefanhoelzl/codehydra
22
+ Project-URL: Issues, https://github.com/stefanhoelzl/codehydra/issues
23
+ Project-URL: Repository, https://github.com/stefanhoelzl/codehydra
24
+ Description-Content-Type: text/markdown
25
+
26
+ # CodeHydra
27
+
28
+ Multi-workspace IDE for parallel AI agent development.
29
+
30
+ ## Installation
31
+
32
+ ```bash
33
+ # Run directly without installation
34
+ uvx codehydra
35
+
36
+ # Or install globally
37
+ pip install codehydra
38
+ codehydra
39
+ ```
40
+
41
+ ## Features
42
+
43
+ - Run multiple AI agents simultaneously in isolated git worktrees
44
+ - Real-time status monitoring across all workspaces
45
+ - Keyboard-driven navigation (Alt+X shortcut mode)
46
+ - Full VS Code integration via code-server
47
+ - Built-in voice dictation
48
+
49
+ ## How It Works
50
+
51
+ This package downloads the appropriate CodeHydra binary for your platform from GitHub Releases on first run, caches it locally, and executes it with any passed arguments.
52
+
53
+ Supported platforms:
54
+
55
+ - Linux x64
56
+ - macOS x64 and arm64
57
+ - Windows x64
58
+
59
+ ## Links
60
+
61
+ - [GitHub Repository](https://github.com/stefanhoelzl/codehydra)
62
+ - [Releases](https://github.com/stefanhoelzl/codehydra/releases)
63
+
64
+ ## License
65
+
66
+ MIT
@@ -0,0 +1,5 @@
1
+ codehydra/__init__.py,sha256=W3I1LqlO-njp-jBneShQ7qXI-OD8jG0sy3qLtQN6H0E,3699
2
+ codehydra-2026.1.13.dist-info/WHEEL,sha256=eycQt0QpYmJMLKpE3X9iDk8R04v2ZF0x82ogq-zP6bQ,79
3
+ codehydra-2026.1.13.dist-info/entry_points.txt,sha256=wdu11Rq7NPyZeJn2I5C8y5re__ivpx6ZO7mREKHt2hg,46
4
+ codehydra-2026.1.13.dist-info/METADATA,sha256=UAqFtw-T6-m1Eo85FKCjjidyX1CV3EK33wkHvWcFhlA,1913
5
+ codehydra-2026.1.13.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: uv 0.9.24
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
@@ -0,0 +1,3 @@
1
+ [console_scripts]
2
+ codehydra = codehydra:main
3
+