email-marketer-weeklylisted
Install: claude install-skill talentedgeai/infinite-leverage
It is Thursday 10:03 AM. Today's date is YYYY-MM-DD.
## Step 0 — Load credentials
```python
def parse_env(path):
vals = {}
try:
with open(path) as f:
for line in f:
line = line.strip()
if not line or line.startswith("#") or "=" not in line:
continue
k, _, v = line.partition("=")
vals[k.strip()] = v.strip().strip('"').strip("'")
except FileNotFoundError:
pass
return vals
env = {}
for f in [".env", ".env.development", ".env.production", ".env.local"]:
env.update(parse_env(f))
```
## Step 1 — Check email index
```bash
cd ~/code-projects/{project-slug}
```
Read `agents/email-marketer/context/email-index.md`. Identify:
- Which stage is currently in flight
- The most recently published blog post
- Which subscribers have already received what
IMPORTANT: If email-index.md is missing or Stage 0 is empty, stop and notify via Lark.
## Step 2 — Read source content
Read the most recently published `content/topics/*/blog.md` that has a corresponding page in `website/pages/blog/posts/`.
Read `agents/email-marketer/context/persona.md` for email voice and style (if exists).
## Step 3 — Draft newsletter
Write newsletter draft to `emails/drafts/newsletter-YYYY-MM-DD.md` with frontmatter:
```markdown
---
subject: {subject line}
preview: {preview text — 90 chars max}
segment: all-subscribers
stage: review
source_post: content/topics/{slug}/blog.md
---
{