write-coding-standards-from-file
Was er macht
Dieses Tool erstellt ein Coding-Standards-Dokument für dein Projekt. Es analysiert eine bestehende Code-Datei, um Stilregeln und Richtlinien für dein Projekt festzulegen.
Wann du ihn nutzt
- ✓Wenn du ein neues Projekt startest und einen Styleguide festlegen möchtest.
- ✓Wenn du sicherstellen willst, dass sich alle im Team an dieselben Coding-Regeln halten.
- ✓Wenn du die besten Coding-Praktiken für dein Projekt dokumentieren möchtest.
Link zum Skill
https://github.com/github/awesome-copilot/blob/main/skills/write-coding-standards-from-file/SKILL.mdKopiere ihn und füge ihn in deine KI ein (Claude, ChatGPT oder Cursor) mit der Bitte, den Anweisungen zu folgen.
So nutzt du ihn
Am einfachsten: Kopiere die Nachricht und füge sie in deine KI ein. Sie liest den Skill und folgt den Anweisungen.
Fertige Nachricht zum Einfügen
Für Claude Code, Codex oder Cursor: Führe den Befehl in deinem Projektordner aus, dann wird der Skill installiert.
Lade die SKILL.md herunter und lege sie in den Skills-Ordner deines Agenten.
Beispielanfrage an deine KI
“Erstelle einen Coding-Styleguide auf Basis der Datei 'my_code.py'.”
5 neue Skills pro Woche. 1 Minute Lesezeit.
So funktioniert es
Das Tool liest eine Code-Datei, die du bereitstellst. Es erkennt den verwendeten Coding-Stil (zum Beispiel Einrückungen und Variablennamen) und erstellt ein Dokument mit diesen Regeln, damit andere sich daran halten können.
Technischer Inhalt (originale SKILL.md)
Originaltext des Autors, auf Englisch, direkt von GitHub.
Write Coding Standards From File
Use the existing syntax of the file(s) to establish the standards and style guides for the project. If more than one file or a folder is passed, loop through each file or files in the folder, appending the file's data to temporary memory or a file, then when complete use temporary data as a single instance; as if it were the file name to base the standards and style guideline on.
Rules and Configuration
Below is a set of quasi-configuration boolean and string[] variables. Conditions for handling true, or other values for each variable are under the level two heading ## Variable and Parameter Configuration Conditions.
Parameters for the prompt have a text definition. There is one required parameter ${fileName}, and several optional parameters ${folderName}, ${instructions}, and any [configVariableAsParameter].
Configuration Variables
- addStandardsTest = false;
- addToREADME = false;
- addToREADMEInsertions = ["atBegin", "middle", "beforeEnd", "bestFitUsingContext"];
- Default to beforeEnd.
- createNewFile = true;
- fetchStyleURL = true;
- findInconsistencies = true;
- fixInconsistencies = true;
- newFileName = ["CONTRIBUTING.md", "STYLE.md", "CODE_OF_CONDUCT.md", "CODING_STANDARDS.md", "DEVELOPING.md", "CONTRIBUTION_GUIDE.md", "GUIDELINES.md", "PROJECT_STANDARDS.md", "BEST_PRACTICES.md", "HACKING.md"];
- For each file in
${newFileName}, if file does not exist, use that file name andbreak, else continue to next file name of${newFileName}.
- For each file in
- outputSpecToPrompt = false;
- useTemplate = "verbose"; // or "v"
- Possible values are
[["v", "verbose"], ["m", "minimal"], ["b", "best fit"], ["custom"]]. - Selects one of the two example templates at the bottom of prompt file under the level two heading
## Coding Standards Templates, or use another composition that is a better fit. - If custom, then apply per request.
- Possible values are
Configuration Variables as Prompt Parameters
If any of the variable names are passed to prompt as-is, or as a similar but clearly related text value, then override the default variable value with the value passed to prompt.
Prompt Parameters
- fileName = The name of the file that will be analyzed in terms of: indentation, variable naming, commenting, conditional procedures, functional procedures, and other syntax related data for the coding language of the file.
- folderName = The name of the folder that will be used to extract data from multiple files into one aggregated dataset that will be analyzed in terms of: indentation, variable naming, commenting, conditional procedures, functional procedures, and other syntax related data for the coding language of the files.
- instructions = Additional instructions, rules, and procedures that will be provided for unique cases.
- [configVariableAsParameter] = If passed will override the default state of the configuration variable. Example:
- useTemplate = If passed will override the configuration
${useTemplate}default. Values are[["v", "verbose"], ["m", "minimal"], ["b", "best fit"]].
- useTemplate = If passed will override the configuration
Required and Optional Parameters
- fileName - required
- folderName - optional
- instructions - optional
- [configVariableAsParameter] - optional
Variable and Parameter Configuration Conditions
${fileName}.length > 1 || ${folderName} != undefined
- If true, toggle
${fixInconsistencies}to false.
${addToREADME} == true
- Insert the coding standards into the
README.mdinstead of outputting to the prompt or creating a new file. - If true, toggle both
${createNewFile}and${outputSpecToPrompt}to false.
${addToREADMEInsertions} == "atBegin"
- If
${addToREADME}is true, then insert the coding standards data at the beginning of theREADME.mdfile after the title.
${addToREADMEInsertions} == "middle"
- If
${addToREADME}is true, then insert the coding standards data at the middle of theREADME.mdfile, changing the standards title heading to match that of theREADME.mdcomposition.
${addToREADMEInsertions} == "beforeEnd"
- If
${addToREADME}is true, then insert the coding standards data at the end of theREADME.mdfile, inserting a new line after the last character, then inserting the data on a new line.
${addToREADMEInsertions} == "bestFitUsingContext"
…
Häufige Fragen
Was passiert, wenn ich mehrere Dateien angebe?
Wenn du mehrere Dateien oder einen ganzen Ordner angibst, kombiniert das Tool die Informationen aus allen und erstellt daraus einen einzigen Satz an Coding-Standards.
Kann ich eigene Anweisungen hinzufügen?
Ja, du kannst zusätzliche Anweisungen für bestimmte Fälle ergänzen, zum Beispiel bestimmte Namenskonventionen oder Formatierungsregeln.
Kann das Tool gefundene Probleme auch beheben?
Ja, wenn es entsprechend konfiguriert ist, kann das Tool Inkonsistenzen im Code finden und so korrigieren, dass sie den festgelegten Standards entsprechen.
Details
Originalbeschreibung des Autors
Write a coding standards document for a project using the coding styles from the file(s) and/or folder(s) passed as arguments in the prompt.
repo: github/awesome-copilot
Beliebtheit
- GitHub-Sterne
- 40k
- Platz im Ranking
- #7482
- Lizenz
- MIT
- Aktualisiert
- 15.10.2026
Kommentare
- …
Weitere Skills aus diesem Repository
acquire-codebase-knowledge
40kHilft deinem Agenten, ein bestehendes Code-Projekt zu verstehen und zu dokumentieren. Nützlich, um neue Teammitglieder einzuarbeiten oder die Architektur zu überblicken.
acreadiness-assess
40kErmöglicht deinem Agenten, die KI-Tauglichkeit eines Projekts zu prüfen und einen Bericht zu erstellen. So siehst du, wie gut das Projekt auf KI-Tools vorbereitet ist.
acreadiness-generate-instructions
40kHilft deinem Agenten, auf Basis einer Prüfung Anweisungen für KI-Tools zu erstellen. So arbeitet die KI besser mit dem Code und erkannte Lücken werden geschlossen.
acreadiness-policy
40kErmöglicht deinem Agenten, Richtlinien für die Bewertung von KI-Projekten festzulegen oder anzuwenden. So werden Projekte einheitlich geprüft und Vorgaben eingehalten.
Ähnliche Skills
obsidian-vault-maintainer
394kHilft deinem Agenten, einen Obsidian-tauglichen Gedächtnis-Vault ordentlich zu halten, mit funktionierenden Wiki-Links, einheitlichen Eigenschaften und sicheren generierten Abschnitten.
wiki-maintainer
394kHilft deinem Agenten, ein OpenClaw-Gedächtnis-Wiki mit wiederholbaren Seiten, sicheren verwalteten Blöcken und Prüfungen auf Widersprüche oder Lücken zu pflegen.
obsidian
394kLässt deinen Agenten Obsidian-Notizen, Aufgaben, Links und Eigenschaften mit der offiziellen Obsidian-Kommandozeile lesen, durchsuchen, erstellen und bearbeiten.