cy0307 commited on
Commit
f7299a4
·
verified ·
1 Parent(s): 102fe95

Guard share page

Browse files
scripts/check_project_consistency.py CHANGED
@@ -141,6 +141,16 @@ def main() -> int:
141
  failures,
142
  )
143
  require(ROOT / "meta" / "social-preview.html", [f">{count}</b>"], failures)
 
 
 
 
 
 
 
 
 
 
144
  require(
145
  ROOT / "posts" / "launch.md",
146
  [
 
141
  failures,
142
  )
143
  require(ROOT / "meta" / "social-preview.html", [f">{count}</b>"], failures)
144
+ distribution_text = (ROOT / "meta" / "DISTRIBUTION.md").read_text(encoding="utf-8")
145
+ share_match = re.search(r"awesome-loop-engineering/(x-v\d+-\d+\.html)", distribution_text)
146
+ if share_match is None:
147
+ failures.append("meta/DISTRIBUTION.md: missing current x share-page link")
148
+ else:
149
+ require(
150
+ ROOT / "docs" / share_match.group(1),
151
+ [f"{count} resources", f"{count} papers"],
152
+ failures,
153
+ )
154
  require(
155
  ROOT / "posts" / "launch.md",
156
  [