cangjie-cjfmt

Format Cangjie code files and directories using the cjfmt tool.

1|Updated Mar 14, 2026
One-click install
npx skills add https://github.com/SunriseSummer/CangjieDocValidator --skill cangjie-cjfmt
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cangjie-cjfmt
Source: https://github.com/SunriseSummer/CangjieDocValidator/tree/main/.github/skills/cjfmt
Command: npx skills add https://github.com/SunriseSummer/CangjieDocValidator --skill cangjie-cjfmt

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill automates the process of formatting Cangjie code according to established style guides, ensuring consistency and readability across projects.

Core Features & Use Cases

  • Code Formatting: Applies consistent indentation, spacing, and line breaks to Cangjie source files.
  • Configuration: Supports custom formatting rules via TOML configuration files.
  • Use Case: You have a large Cangjie codebase with inconsistent formatting. Use this Skill to automatically reformat all .cj files to adhere to the project's standard style.

Quick Start

Format the Cangjie file located at 'src/main.cj' using the cjfmt skill.

Frequently Asked Questions about cangjie-cjfmt

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

FAQPage Schema
How do I format Cangjie code automatically to enforce style conventions?

Format Cangjie code automatically by running the `cjfmt` tool on single files or entire directories to enforce consistent indentation, spacing, and line breaks for project readability.

Can I apply line-range formatting to a specific Cangjie source file?

Yes, line-range formatting is supported. You can target specific sections of a Cangjie source file rather than the entire document, allowing localized style enforcement without affecting untouched code.

How do I use a custom configuration file for Cangjie code formatting?

You can define custom formatting rules in a TOML configuration file and pass it to the `cjfmt` tool, ensuring the code style adheres to your specific project standards and conventions.

What is the best way to format a large Cangjie codebase with inconsistent styling?

The best way to fix inconsistent formatting is to run directory-wide `cjfmt` processing on all `.cj` files, automatically reformatting the entire Cangjie codebase to match standard style guidelines.

Does Cangjie code formatting support output redirection for logging?

Yes, the `cjfmt` tool supports output redirection options. You can redirect the formatted output to a different destination instead of overwriting the original Cangjie source files directly.