This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import pathlib
|
||||
|
||||
from loop_state.paths import CLAUDE_HOME
|
||||
from failure import Failure
|
||||
from project_config.main import located
|
||||
from chunk_driver.project.text_file import read_utf8
|
||||
@@ -15,7 +16,7 @@ HUMAN_RULES_FILE = "CLAUDE.md"
|
||||
HUMAN_RULE_DIR = "rules"
|
||||
# How the judge's prompt names the records above, in the order it reads them.
|
||||
RECORDS_NAMED = "the project's working rules and decisions, then the human's rules for every project"
|
||||
HUMAN_RULE_NAMES = (f"~/.claude/{HUMAN_RULES_FILE}", f"~/.claude/{HUMAN_RULE_DIR}/", "the project's review standards")
|
||||
HUMAN_RULE_NAMES = (f"~/{CLAUDE_HOME}/{HUMAN_RULES_FILE}", f"~/{CLAUDE_HOME}/{HUMAN_RULE_DIR}/", "the project's review standards")
|
||||
|
||||
|
||||
CONSEQUENCE = "the judge cannot read the records"
|
||||
@@ -55,5 +56,5 @@ def file_text(path: pathlib.Path) -> str | Failure:
|
||||
def named(rule: pathlib.Path, home: pathlib.Path, claude_dir: pathlib.Path) -> str:
|
||||
"""rule's path as the human writes it: under ~/.claude, or ~/ for the rest of home, or else in full."""
|
||||
if rule.is_relative_to(claude_dir):
|
||||
return f"~/.claude/{rule.relative_to(claude_dir)}"
|
||||
return f"~/{CLAUDE_HOME}/{rule.relative_to(claude_dir)}"
|
||||
return f"~/{rule.relative_to(home)}" if rule.is_relative_to(home) else str(rule)
|
||||
|
||||
Reference in New Issue
Block a user