Public Access
feat: delete orphan workflows during sync — preserve custom-* prefix #315
Reference in New Issue
Block a user
Delete Branch "feature/delete-orphan-workflows"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
workflow_sync.php --delete-orphansnow removes workflows from repos that are not in the platform template.Protected from deletion:
custom-prefix (repo-specific convention)custom/subdirectory (future: subfolder discovery, see #314)New methods:
deleteOrphanWorkflows()— compares repo workflows against template, deletes extrasdeleteFile()— deletes a file via Gitea Contents APIlistWorkflowEntries()— lists all entries (files + dirs) in workflows dirTest plan
php -l cli/workflow_sync.phppasses--delete-orphanswith--dry-runshows WOULD DELETE for non-template workflowscustom-*.ymlfiles are preserved (shown as KEPT)