Populate layered-soul: identity, memories, skills, plan (Hermes & Sam)
- SOUL.md: full agent identity, operating principles, voice
- IDENTITY.md: runtime identity, hosts, boundaries
- USER.md: operator context imported from hermes-soul
- AGENTS.md: actual operating rules, infrastructure, quick reference
- memories/curated/: 5 topics (tailscale, forgejo, agents, projects, vaultwarden)
- skills/: 9 cross-harness skills imported from hermes-soul after review
- docs/PLAN-CONFIGURE-PRIVATE-REPO.md: configuration plan
- Validate: passes clean
2026-06-14 00:21:26 +02:00
# Codeberg Host Reference
Codeberg is a Forgejo-based public git host at `codeberg.org` . Git operations are identical to self-hosted Forgejo, but the API is Forgejo, SSH key names differ, and discovery flows use `git ls-remote` instead of `gh` .
## Prerequisites
SSH key must be added at https://codeberg.org/settings/keys. Test:
```bash
ssh -T git@codeberg .org
# Expected: "Hi there, <user>! You've successfully authenticated..."
```
No `gh` CLI — use pure `git` + `ssh` for everything.
## Check What's Cloned Locally
When a project spans multiple repos, first survey what exists:
```bash
for d in /home/user/ai/*/; do
if [ -d "$d/.git" ]; then
echo "=== $d ==="
git -C "$d" remote -v
fi
done
```
## Test Remote Repo Existence
```bash
git ls-remote git@codeberg .org:OrgName/RepoName.git HEAD
```
## Clone
```bash
git clone git@codeberg .org:OrgName/RepoName.git /path/to/dest
git clone --depth 1 git@codeberg .org:OrgName/RepoName.git /path/to/dest # shallow
```
## Multi-Repo AGENTS.md Audit
After cloning, audit each repo's AGENTS.md for:
2026-06-14 01:48:32 +02:00
Populate layered-soul: identity, memories, skills, plan (Hermes & Sam)
- SOUL.md: full agent identity, operating principles, voice
- IDENTITY.md: runtime identity, hosts, boundaries
- USER.md: operator context imported from hermes-soul
- AGENTS.md: actual operating rules, infrastructure, quick reference
- memories/curated/: 5 topics (tailscale, forgejo, agents, projects, vaultwarden)
- skills/: 9 cross-harness skills imported from hermes-soul after review
- docs/PLAN-CONFIGURE-PRIVATE-REPO.md: configuration plan
- Validate: passes clean
2026-06-14 00:21:26 +02:00
- Agent identity table present
- OS split documented (Dev host vs deploy target)
- Cross-repo section lists all repos
- Constraints match platform
**Audit technique** — scan for OS-specific terms:
```python
from pathlib import Path
terms = ['FreeBSD', 'Linux', 'bastille', 'jail', 'pkg ', 'apt', 'systemd']
for term in terms:
hits = []
for path in Path(root).rglob('*'):
if path.is_file() and '.git/' not in str(path):
try:
count = path.read_text(errors='ignore').lower().count(term.lower())
if count > 0:
hits.append((str(path.relative_to(root)), count))
except: pass
if hits:
print(f' {term}: {sum(h[1] for h in hits)} hits in {len(hits)} files')
```
## Fixing Stale Git Remotes
```bash
git remote -v
git remote remove origin-https
git remote set-url origin-https git@codeberg .org:OrgName/CorrectRepo.git
```
## Shallow Clone Fixes (Codeberg-specific)
When unshallow via SSH times out, use HTTPS fallback:
```bash
git remote set-url origin https://codeberg.org/Org/Repo.git
git fetch --unshallow origin
git remote set-url origin git@codeberg .org:Org/Repo.git # restore SSH
```
## Quick Reference
2026-06-14 01:48:32 +02:00
| Action | Command |
| ----------------- | --------------------------------------------------- |
| Test SSH auth | `ssh -T git@codeberg.org` |
| Check repo exists | `git ls-remote git@codeberg.org:Org/Repo.git HEAD` |
| Clone | `git clone git@codeberg.org:Org/Repo.git` |
| Shallow clone | `git clone --depth 1 git@codeberg.org:Org/Repo.git` |