Creates article-relative ./snippets/ directories and returns their paths. Use when a snippet workflow needs folders composed from an article path plus caller-selected platform, conflict-avoidance subject, and code-language segments.
75%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
Passed
No findings from the security scan
Fix and improve this skill with Tessl
tessl review fix ./.github/skills/create-snippet-folders/SKILL.mdCreate the requested folders that hold code snippets for one documentation article, and return their paths to the calling workflow. Don't choose the structure, inspect project compatibility, create projects, write example code, or update the article.
Before requesting directories, choose the path segments as follows:
net for .NET 6 or later snippets.framework for .NET Framework snippets.AsyncProgram and SyncProgram when two examples both require a Program.cs file. Otherwise, omit the subject segment.csharp for C# code or vb for Visual Basic code. Omit the language segment only when the caller requests the article's shared snippet root rather than a language-specific directory.Require the calling workflow to provide:
net, framework, or omitted.csharp, vb, or omitted.The caller must decide whether the article requires platform separation, a subject folder to prevent conflicts, and a language folder. If any segment decision is missing, return control to the caller without creating folders. Don't infer missing segments from the article or existing snippets.
For each requested directory:
Use the folder that contains the target article as the base directory.
Use the article filename without .md as {article-name}.
Construct the path in this order:
./snippets/{article-name}/[platform]/[subject]/[language]/
Omit every segment that the caller explicitly marks as omitted. Don't reorder or rename supplied segments.
Create the directory and any missing parent directories. If the directory already exists, leave it and its contents unchanged.
Return the article-relative and repository-relative path, and report whether the directory was created or already existed.
Given docs/core/create-app.md, these inputs produce these paths:
csharp: ./snippets/create-app/csharp/net, subject omitted, language vb: ./snippets/create-app/net/vb/AsyncProgram, language csharp: ./snippets/create-app/AsyncProgram/csharp/./snippets/create-app/The skill treats supplied segments as single safe path components. Validate platform, subject, and language values before creating folders; reject path separators, absolute paths, and ./.. segments.
dotnet/docs
bcbe167
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.