-
Notifications
You must be signed in to change notification settings - Fork 5
Updated all the files to give more control to the user #12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -1,39 +1,290 @@ | ||||||||||||||||||||||||||||
| # Basic ODK workflow | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| # WORKFLOW: Build Ontology (Quality Control) | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| # Purpose: Builds ontology release assets and performs quality control checks | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # This workflow: | ||||||||||||||||||||||||||||
| # 1. Refreshes imports to ensure consistency | ||||||||||||||||||||||||||||
| # 2. Generates release artifacts (OWL, JSON-LD, Turtle, etc.) | ||||||||||||||||||||||||||||
| # 3. Runs quality control checks (syntax, consistency, etc.) | ||||||||||||||||||||||||||||
| # 4. Commits generated assets back to the repository | ||||||||||||||||||||||||||||
| # 5. Triggers the documentation workflow to continue the chain | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # This is the core build workflow that transforms the edit file | ||||||||||||||||||||||||||||
| # (*-edit.owl) into production-ready ontology releases in multiple formats. | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # Execution Chain Position: | ||||||||||||||||||||||||||||
| # setup-repo → refresh-imports → [BUILD/QC] → docs | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # Read more about ODK builds: | ||||||||||||||||||||||||||||
| # https://github.com/INCATools/ontology-development-kit#building-the-ontology | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||
| name: build | ||||||||||||||||||||||||||||
| name: Build Ontology | ||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||
| # Controls when the action will run. | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| # WORKFLOW TRIGGERS | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| # This workflow can be triggered in three ways: | ||||||||||||||||||||||||||||
| # 1. Via repository_dispatch from refresh-imports workflow (after imports refresh) | ||||||||||||||||||||||||||||
| # 2. Automatically on pushes that modify ontology source files | ||||||||||||||||||||||||||||
| # 3. Manually via workflow_dispatch for forced builds | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # Path filters ensure the workflow only runs when ontology files change, | ||||||||||||||||||||||||||||
| # preventing unnecessary builds on unrelated commits (README, docs, etc.). | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # IMPORTANT: Push triggers skip commits made by github-actions[bot] to prevent | ||||||||||||||||||||||||||||
| # duplicate runs when the workflow chain is triggered via repository_dispatch. | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| on: | ||||||||||||||||||||||||||||
| # Triggers the workflow on push or pull request events but only for the main branch | ||||||||||||||||||||||||||||
| push: | ||||||||||||||||||||||||||||
| branches: ["*"] | ||||||||||||||||||||||||||||
| pull_request: | ||||||||||||||||||||||||||||
| branches: ["*"] | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # TRIGGER 1: Repository Dispatch (from refresh-imports workflow) | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # Listens for 'trigger-qc' event dispatched by refresh-imports.yml | ||||||||||||||||||||||||||||
| # This ensures build runs immediately after imports are refreshed | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| repository_dispatch: | ||||||||||||||||||||||||||||
| types: [trigger-qc] | ||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||
| # Allows you to run this workflow manually from the Actions tab | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # TRIGGER 2: Push Events (for regular development) | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # Triggers when any file in src/ontology/ is modified and pushed | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # Why src/ontology/**? | ||||||||||||||||||||||||||||
| # - Catches changes to edit files, components, imports, metadata | ||||||||||||||||||||||||||||
| # - Ensures builds run after ontology content updates | ||||||||||||||||||||||||||||
| # - Excludes unrelated changes (documentation, root README, etc.) | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # Examples of files that trigger: | ||||||||||||||||||||||||||||
| # - src/ontology/myonto-edit.owl (main edit file) | ||||||||||||||||||||||||||||
| # - src/ontology/components/*.owl (component modules) | ||||||||||||||||||||||||||||
| # - src/ontology/imports/*.owl (import modules) | ||||||||||||||||||||||||||||
| # - src/ontology/Makefile (build configuration) | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # Note: This trigger is skipped for commits made by github-actions[bot] | ||||||||||||||||||||||||||||
| # to prevent duplicate runs when triggered via repository_dispatch | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # push: | ||||||||||||||||||||||||||||
| # branches: ["*"] # Triggers on any branch | ||||||||||||||||||||||||||||
| # paths: | ||||||||||||||||||||||||||||
| # - 'src/ontology/**' | ||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # TRIGGER 3: Pull Request Events (for PR validation) | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # Same as push trigger, but for pull requests | ||||||||||||||||||||||||||||
| # Runs QC checks on PR branches to validate changes before merge | ||||||||||||||||||||||||||||
| # Note: Commits are skipped for PRs (see commit step conditions) | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # pull_request: | ||||||||||||||||||||||||||||
| # branches: ["*"] | ||||||||||||||||||||||||||||
| # paths: | ||||||||||||||||||||||||||||
| # - 'src/ontology/**' | ||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # TRIGGER 4: Manual Trigger (for forced builds) | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # Allows manual execution via GitHub UI | ||||||||||||||||||||||||||||
| # Useful for: | ||||||||||||||||||||||||||||
| # - Testing build process without code changes | ||||||||||||||||||||||||||||
| # - Forcing rebuild after external changes | ||||||||||||||||||||||||||||
| # - Troubleshooting build issues | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| workflow_dispatch: | ||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||
| # A workflow run is made up of one or more jobs that can run sequentially or in parallel | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| # ENVIRONMENT VARIABLES | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| # Global variables available to all jobs in this workflow | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| env: | ||||||||||||||||||||||||||||
| # Default branch for git operations (used in some ODK make targets) | ||||||||||||||||||||||||||||
| DEFAULT_BRANCH: main | ||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| # JOBS | ||||||||||||||||||||||||||||
| # ============================================================================== | ||||||||||||||||||||||||||||
| jobs: | ||||||||||||||||||||||||||||
| # This workflow contains a single job called "ontology_qc" | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # JOB: ontology_qc | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| # Main job that performs the complete build and QC process | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # Process Flow: | ||||||||||||||||||||||||||||
| # 1. Checkout repository with full history | ||||||||||||||||||||||||||||
| # 2. Refresh imports (ensures consistency) | ||||||||||||||||||||||||||||
| # 3. Build all release assets (OWL, JSON-LD, Turtle, etc.) | ||||||||||||||||||||||||||||
| # 4. Commit generated files back to repository | ||||||||||||||||||||||||||||
| # 5. Trigger documentation workflow | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # Container: ODK full image with all build tools | ||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||
| # CRITICAL: Skips workflow for commits made by github-actions[bot] on push | ||||||||||||||||||||||||||||
| # to prevent duplicate runs when triggered via repository_dispatch | ||||||||||||||||||||||||||||
| # ============================================================================ | ||||||||||||||||||||||||||||
| ontology_qc: | ||||||||||||||||||||||||||||
| # The type of runner that the job will run on | ||||||||||||||||||||||||||||
| # Use latest Ubuntu runner for stability | ||||||||||||||||||||||||||||
| runs-on: ubuntu-latest | ||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||
| # CRITICAL: Skip this workflow if triggered by push from github-actions[bot] | ||||||||||||||||||||||||||||
| # This prevents duplicate runs in the workflow chain | ||||||||||||||||||||||||||||
| # The chain uses repository_dispatch, so push triggers from bot commits are redundant | ||||||||||||||||||||||||||||
| # if: | | ||||||||||||||||||||||||||||
| # github.event_name != 'push' || | ||||||||||||||||||||||||||||
| # github.event.head_commit.author.name != 'github-actions[bot]' | ||||||||||||||||||||||||||||
|
Comment on lines
+130
to
+135
|
||||||||||||||||||||||||||||
| # CRITICAL: Skip this workflow if triggered by push from github-actions[bot] | |
| # This prevents duplicate runs in the workflow chain | |
| # The chain uses repository_dispatch, so push triggers from bot commits are redundant | |
| # if: | | |
| # github.event_name != 'push' || | |
| # github.event.head_commit.author.name != 'github-actions[bot]' | |
| # NOTE: The push trigger is currently commented out (see lines 68-72). | |
| # Therefore, the skip logic for bot commits is not needed at this time. | |
| # If the push trigger is re-enabled, uncomment the following 'if:' condition | |
| # to prevent duplicate runs from bot commits: | |
| # if: | | |
| # github.event_name != 'push' || | |
| # github.event.head_commit.author.name != 'github-actions[bot]' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The entire push and pull_request triggers are commented out (lines 68-83), meaning this workflow will only run via
repository_dispatchor manual trigger. This contradicts the extensive documentation describing automatic triggering on file changes. If this is intentional, the comments should be updated to reflect that these triggers are disabled by design. If not, these triggers should be enabled to match the documented behavior.