Skip to content

Commit acab455

Browse files
authored
Merge pull request #25 from PyAutoLabs/feature/memory-structure-cleanup
Restructure: wiki/ + bibliography consolidation, structure lint (#24)
2 parents ba11305 + 9f63e79 commit acab455

198 files changed

Lines changed: 457 additions & 89205 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/validate.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: validate
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
8+
jobs:
9+
validate:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
- uses: actions/setup-python@v5
14+
with:
15+
python-version: "3.11"
16+
- run: pip install pytest
17+
- run: make validate
18+
- run: make test

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ desktop.ini
3434
*.swp
3535
*~
3636
__pycache__/
37+
.pytest_cache/
3738
*.pyc
3839

3940
# LaTeX build artefacts
@@ -48,4 +49,4 @@ __pycache__/
4849
*.toc
4950

5051
# Exception — the wiki's own log.md is text and must be tracked
51-
!lensing_wiki/log.md
52+
!wiki/*/log.md

AGENTS.md

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,31 @@ packaging, tooling, and workflow tasks.
1515
When you do read:
1616

1717
1. **Index first.** Start at [`index.md`](index.md), then the relevant
18-
sub-wiki's own `index.md` (`lensing_wiki/`, `smbh_wiki/`, `cti_wiki/`,
19-
`methods_wiki/`, `galaxies_wiki/`).
18+
sub-wiki's own `index.md` (`wiki/lensing/`, `wiki/smbh/`, `wiki/cti/`,
19+
`wiki/methods/`, `wiki/galaxies/`).
2020
2. **Then at most 2–3 pages.** Read only the concept/entity/source pages the
2121
index points you to. **Never bulk-load a sub-wiki.**
2222
3. **Do not couple to the internal layout** — reach pages through the indexes,
2323
not hard-coded paths.
2424

25+
## The write contract (layout rules)
26+
27+
The repo has exactly **two content homes**, enforced by
28+
`make validate-structure` (CI runs it on every push/PR):
29+
30+
- **`wiki/<domain>/`** — every sub-wiki, following the shared schema in
31+
[`wiki/CLAUDE.md`](wiki/CLAUDE.md). New sub-wikis are added beside the
32+
existing ones, never at the repo root.
33+
- **`bibliography/`** — the *only* place BibTeX lives. One canonical file
34+
(`pyautomemory.bib`) plus `bibkey_aliases.yaml`; never add loose `.bib`
35+
files anywhere else.
36+
37+
**Source PDFs live off-repo.** Never commit a paper (PDF/HTML, with or
38+
without a file extension) — read it, stub it in the right
39+
`wiki/<domain>/sources/*.md`, add its canonical entry to `bibliography/`,
40+
and run `make validate`. Unrecognised top-level files/folders fail the lint;
41+
the allowlist is in `scripts/validate_structure.py`.
42+
2543
## What does NOT live here
2644

2745
- **Operational history** — what the organism *did* (prior tasks, decisions,

CTI/Hall1952Theory

Lines changed: 0 additions & 69 deletions
This file was deleted.
-309 KB
Binary file not shown.

Euclid/Paykari2020.bib

Lines changed: 0 additions & 18 deletions
This file was deleted.

Hubble1926.321H

-2.54 MB
Binary file not shown.
-4.38 MB
Binary file not shown.

Makefile

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,12 @@
1-
.PHONY: validate-literature-citations
1+
.PHONY: validate validate-literature-citations validate-structure test
2+
3+
validate: validate-literature-citations validate-structure
24

35
validate-literature-citations:
46
python scripts/validate_literature_citations.py
7+
8+
validate-structure:
9+
python scripts/validate_structure.py
10+
11+
test:
12+
python -m pytest tests/ -q

0 commit comments

Comments
 (0)