cangjie-macro-build

Compile and build Cangjie macro packages using cjc and cjpm.

2|Updated Mar 10, 2026
One-click install
npx skills add https://github.com/zhenzhizhi12/NexusAgent --skill cangjie-macro-build-zhenzhizhi12
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cangjie-macro-build
Source: https://github.com/zhenzhizhi12/NexusAgent/tree/main/.opencode/skills/common-skill-l1/macro_build
Command: npx skills add https://github.com/zhenzhizhi12/NexusAgent --skill cangjie-macro-build-zhenzhizhi12

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides comprehensive guidance on compiling and building macro packages within the Cangjie language ecosystem, addressing common challenges in dependency management and build processes.

Core Features & Use Cases

  • Macro Package Compilation: Learn to use cjc --compile-macro for compiling macro packages.
  • Project Structure: Understand the recommended project layout for macro modules using cjpm.toml.
  • Dependency Management: Effectively manage dependencies between macro packages and regular packages.
  • Advanced Features: Explore parallel macro expansion and debugging modes for enhanced development.
  • Use Case: When developing a new Cangjie library that utilizes macros, this Skill will guide you through setting up the project, compiling the macro components, and integrating them with your main application.

Quick Start

Use the cangjie-macro-build skill to compile the macro package located in the 'macros/m.cj' directory and then compile the calling package 'src/demo.cj' linking against the compiled macros.

Frequently Asked Questions about cangjie-macro-build

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

FAQPage Schema
How do I compile Cangjie macro packages using cjc?

To compile Cangjie macro packages, use the `cjc` compiler with the `--compile-macro` flag to build macro modules before linking them with your main application.

What is the recommended project structure for Cangjie macro modules?

The recommended project structure for Cangjie macro modules uses `cjpm.toml` to manage configurations, separating macro packages like `macros/m.cj` from calling packages like `src/demo.cj`.

How does cjpm manage dependencies for multi-module Cangjie macro projects?

`cjpm` manages multi-module Cangjie macro project dependencies by configuring package relationships in `cjpm.toml`, ensuring compiled macro packages correctly link with regular packages.

Can I use parallel macro expansion and debugging modes in Cangjie?

Yes, Cangjie supports advanced features like parallel macro expansion and debugging modes to enhance macro development and build performance within the compilation workflow.

What are the platform-specific considerations when building Cangjie macros?

Building Cangjie macros requires addressing platform-specific considerations during the `cjc --compile-macro` process to ensure proper compilation and integration across different environments.