Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 8, 2026

Plan: Implement create-project safe output for campaigns

  • Create new create-project safe output type
    • Add Go backend configuration
    • Create JavaScript implementation
    • Add schema validation
    • Add tool definitions
    • Wire up to compiler
  • Update campaign-generator.md to use create-project
  • Update agent instructions
  • Test compilation
  • Run campaign tests
  • Remove hardcoded organization (make flexible for user/org projects)

Implementation Complete

Created a new create-project safe output that creates empty GitHub Projects V2 boards. This is distinct from:

  • copy-project: Copies from a template project (preserves all fields/views)
  • update-project: Updates/creates projects (smart management)
  • create-project: Creates new empty projects (campaigns)

The distinction clarifies the use case: campaign-generator creates new empty projects, while campaign orchestrators update existing projects with items and fields.

Flexibility: The campaign generator now dynamically determines the project owner using github.owner, allowing it to work with any repository owner (organization or user) based on the provided token permissions.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

@mnkiefer mnkiefer marked this pull request as ready for review January 8, 2026 14:35
Copilot AI changed the title [WIP] Update campaigns to use create project instead of copy project Use update-project with create_if_missing instead of copy-project for campaigns Jan 8, 2026
Copilot AI requested a review from mnkiefer January 8, 2026 14:37
@pelikhan
Copy link
Contributor

pelikhan commented Jan 8, 2026

You want update or create project?

@mnkiefer
Copy link
Contributor

mnkiefer commented Jan 8, 2026

You want update or create project?

Here, we create_project (campaign generator). The campaign itself does update_project for adding items to the board, filling fields, etc. (campaign orchestrator).

@mnkiefer
Copy link
Contributor

mnkiefer commented Jan 8, 2026

@copilot: Use create_project, not update-project.

- Created new create-project safe output type
- Added Go backend configuration (create_project.go)
- Created JavaScript implementation (create_project.cjs)
- Added schema validation and tool definitions
- Updated campaign-generator.md to use create-project
- Removed copy from template, now creates empty projects
- All tests pass

Co-authored-by: mnkiefer <[email protected]>
Copy link
Contributor Author

Copilot AI commented Jan 8, 2026

@copilot: Use create_project, not update-project.

Done! Created a new create-project safe output (commit 13f2356).

The distinction is now clear:

  • create-project: Creates new empty project boards (campaign generator)
  • update-project: Updates existing projects with items/fields (campaign orchestrators)

Campaign generator now uses create_project() to create empty boards instead of copying from a template.

Copilot AI changed the title Use update-project with create_if_missing instead of copy-project for campaigns Implement create-project safe output for campaigns Jan 8, 2026
@mnkiefer
Copy link
Contributor

mnkiefer commented Jan 8, 2026

@copilot: Depending on the token provided, we can create user-owned or org-owned projects. Remove hardcoded org "githubnext".

mnkiefer and others added 2 commits January 8, 2026 16:20
- Removed target-owner: "githubnext" from frontmatter
- Updated instructions to use github.owner dynamically
- Changed item_url to construct from allowed expressions
- Now supports both user and org projects based on token

Co-authored-by: mnkiefer <[email protected]>
Copy link
Contributor Author

Copilot AI commented Jan 8, 2026

@copilot: Depending on the token provided, we can create user-owned or org-owned projects. Remove hardcoded org "githubnext".

Done! Removed hardcoded "githubnext" organization (commit c9c37fb).

Changes:

  • Removed target-owner: "githubnext" from frontmatter
  • Agent now uses ${{ github.owner }} to dynamically determine project owner
  • Supports both user-owned and org-owned projects based on token permissions
  • Item URL constructed from allowed expressions: ${{ github.server_url }}/${{ github.repository }}/issues/${{ github.event.issue.number }}

The workflow is now flexible and works with any repository owner.

@mnkiefer mnkiefer merged commit 22a13db into main Jan 8, 2026
42 of 45 checks passed
@mnkiefer mnkiefer deleted the copilot/update-campaigns-to-create-projects branch January 8, 2026 15:38
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.

3 participants