Skip to content

Conversation

Copy link

Copilot AI commented Jan 15, 2026

Implements automated synchronization of workflow files from this repository to all plugin repositories, ensuring consistent build configurations while supporting per-repo customization.

Implementation

Template Files (plugin_build.yml.{dev,nodos-1.3,nodos-1.2})

  • Branch-specific workflow templates with placeholders for repo-specific values
  • Placeholders: __BUILD_NUMBER_OFFSET__, __LINUX_ENABLED__, __WINDOWS_ENABLED__
  • Copied to .github/workflows/build.yml in target repos with substitutions applied

Configuration (repositories.json)

  • Maps 39 repo/branch combinations to their workflow templates
  • Covers 13 plugin repositories across 3 branches each

Sync Script (scripts/update_workflows.py)

  • Clones each target repo/branch
  • Reads .nodos/workflow_config.json from plugin repo (if exists, else defaults)
  • Applies template substitutions
  • Commits and pushes updated workflow file

Automation (.github/workflows/update_workflow.yml)

  • Triggers on changes to templates, configuration, or script
  • Supports manual dispatch with repo/branch filters and dry-run mode

Repository Configuration

Plugin repos can customize via .nodos/workflow_config.json:

{
  "build_number_offset": 500,
  "linux_enabled": true,
  "windows_enabled": false
}

All fields optional; defaults to offset 0, both platforms enabled.

Usage

  • Automatic: Push template changes → all plugin repos update
  • Manual: Actions → Update Plugin Workflows → Run (optionally target specific repo/branch or dry-run)

See WORKFLOW_SYNC_README.md for complete documentation.

Original prompt

Write a plugin_build.yml file(do not put it inside .github folder) that will be used as plugin repositories' workflow file. It will be copied to the plugin repositories when we push a change to the actions repository, so that they are always synced. Make it somewhat templated like, "plugin_buily.yml.nodos-1.3" so that plugins(and their branches) can request different workflow. Also, write a update_workflow.yml workflow file, which updates given repositories' workflow files as I described. The repositories that use plugin_build.yml will be put inside a json file in a format that will say which workflow file they request(the branch name) and their repo url. Multiple branches from the same repo might have different requests so it should handle that too. The file should be renamed to "build.yml" and put inside .github/workflows of the repository on copy. There are also some repo specific inputs, get them from a file inside the repo too(like the build number start index). The file should not be directly on the root folder though. Here is a sample build.yml file from the audio plugin repository:

name: Build

on:
  push:
    branches: [ dev ]
  workflow_dispatch:
    inputs:
      publish_mode:
        description: 'Publish Mode'
        required: true
        default: 'If Changed'
        type: choice
        options:
          - If Changed
          - Force
          - None
      plugin_names:
        description: 'Publish only these plugins (semicolon-delimited) (optional)'
        required: false
        default: ''
        type: string
      run_tests:
        description: 'Run Tests'
        required: false
        default: false
        type: boolean
      clean:
        description: 'Clean build'
        required: false
        default: false
        type: boolean
      sign_binaries:
        description: 'Sign binaries'
        required: false
        default: false
        type: boolean
      linux:
        description: 'Release for Linux'
        required: false
        default: true
        type: boolean
      windows:
        description: 'Release for Windows'
        required: false
        default: true
        type: boolean
      version_check:
        description: 'Version Check'
        required: true
        default: 'strict'
        type: choice
        options:
          - none
          - loose
          - strict

run-name: >-
  ${{ ((github.event_name == 'push') && format('Build Only: {0}', github.event.head_commit.message)) ||
      (github.event.inputs.publish_mode == 'If Changed') && 'Build & Release' || 
      (github.event.inputs.publish_mode == 'Force') && 'Build & Release (Force)' ||
      'Build Only' }}

concurrency:
  group: single
  cancel-in-progress: false

jobs:
  call-release-plugins:
    name: Build
    uses: nodos-dev/actions/.github/workflows/plugins.yml@main
    secrets:
      CI_TOKEN: ${{ secrets.CI_TOKEN }}
      SENTRY_TOKEN: ${{ secrets.SENTRY_TOKEN }}
    with:
      ref_name: ${{ github.ref_name }}
      publish_mode: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.publish_mode || 'None' }}
      plugin_names: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.plugin_names || '' }}
      clean: ${{ github.event_name == 'workflow_dispatch' && fromJson(github.event.inputs.clean) || false }}
      build_number: ${{ github.run_number }}
      sign_binaries: ${{github.event_name == 'workflow_dispatch' && fromJson(github.event.inputs.sign_binaries) || false }}
      linux: ${{ github.event_name == 'workflow_dispatch' && fromJson(github.event.inputs.linux) || github.event_name == 'push' }}
      windows: ${{ github.event_name == 'workflow_dispatch' && fromJson(github.event.inputs.windows) || github.event_name == 'push' }}
      run_tests: ${{ github.event_name == 'workflow_dispatch' && fromJson(github.event.inputs.run_tests) || false }}
      version_check: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.version_check || 'strict' }}

Some plugins don't have linux builds etc. it will be included the file that will be inside the repo too.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI and others added 5 commits January 15, 2026 14:11
Co-authored-by: caner-milko <13199909+caner-milko@users.noreply.github.com>
Co-authored-by: caner-milko <13199909+caner-milko@users.noreply.github.com>
Co-authored-by: caner-milko <13199909+caner-milko@users.noreply.github.com>
…ndling and git auth

Co-authored-by: caner-milko <13199909+caner-milko@users.noreply.github.com>
Co-authored-by: caner-milko <13199909+caner-milko@users.noreply.github.com>
Copilot AI changed the title [WIP] Add plugin build workflow files for repositories Add plugin workflow sync system with templated build files Jan 15, 2026
Copilot AI requested a review from caner-milko January 15, 2026 14:30
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.

2 participants