Skip to content

Implement logic to mark projects as 'likely_class_project' based on parent remixes and create a script for bulk updates#449

Open
cycomachead wants to merge 1 commit into
mainfrom
cycomachead/ai/13/1
Open

Implement logic to mark projects as 'likely_class_project' based on parent remixes and create a script for bulk updates#449
cycomachead wants to merge 1 commit into
mainfrom
cycomachead/ai/13/1

Conversation

@cycomachead
Copy link
Copy Markdown
Member

Propagate likely_class_work status to remixes

Implements automatic inheritance of the likely_class_work flag when projects are remixed, and adds a CLI utility for bulk-marking a user's or project's entire remix tree as class work.

Changes

  • controllers/project.lua

    • When a project is manually marked as a remix (mark_as_remix), if the parent project has likely_class_work = true, the remixed project is updated to match.
    • During project save, if a remixID is present in the request body, the parent's likely_class_work status is inherited by the new project at creation time.
  • bin/mark-class-projects.lua (new)

    • CLI script to bulk-update likely_class_work = true for all projects belonging to a user (--user <username>) or a single project (--project <id>).
    • Uses a recursive CTE to walk the full remix descendant tree, ensuring transitive remixes are also marked.
    • Connects using the same environment variables as the rest of the project (DATABASE_HOST, DATABASE_PORT, etc.).
    • Reports how many projects were newly marked.

Usage

lua bin/mark-class-projects.lua --user <username>
lua bin/mark-class-projects.lua --project <project_id>

Superconductor Ticket Implementation | App Preview | Guided Review

- Update project controller to inherit `likely_class_work` status from
  parent projects during remix creation and manual remix marking.
- Add `bin/mark-class-projects.lua` utility to bulk update projects by
  user or project ID, including recursive updates for all descendants.

Co-authored-by: Claude Code <noreply@anthropic.com>
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