Skip to content

Phase 2: Add GitHub repository deletion service function - #130

Merged
neuromechanist merged 2 commits into
feature/issue-128-epic-deletionfrom
feature/issue-124-github-deletion
Feb 12, 2026
Merged

neuromechanist merged 2 commits into
feature/issue-128-epic-deletionfrom
feature/issue-124-github-deletion

Conversation

@neuromechanist

Copy link
Copy Markdown
Contributor

Summary

  • Add deleteRepository() to github.ts
  • Idempotent: 204 (deleted) and 404 (already gone) both return success
  • Throws with details on auth errors or other failures
  • Requires PAT with delete_repo scope

Test plan

  • Tests in test/github-deletion.test.ts
  • Tests skip when GITHUB_ADMIN_PAT not available
  • Covers: non-existent repo (404 idempotent), invalid PAT (throws)
  • bunx biome check passes
  • bun run typecheck passes

Closes #124
Part of Epic #128 (Dataset deletion system)

@github-actions

github-actions Bot commented Feb 12, 2026 •

Copy link
Copy Markdown

📦 Package Preview

Your package is ready to test!

bun install -g nemar-cli@PR130

Version: 0.4.0-PR130.ee8b156
Commit: ee8b156


🤖 Updated on each push.

Add deleteRepository() to github.ts. Idempotent: 204 (deleted)
and 404 (not found) both return success. Requires PAT with
delete_repo scope.

Closes #124
- Add repo name validation (reject /, .., empty)
- Tighten status check to 204/404 only (not all 2xx)
- Use clearly fake repo name in invalid PAT test

This branch was previously deployed

1 inactive deployment
npm — a56c9634 Deployed Feb 12, 2026 by neuromechanist via publish #211
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant