{"id":"1cd45486-208e-4f19-9efd-fbaca87002f0","shortId":"cCqsAP","kind":"skill","title":"cli-just","tagline":"This skill should be used when the user asks to \"create a justfile\", \"write just recipes\", \"configure just settings\", \"add just modules\", \"use just attributes\", \"set up task automation\", mentions justfile, just command runner, or task automation with just.","description":"# Just Command Runner\n\n## Overview\n\nExpert guidance for Just, a command runner with syntax inspired by make. Use this skill for creating justfiles, writing recipes, configuring settings, and implementing task automation workflows.\n\n**Key capabilities:**\n\n- Create and organize justfiles with proper structure\n- Write recipes with attributes, dependencies, and parameters\n- Configure settings for shell, modules, and imports\n- Use built-in constants for terminal formatting\n- Implement check/write patterns for code quality tools\n\n## Quick Reference\n\n### Essential Settings\n\n```just\nset allow-duplicate-recipes       # Allow recipes to override imported ones\nset allow-duplicate-variables     # Allow variables to override imported ones\nset shell := [\"bash\", \"-euo\", \"pipefail\", \"-c\"]  # Strict bash with error handling\nset unstable                      # Enable unstable features (user-defined functions, eager keyword)\nset dotenv-load                   # Auto-load .env file\nset positional-arguments          # Pass recipe args as $1, $2, etc.\nset lazy                          # Defer evaluation of unused variables (v1.48.0+)\nset no-cd                         # Don't change to justfile directory for any recipe (v1.51.0+)\n```\n\n### Common Attributes\n\n| Attribute                  | Purpose                                                           |\n| -------------------------- | ----------------------------------------------------------------- |\n| `[arg(\"p\", long, ...)]`    | Configure parameter as `--flag` option (v1.46)                    |\n| `[arg(\"p\", pattern=\"…\")]`  | Constrain parameter to match regex pattern                        |\n| `[confirm(\"prompt\")]`      | Require user confirmation (expressions OK as of v1.49)            |\n| `[doc(\"text\")]`            | Override recipe documentation                                     |\n| `[env(\"NAME\", \"VALUE\")]`   | Set env var for this recipe only (v1.47+, expr v1.51)             |\n| `[group(\"name\")]`          | Group recipes in `just --list` output                             |\n| `[linux]` / `[macos]` …    | Restrict to OS; also `[freebsd]/[netbsd]/[dragonflybsd]` (v1.47+) |\n| `[no-cd]`                  | Don't change to justfile directory                                |\n| `[parallel]`               | Run direct dependencies concurrently                              |\n| `[positional-arguments]`   | Enable positional args for this recipe only                       |\n| `[private]`                | Hide from `just --list` (same as `_` prefix)                      |\n| `[script]`                 | Execute recipe as single script block                             |\n| `[script(\"interpreter\")]`  | Use specific interpreter (bash, python, etc.)                     |\n| `[working-directory: \"…\"]` | Run from given path (expressions OK as of v1.51)                  |\n\n### Recipe Argument Flags (v1.46.0+)\n\nThe `[arg()]` attribute configures parameters as CLI-style options:\n\n```just\n# Long option (--target)\n[arg(\"target\", long)]\nbuild target:\n    cargo build --target {{ target }}\n\n# Short option (-v)\n[arg(\"verbose\", short=\"v\")]\nrun verbose=\"false\":\n    echo \"Verbose: {{ verbose }}\"\n\n# Combined long + short\n[arg(\"output\", long, short=\"o\")]\ncompile output:\n    gcc main.c -o {{ output }}\n\n# Flag without value (presence sets to \"true\")\n[arg(\"release\", long, value=\"true\")]\nbuild release=\"false\":\n    cargo build {{ if release == \"true\" { \"--release\" } else { \"\" } }}\n\n# Help string (shown in `just --usage`)\n[arg(\"target\", long, help=\"Build target architecture\")]\nbuild target:\n    cargo build --target {{ target }}\n```\n\n**Usage examples:**\n\n```bash\njust build --target x86_64\njust build --target=x86_64\njust compile -o main\njust build --release\njust --usage build    # Show recipe argument help\n```\n\nMultiple attributes can be combined:\n\n```just\n[no-cd, private]\n[group(\"checks\")]\nrecipe:\n    echo \"hello\"\n```\n\n### Built-in Constants\n\nTerminal formatting constants are globally available (no definition needed):\n\n| Constant                                            | Description                                |\n| --------------------------------------------------- | ------------------------------------------ |\n| `CYAN`, `GREEN`, `RED`, `YELLOW`, `BLUE`, `MAGENTA` | Text colors                                |\n| `BOLD`, `ITALIC`, `UNDERLINE`, `STRIKETHROUGH`      | Text styles                                |\n| `NORMAL`                                            | Reset formatting                           |\n| `BG_*`                                              | Background colors (BG_RED, BG_GREEN, etc.) |\n| `HEX`, `HEXLOWER`                                   | Hexadecimal digits                         |\n\nUsage:\n\n```just\n@status:\n    echo -e '{{ GREEN }}Success!{{ NORMAL }}'\n    echo -e '{{ BOLD + CYAN }}Building...{{ NORMAL }}'\n```\n\n### Key Functions\n\n```just\n# Require executable exists (fails recipe if not found)\njq := require(\"jq\")\n\n# Get environment variable with default\nlog_level := env(\"LOG_LEVEL\", \"info\")\n\n# Get justfile directory path\nroot := justfile_dir()\n\n# Module location (v1.49.0–1.50.0; useful inside `mod` files)\nmod_path := module_path()            # Full submodule path, e.g. \"foo::bar\"\nmod_file := module_file()            # Absolute path to module's justfile\nmod_dir := module_directory()        # Directory containing the module justfile\n\n# Runtime directory (v1.49.0; typically $XDG_RUNTIME_DIR, falls back to tempdir)\nrt := runtime_directory()\n```\n\n### User-Defined Functions (v1.49.0+)\n\nDefine reusable named expressions with `name(args) := expression`. Requires `set unstable`. Functions can reference module-level assignments.\n\n```just\nset unstable\n\nbase := \"foo\"\njoin(extension) := base + \".\" + extension\n\n# Use f-strings for interpolation\nhello(name) := f\"Hello, {{ name }}!\"\n\ncreate:\n    touch {{ join(\"c\") }}\n    touch {{ join(\"html\") }}\n    echo '{{ hello(\"World\") }}'\n```\n\nUse these to dedupe expression logic that would otherwise repeat across recipes; prefer them over backtick-evaluated variables when the value depends on input.\n\n## Recipe Patterns\n\nWhen designing recipes that use status reporting, check/write semantics, or alias conventions, see [references/patterns.md](references/patterns.md).\n\n## Inline Scripts\n\nWhen writing recipes that need shell scripts (script attribute or shebang style), see [references/inline-scripts.md](references/inline-scripts.md).\n\n## Modules & Imports\n\n### Import Pattern\n\nInclude recipes from another file:\n\n```just\nimport \"./just/settings.just\"\nimport \"./just/base.just\"\nimport? \"./local.just\"    # Optional (no error if missing)\n```\n\n### Module Pattern\n\nLoad submodule (requires `set unstable`):\n\n```just\nmod foo                   # Loads foo.just or foo/justfile\nmod bar \"path/to/bar\"     # Custom path\nmod? optional             # Optional module\n\n# Call module recipes\njust foo::build\n```\n\n### Devkit Import Pattern\n\nFor projects using `@sablier/devkit`:\n\n```just\nimport \"./node_modules/@sablier/devkit/just/base.just\"\nimport \"./node_modules/@sablier/devkit/just/npm.just\"\n```\n\n## Section Organization\n\nStandard section header format:\n\n```just\n# ---------------------------------------------------------------------------- #\n#                                 DEPENDENCIES                                 #\n# ---------------------------------------------------------------------------- #\n```\n\nCommon sections (in order):\n\n1. **DEPENDENCIES** - Required tools with URLs\n2. **CONSTANTS** - Glob patterns, environment vars\n3. **RECIPES / COMMANDS** - Main entry points\n4. **CHECKS** - Code quality recipes\n5. **UTILITIES / INTERNAL HELPERS** - Private helpers\n\n## Default Recipe\n\nAlways define a default recipe:\n\n```just\n# Show available commands\ndefault:\n    @just --list\n```\n\n## Dependencies Declaration\n\nDocument required tools at the top:\n\n```just\n# ---------------------------------------------------------------------------- #\n#                                 DEPENDENCIES                                 #\n# ---------------------------------------------------------------------------- #\n\n# Bun: https://bun.sh\nbun := require(\"bun\")\n\n# Ni: https://github.com/antfu-collective/ni\nna := require(\"na\")\nni := require(\"ni\")\nnlx := require(\"nlx\")\n\n# Usage: invoke directly in recipes (not with interpolation)\nbuild:\n    bun next build\n```\n\n**Note:** `require()` validates the tool exists at recipe evaluation time. Use the variable name directly (e.g., `bun`), not with interpolation (`{{ bun }}`).\n\n## Context7 Fallback\n\nFor Just features not covered in this skill (new attributes, advanced functions, edge cases), fetch the latest documentation:\n\n```\nUse context7 MCP with library ID `/websites/just_systems_man_en` to get up-to-date Just documentation.\n```\n\nExample topics to search:\n\n- `modules import mod` - Module system details\n- `settings` - All available settings\n- `attributes` - Recipe attributes\n- `functions` - Built-in functions\n- `script recipes` - Script block syntax\n\n## Additional Resources\n\n### Reference Files\n\nFor detailed patterns and comprehensive coverage, consult:\n\n- **[`references/settings.md`](references/settings.md)** - Settings configuration and module system\n- **[`references/recipes.md`](references/recipes.md)** - Recipe attributes, parameters, dependencies, and prefixes\n- **[`references/syntax.md`](references/syntax.md)** - Constants, functions, variables, and CLI options\n- **[`references/patterns.md`](references/patterns.md)** - Established conventions, section organization, helper patterns\n\n### Example Templates\n\nWorking justfile templates in `examples/`:\n\n- **[`devkit.just`](examples/devkit.just)** - Minimal template importing @sablier/devkit\n- **[`standalone.just`](examples/standalone.just)** - Full standalone template with all patterns\n\n### External Documentation\n\n- **Official Manual**: https://just.systems/man/en/\n- **GitHub Repository**: https://github.com/casey/just\n- **Context7 Library ID**: `/websites/just_systems_man_en`\n\n## No Justfile Formatter\n\nDo not use `just --fmt` or `just --dump`. The user has bespoke formatting preferences that the built-in formatter does not respect. Preserve existing formatting as-is.\n\n## Tips\n\n1. Use `@` prefix to suppress command echo: `@echo \"quiet\"`\n2. Use `+` for variadic parameters: `test +args`\n3. Use `*` for optional variadic: `build *flags`\n4. Quote glob patterns in variables: `GLOBS := \"\\\"**/*.json\\\"\"`\n5. Use `[no-cd]` in monorepos to stay in current directory\n6. Private recipes start with `_` or use `[private]`\n7. Always define aliases after recipe names for discoverability","tags":["cli","just","agent","skills","paulrberg","agent-skills","ai-agents"],"capabilities":["skill","source-paulrberg","skill-cli-just","topic-agent-skills","topic-ai-agents"],"categories":["agent-skills"],"synonyms":[],"warnings":[],"endpointUrl":"https://skills.sh/PaulRBerg/agent-skills/cli-just","protocol":"skill","transport":"skills-sh","auth":{"type":"none","details":{"cli":"npx skills add PaulRBerg/agent-skills","source_repo":"https://github.com/PaulRBerg/agent-skills","install_from":"skills.sh"}},"qualityScore":"0.478","qualityRationale":"deterministic score 0.48 from registry signals: · indexed on github topic:agent-skills · 56 github stars · SKILL.md body (10,555 chars)","verified":false,"liveness":"unknown","lastLivenessCheck":null,"agentReviews":{"count":0,"score_avg":null,"cost_usd_avg":null,"success_rate":null,"latency_p50_ms":null,"narrative_summary":null,"summary_updated_at":null},"enrichmentModel":"deterministic:skill-github:v1","enrichmentVersion":1,"enrichedAt":"2026-05-18T18:57:35.606Z","embedding":null,"createdAt":"2026-04-18T22:17:36.841Z","updatedAt":"2026-05-18T18:57:35.606Z","lastSeenAt":"2026-05-18T18:57:35.606Z","tsv":"'/antfu-collective/ni':857 '/casey/just':1036 '/just/base.just':733 '/just/settings.just':731 '/local.just':735 '/man/en/':1031 '/node_modules':779,782 '/websites/just_systems_man_en':926,1040 '1':178,796,1074 '1.50.0':560 '2':179,802,1083 '3':808,1090 '4':814,1097 '5':819,1105 '6':1117 '64':432,437 '7':1125 'absolut':579 'across':671 'add':23 'addit':962 'advanc':912 'alia':698 'alias':1128 'allow':119,122,130,133 'allow-duplicate-recip':118 'allow-duplicate-vari':129 'also':266 'alway':827,1126 'anoth':727 'architectur':418 'arg':176,207,216,290,335,348,360,373,391,412,619,1089 'argument':173,287,331,450 'as-i':1070 'ask':12 'assign':630 'attribut':28,86,204,205,336,453,713,911,949,951,983 'auto':166 'auto-load':165 'autom':32,40,72 'avail':476,834,947 'back':602 'background':500 'backtick':677 'backtick-evalu':676 'bar':574,756 'base':634,638 'bash':141,146,315,427 'bespok':1055 'bg':499,502,504 'block':309,960 'blue':486 'bold':490,521 'build':351,354,396,400,416,419,422,429,434,443,447,523,769,875,878,1095 'built':99,468,954,1061 'built-in':98,467,953,1060 'bun':849,851,853,876,895,899 'bun.sh':850 'c':144,654 'call':764 'capabl':75 'cargo':353,399,421 'case':915 'cd':192,273,460,1109 'chang':195,276 'check':463,815 'check/write':106,695 'cli':2,341,994 'cli-just':1 'cli-styl':340 'code':109,816 'color':489,501 'combin':370,456 'command':36,44,52,810,835,1079 'common':203,792 'compil':378,439 'comprehens':970 'concurr':284 'configur':20,67,90,210,337,976 'confirm':225,229 'constant':101,470,473,480,803,990 'constrain':219 'consult':972 'contain':590 'context7':900,921,1037 'convent':699,999 'cover':906 'coverag':971 'creat':14,63,76,651 'current':1115 'custom':758 'cyan':482,522 'date':932 'declar':840 'dedup':664 'default':543,825,830,836 'defer':183 'defin':157,610,613,828,1127 'definit':478 'depend':87,283,683,791,797,839,848,985 'descript':481 'design':689 'detail':944,967 'devkit':770 'devkit.just':1011 'digit':510 'dir':556,586,600 'direct':282,869,893 'directori':198,279,320,552,588,589,595,607,1116 'discover':1133 'doc':235 'document':239,841,919,934,1026 'dotenv':163 'dotenv-load':162 'dragonflybsd':269 'dump':1051 'duplic':120,131 'e':515,520 'e.g':572,894 'eager':159 'echo':367,465,514,519,658,1080,1081 'edg':914 'els':405 'enabl':152,288 'entri':812 'env':168,240,244,546 'environ':540,806 'error':148,738 'essenti':114 'establish':998 'etc':180,317,506 'euo':142 'evalu':184,678,887 'exampl':426,935,1004,1010 'examples/devkit.just':1012 'examples/standalone.just':1018 'execut':304,529 'exist':530,884,1068 'expert':47 'expr':251 'express':230,325,616,620,665 'extens':637,639 'extern':1025 'f':642,648 'f-string':641 'fail':531 'fall':601 'fallback':901 'fals':366,398 'featur':154,904 'fetch':916 'file':169,564,576,578,728,965 'flag':213,332,384,1096 'fmt':1048 'foo':573,635,750,768 'foo.just':752 'foo/justfile':754 'format':104,472,498,789,1056,1069 'formatt':1043,1063 'found':535 'freebsd':267 'full':569,1019 'function':158,526,611,624,913,952,956,991 'gcc':380 'get':539,550,928 'github':1032 'github.com':856,1035 'github.com/antfu-collective/ni':855 'github.com/casey/just':1034 'given':323 'glob':804,1099,1103 'global':475 'green':483,505,516 'group':253,255,462 'guidanc':48 'handl':149 'header':788 'hello':466,646,649,659 'help':406,415,451 'helper':822,824,1002 'hex':507 'hexadecim':509 'hexlow':508 'hide':296 'html':657 'id':925,1039 'implement':70,105 'import':96,126,137,721,722,730,732,734,771,778,781,940,1015 'includ':724 'info':549 'inlin':703 'input':685 'insid':562 'inspir':56 'intern':821 'interpol':645,874,898 'interpret':311,314 'invok':868 'ital':491 'join':636,653,656 'jq':536,538 'json':1104 'just.systems':1030 'just.systems/man/en/':1029 'justfil':16,34,64,79,197,278,551,555,584,593,1007,1042 'key':74,525 'keyword':160 'latest':918 'lazi':182 'level':545,548,629 'librari':924,1038 'linux':261 'list':259,299,838 'load':164,167,743,751 'locat':558 'log':544,547 'logic':666 'long':209,345,350,371,375,393,414 'maco':262 'magenta':487 'main':441,811 'main.c':381 'make':58 'manual':1028 'match':222 'mcp':922 'mention':33 'minim':1013 'miss':740 'mod':563,565,575,585,749,755,760,941 'modul':25,94,557,567,577,582,587,592,628,720,741,763,765,939,942,978 'module-level':627 'monorepo':1111 'multipl':452 'na':858,860 'name':241,254,615,618,647,650,892,1131 'need':479,709 'netbsd':268 'new':910 'next':877 'ni':854,861,863 'nlx':864,866 'no-cd':190,271,458,1107 'normal':496,518,524 'note':879 'o':377,382,440 'offici':1027 'ok':231,326 'one':127,138 'option':214,343,346,358,736,761,762,995,1093 'order':795 'organ':78,785,1001 'os':265 'otherwis':669 'output':260,374,379,383 'overrid':125,136,237 'overview':46 'p':208,217 'parallel':280 'paramet':89,211,220,338,984,1087 'pass':174 'path':324,553,566,568,571,580,759 'path/to/bar':757 'pattern':107,218,224,687,723,742,772,805,968,1003,1024,1100 'pipefail':143 'point':813 'posit':172,286,289 'positional-argu':171,285 'prefer':673,1057 'prefix':302,987,1076 'presenc':387 'preserv':1067 'privat':295,461,823,1118,1124 'project':774 'prompt':226 'proper':81 'purpos':206 'python':316 'qualiti':110,817 'quick':112 'quiet':1082 'quot':1098 'recip':19,66,84,121,123,175,201,238,248,256,293,305,330,449,464,532,672,686,690,707,725,766,809,818,826,831,871,886,950,958,982,1119,1130 'red':484,503 'refer':113,626,964 'references/inline-scripts.md':718,719 'references/patterns.md':701,702,996,997 'references/recipes.md':980,981 'references/settings.md':973,974 'references/syntax.md':988,989 'regex':223 'releas':392,397,402,404,444 'repeat':670 'report':694 'repositori':1033 'requir':227,528,537,621,745,798,842,852,859,862,865,880 'reset':497 'resourc':963 'respect':1066 'restrict':263 'reusabl':614 'root':554 'rt':605 'run':281,321,364 'runner':37,45,53 'runtim':594,599,606 'sablier/devkit':776,1016 'sablier/devkit/just/base.just':780 'sablier/devkit/just/npm.just':783 'script':303,308,310,704,711,712,957,959 'search':938 'section':784,787,793,1000 'see':700,717 'semant':696 'set':22,29,68,91,115,117,128,139,150,161,170,181,189,243,388,622,632,746,945,948,975 'shebang':715 'shell':93,140,710 'short':357,362,372,376 'show':448,833 'shown':408 'singl':307 'skill':5,61,909 'skill-cli-just' 'source-paulrberg' 'specif':313 'standalon':1020 'standalone.just':1017 'standard':786 'start':1120 'status':513,693 'stay':1113 'strict':145 'strikethrough':493 'string':407,643 'structur':82 'style':342,495,716 'submodul':570,744 'success':517 'suppress':1078 'syntax':55,961 'system':943,979 'target':347,349,352,355,356,413,417,420,423,424,430,435 'task':31,39,71 'tempdir':604 'templat':1005,1008,1014,1021 'termin':103,471 'test':1088 'text':236,488,494 'time':888 'tip':1073 'tool':111,799,843,883 'top':846 'topic':936 'topic-agent-skills' 'topic-ai-agents' 'touch':652,655 'true':390,395,403 'typic':597 'underlin':492 'unstabl':151,153,623,633,747 'unus':186 'up-to-d':929 'url':801 'usag':411,425,446,511,867 'use':8,26,59,97,312,561,640,661,692,775,889,920,1046,1075,1084,1091,1106,1123 'user':11,156,228,609,1053 'user-defin':155,608 'util':820 'v':359,363 'v1.46':215 'v1.46.0':333 'v1.47':250,270 'v1.48.0':188 'v1.49':234 'v1.49.0':559,596,612 'v1.51':252,329 'v1.51.0':202 'valid':881 'valu':242,386,394,682 'var':245,807 'variabl':132,134,187,541,679,891,992,1102 'variad':1086,1094 'verbos':361,365,368,369 'without':385 'work':319,1006 'workflow':73 'working-directori':318 'world':660 'would':668 'write':17,65,83,706 'x86':431,436 'xdg':598 'yellow':485","prices":[{"id":"d72a589e-e291-4919-bee5-a66e0c01a7c1","listingId":"1cd45486-208e-4f19-9efd-fbaca87002f0","amountUsd":"0","unit":"free","nativeCurrency":null,"nativeAmount":null,"chain":null,"payTo":null,"paymentMethod":"skill-free","isPrimary":true,"details":{"org":"PaulRBerg","category":"agent-skills","install_from":"skills.sh"},"createdAt":"2026-04-18T22:17:36.841Z"}],"sources":[{"listingId":"1cd45486-208e-4f19-9efd-fbaca87002f0","source":"github","sourceId":"PaulRBerg/agent-skills/cli-just","sourceUrl":"https://github.com/PaulRBerg/agent-skills/tree/main/skills/cli-just","isPrimary":false,"firstSeenAt":"2026-04-18T22:17:36.841Z","lastSeenAt":"2026-05-18T18:57:35.606Z"}],"details":{"listingId":"1cd45486-208e-4f19-9efd-fbaca87002f0","quickStartSnippet":null,"exampleRequest":null,"exampleResponse":null,"schema":null,"openapiUrl":null,"agentsTxtUrl":null,"citations":[],"useCases":[],"bestFor":[],"notFor":[],"kindDetails":{"org":"PaulRBerg","slug":"cli-just","github":{"repo":"PaulRBerg/agent-skills","stars":56,"topics":["agent-skills","ai-agents"],"license":"mit","html_url":"https://github.com/PaulRBerg/agent-skills","pushed_at":"2026-05-17T10:33:19Z","description":"PRB's collection of agent skills","skill_md_sha":"ad6b654f3119e0558d1ebc1841c72b227b447fe8","skill_md_path":"skills/cli-just/SKILL.md","default_branch":"main","skill_tree_url":"https://github.com/PaulRBerg/agent-skills/tree/main/skills/cli-just"},"layout":"multi","source":"github","category":"agent-skills","frontmatter":{"name":"cli-just","description":"This skill should be used when the user asks to \"create a justfile\", \"write just recipes\", \"configure just settings\", \"add just modules\", \"use just attributes\", \"set up task automation\", mentions justfile, just command runner, or task automation with just."},"skills_sh_url":"https://skills.sh/PaulRBerg/agent-skills/cli-just"},"updatedAt":"2026-05-18T18:57:35.606Z"}}