Skip to content

feat: sync-to-forge-core automation + codex API fixes#294

Merged
namastex888 merged 2 commits into
devfrom
fix/codex-api-breaking-changes
Dec 4, 2025
Merged

feat: sync-to-forge-core automation + codex API fixes#294
namastex888 merged 2 commits into
devfrom
fix/codex-api-breaking-changes

Conversation

@namastex888

@namastex888 namastex888 commented Dec 4, 2025

Copy link
Copy Markdown
Contributor

Summary

  • Add sync-to-forge-core.yml workflow that automatically syncs forge-core/ changes when PRs merge to dev
  • Fix .cargo/config.toml codex patches (must always be active, not toggled by dev-core)
  • Update dev-core-off and pre-push hook to only check for forge-core patches, not crates-io patches
  • Remove obsolete Makefile targets (commit-both, push-both, pr)
  • Update dev-help documentation with new automated workflow

New Workflow

Developers now ONLY work in automagik-forge. When PRs merge to dev:

  1. sync-to-forge-core.yml automatically pushes forge-core/ changes to forge-core repo
  2. No manual interaction with forge-core repo needed ever

Test plan

  • Merge this PR
  • Verify sync-to-forge-core workflow triggers
  • Check forge-core repo receives the changes
  • Run bump-rc release workflow

- Remove orphaned dev-core-helper.sh (549 lines, never called)
- Consolidate mode detection to grep ^\[patch\. in config.toml
- Fix push-both and pr targets to use correct detection method
- Inline dev-core-check diagnostics (was delegating to deleted script)
- Update check-versions.sh to use grep-based detection
- Improve dev-help documentation with workflow explanation
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @namastex888, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request refines and simplifies the dev-core development workflow by centralizing how 'dev-core' mode is detected and eliminating outdated or unused helper scripts. The changes enhance the clarity and reliability of cross-repository development commands, ensuring that various make targets and scripts consistently recognize the active development environment. This consolidation reduces technical debt and improves the overall maintainability of the development tooling.

Highlights

  • Code Removal: The orphaned dev-core-helper.sh script, which was never called by the Makefile and contained 549 lines of code, has been completely removed.
  • Dev-Core Mode Detection: The method for detecting 'dev-core' mode has been consolidated to a single, consistent approach: checking for [patch. entries in .cargo/config.toml using grep.
  • Makefile Target Fixes: The push-both and pr Makefile targets have been updated to correctly use the new grep-based dev-core mode detection, resolving an issue where they were checking for a non-existent .dev-core-active file.
  • Inlined Diagnostics: The diagnostics logic for dev-core-check has been inlined directly into the Makefile, removing its dependency on the dev-core-helper.sh script.
  • Script Update: The check-versions.sh script has been updated to also utilize the new grep-based detection for 'dev-core' mode.
  • Documentation Improvement: The dev-help documentation within the Makefile has been significantly improved, providing a comprehensive explanation of the full dev-core workflow, including starting, during development, and pre-PR steps, along with safety notes.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request does a great job of consolidating the dev-core workflow, removing the orphaned dev-core-helper.sh script, and simplifying mode detection. The changes make the developer experience clearer and more robust. My feedback focuses on a few minor areas to further improve the robustness of the new diagnostic scripts and ensure the documentation in dev-help is accurate.

Comment thread Makefile
fi
@if [ -d "forge-core" ]; then \
echo -e "Core dir: $(FONT_GREEN)EXISTS$(FONT_RESET)"; \
echo -e "Branch: $$(cd forge-core && git branch --show-current)"; \

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The command git branch --show-current will output an error message to stderr if the forge-core directory exists but is not a git repository, or if the HEAD is detached. This can be confusing for the user. It's better to suppress the error and provide a fallback message, similar to how it's done for the 'Version' line, to make the health check script more robust.

		echo -e "Branch:   $$(cd forge-core && git branch --show-current 2>/dev/null || echo 'detached HEAD or not a git repo')"; \

Comment thread Makefile Outdated
@echo " make dev-core-status Detailed dev-core status"
@echo " make commit-both Commit to both repos"
@echo " make dev-core-check Health check diagnostics"
@echo " make commit-both MSG='x' Commit to both repos with same message"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The documentation for commit-both suggests it accepts a MSG variable from the command line (MSG='x'). However, the implementation of the commit-both target is interactive and uses read -p to prompt for a commit message. This documentation is misleading. Please update it to reflect the interactive nature of the command.

	@echo "  make commit-both           Commit to both repos with same message (interactive)"

Comment thread scripts/check-versions.sh
Comment on lines +116 to +120
DEV_CORE_ACTIVE=false
if grep -q '^\[patch\.' "$REPO_ROOT/.cargo/config.toml" 2>/dev/null; then
DEV_CORE_ACTIVE=true
fi
if [ "$DEV_CORE_ACTIVE" = "false" ] && [ -n "$UNIQUE_TAGS" ]; then

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

This logic to check for dev-core mode can be simplified. Instead of using a flag variable (DEV_CORE_ACTIVE), you can directly use the grep command's exit code in the if condition. This makes the code more concise and easier to read.

Suggested change
DEV_CORE_ACTIVE=false
if grep -q '^\[patch\.' "$REPO_ROOT/.cargo/config.toml" 2>/dev/null; then
DEV_CORE_ACTIVE=true
fi
if [ "$DEV_CORE_ACTIVE" = "false" ] && [ -n "$UNIQUE_TAGS" ]; then
if ! grep -q '^\[patch\.' "$REPO_ROOT/.cargo/config.toml" 2>/dev/null && [ -n "$UNIQUE_TAGS" ]; then

- Add sync-to-forge-core.yml workflow that auto-syncs forge-core/
  changes when PRs merge to dev
- Fix .cargo/config.toml codex patches (must always be active)
- Update dev-core-off to not touch crates-io patches
- Remove obsolete Makefile targets (commit-both, push-both, pr)
- Update dev-help documentation with new automated workflow

The new workflow means developers only work in automagik-forge.
When PRs merge, forge-core is automatically updated - no manual
interaction with forge-core repo needed.
@namastex888 namastex888 changed the title fix: consolidate dev-core workflow feat: sync-to-forge-core automation + codex API fixes Dec 4, 2025
@namastex888 namastex888 added the rc Release candidate - triggers RC automation label Dec 4, 2025
@namastex888
namastex888 merged commit 100bde4 into dev Dec 4, 2025
1 check failed
@namastex888
namastex888 deleted the fix/codex-api-breaking-changes branch December 4, 2025 19:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

rc Release candidate - triggers RC automation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant