Skip to content

Workflow directories

Most Git hosts read workflow files from a single directory. If .forgejo/workflows/ exists, .github/workflows/ is ignored entirely. This is a problem for teams that use both GitHub and a self-hosted Git instance, or that migrate incrementally.

Codebahn scans all four workflow directories and merges the results:

  1. .codebahn/workflows/ (highest priority)
  2. .forgejo/workflows/
  3. .gitea/workflows/
  4. .github/workflows/ (lowest priority)

Every .yml and .yaml file found across these directories is included. If the same filename appears in multiple directories, the higher-priority directory wins and the others are skipped for that file.

Given this repository structure:

.codebahn/workflows/
deploy.yml # Codebahn-specific deploy
.forgejo/workflows/
deploy.yml # ignored (same name, lower priority)
lint.yml # included
.github/workflows/
ci.yml # included
lint.yml # ignored (same name, lower priority)

Codebahn runs three workflows: deploy.yml from .codebahn/, lint.yml from .forgejo/, and ci.yml from .github/.

On other Git hosting services that read only one directory, the merge behaviour does not apply. If you need your workflows to work on both Codebahn and another host, keep all workflows in a single directory.