This repository provides syntax highlighting for Minecraft .mcfunction files in the Micro editor.
It improves readability and helps developers quickly identify commands, selectors, effects, numbers, boolean values, JSON-like arguments, and dangerous commands.
- Minecraft datapack developers
- Function and command script creators
- Micro editor users who want clearer, more readable
.mcfunctionfiles
- Highlight main commands (
effect,execute,give,tp,scoreboard, etc.) - Highlight subcommands / operators (
run,if,matches,modify, etc.) - Highlight selectors (
@s,@e,@a) - Highlight namespaces (
minecraft:wither,minecraft:stone) - Highlight numbers and boolean values (
true,false) - Highlight dangerous commands (
kill @e,tp @e,clear @a) aserror(red in most colorschemes) - Highlight JSON-like arguments (
{"text":"Hello","color":"red"})
git clone https://github.com/BuriXon-code/micro-syntax-mcfunction
cd micro-syntax-mcfunction
mkdir -p $HOME/.config/micro/syntax
cp mcfunction.yaml $HOME/.config/micro/syntax/After installation, open a .mcfunction file in Micro and the syntax highlighting will be applied automatically.
effect give @s minecraft:wither 5 1 true
execute if score @s weapon_random matches 25 run item modify entity @s weapon.mainhand murder_weapon:mark25
kill @e[type=zombie]
effect→ statementgive→ subcommand@s→ selectorminecraft:wither→ identifier- Numbers (
5 1) → numbers true→ boolean / constant- Dangerous commands (
kill @e) → error / red
- This repository only adds syntax highlighting for
.mcfunctionfiles - It does not modify Micro core functionality
- Works on Linux, macOS, Windows, and Termux
- For color customization, adjust your Micro colorscheme (e.g.,
errortoken color for dangerous commands)
