using-cmhg

Clarify CMHG and CMunge syntax for RISC OS module development.

3|Updated Apr 10, 2026
One-click install
npx skills add https://github.com/gerph/riscos-agent-skills --skill using-cmhg
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: using-cmhg
Source: https://github.com/gerph/riscos-agent-skills/tree/main/skills/using-cmhg
Command: npx skills add https://github.com/gerph/riscos-agent-skills --skill using-cmhg

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

CMHG/CMunge configuration knowledge is scattered; this skill consolidates essential CMHG directives and their usage for reliable RISC OS module development.

Core Features & Use Cases

  • Directive reference: Quick explanations of title-string, help-string, initialisation-code, and veneer directives.
  • Practical guidance: How to structure a CMHG file, with examples and best practices.
  • References and context: Links to referenced syntax and vector-traps documentation to deepen understanding.

Quick Start

Create a CMHG header for a new RISC OS module using CMunge directives described in this skill.

Frequently Asked Questions about using-cmhg

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

FAQPage Schema
How do I structure a CMHG file for a RISC OS module?

CMHG files use directives like title-string, help-string, and initialisation-code to define RISC OS module components. Apply CMunge syntax to generate the required headers and veneers for ROM or loadable modules.

What are CMHG vector directives used for in RISC OS module development?

CMHG vector directives define vector-traps to intercept system vectors in RISC OS modules. They generate veneer code allowing your module to hook into OS functionality safely.

When do I need CMunge to create headers for ROM modules?

Use CMunge when creating headers for ROM or loadable modules requiring standard entry points. It processes CMHG files to generate C headers and assembly veneers for module initialization.

What is the difference between title-string and help-string directives in CMHG?

The title-string directive defines the module's internal registered OS name, while the help-string provides user-facing text displayed by the OS help system. Both are required in CMHG configuration.

Does CMunge support debugging initialisation-code directives for RISC OS modules?

CMunge supports debugging initialisation-code directives by generating veneers allowing module initialization routines to return errors properly. Reference documentation clarifies syntax for error handling and startup.

Why is my CMHG header not generating correctly with CMunge?

CMHG headers fail to generate when directive syntax is malformed or required directives like title-string are missing. Verify your CMHG file structure against directive references and ensure proper formatting.