ci-workflow-sync

Synchronize GitHub Actions workflows with Forgejo Actions equivalents for dual-track CI.

29.5k|7.3k|Updated Feb 23, 2023
One-click install
npx skills add https://github.com/labring/FastGPT --skill ci-workflow-sync
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ci-workflow-sync
Source: https://github.com/labring/FastGPT/tree/main/.agents/skills/system/ci-workflow-sync
Command: npx skills add https://github.com/labring/FastGPT --skill ci-workflow-sync

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

FastGPT maintains two parallel CI systems—GitHub Actions for the open-source community and Forgejo Actions for the internal network—and any change to a workflow on one side must be mirrored on the other with platform-specific transformations, which is error-prone when done manually.

Core Features & Use Cases

  • Dual-track workflow synchronization: Detects changes under .github/workflows/ and applies the equivalent update to .forgejo/workflows/, keeping build and test logic functionally identical.
  • Eleven conversion patterns: Covers registry address rewriting, removal of Aliyun/Docker Hub logins, actions/* to forgejo/* action renames, permissions cleanup, intranet proxy and mirror injection, buildx driver-opts, artifact download rewrites, runner matrix defaults, workflow_dispatch version inputs, and github-script removal.
  • Decision tree for new workflows: Determines whether a new GitHub workflow needs a Forgejo counterpart (build/test workflows usually do; preview/docs/helm workflows do not).
  • Use Case: You add a new build-marketplace.yml GitHub workflow that pushes images to ghcr.io. The skill rewrites it for Forgejo: dynamic registry from github.server_url, proxy variables from vars.AB_*, buildkitd config, and per-architecture artifact downloads.

Quick Start

I just modified .github/workflows/build-fastgpt.yml to add a new build argument, please sync the corresponding Forgejo workflow.

Frequently Asked Questions about ci-workflow-sync

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I sync a GitHub Actions workflow to Forgejo Actions?

Read the GitHub workflow, diff it against the existing Forgejo counterpart, then apply the conversion patterns: replace ghcr.io with a dynamic registry from github.server_url, swap actions/* for forgejo/*, inject proxy variables, and rewrite artifact downloads by explicit name.

Which GitHub workflows need a Forgejo Actions equivalent?

Workflows that build OCI images or run unit tests typically need Forgejo versions since the internal network depends on them. Preview deployments, docs builds, helm releases, and issue automation are GitHub-specific and usually do not need syncing.

Does Forgejo Actions support actions/github-script?

No, Forgejo has no github-script equivalent. Steps using it must be deleted or rewritten, such as replacing PR coverage comments with inline node scripts that write to GITHUB_STEP_SUMMARY.

Why does forgejo/download-artifact fail with pattern and merge-multiple?

Forgejo's download-artifact action does not support the pattern or merge-multiple parameters. You must download each artifact by its explicit name in separate steps, optionally adding continue-on-error for missing architectures.

What are common mistakes when converting GitHub workflows to Forgejo?

Common mistakes include copying files directly with ghcr.io hardcoded, keeping Aliyun or Docker Hub login steps, leaving attestation permissions, and hardcoding proxy URLs instead of using vars.AB_* repository variables.