cribsheet 0.2.0__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.
crib/__init__.py ADDED
@@ -0,0 +1,20 @@
1
+ """cribsheet — markdown memory with a Chroma embedding index.
2
+
3
+ The package *imports* cleanly with only PyYAML present: heavy backends
4
+ (chromadb, sentence-transformers, fastmcp, watchdog) are imported lazily by the
5
+ modules that need them, so the core indexing loop stays usable — and testable —
6
+ without them. That's a code property, not a packaging claim — the base install
7
+ ships chromadb (a pyproject dependency), and normal use wants `[full]`.
8
+ """
9
+
10
+ # Single-sourced from pyproject: the installed package metadata IS the version,
11
+ # so `[project] version` in pyproject.toml (and the matching git tag) is the only
12
+ # place it's written. Falls back gracefully when run from an uninstalled tree.
13
+ from importlib.metadata import PackageNotFoundError, version as _pkg_version
14
+
15
+ try:
16
+ __version__ = _pkg_version("cribsheet")
17
+ except PackageNotFoundError: # running from source without an install
18
+ __version__ = "0+unknown"
19
+
20
+ del PackageNotFoundError, _pkg_version
crib/__main__.py ADDED
@@ -0,0 +1,9 @@
1
+ """`python -m crib` entry point — used by the git merge driver, which needs a
2
+ stable, PATH-independent way to re-invoke the CLI (DESIGN §14)."""
3
+
4
+ import sys
5
+
6
+ from .cli import main
7
+
8
+ if __name__ == "__main__":
9
+ sys.exit(main())