Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/fuwn/suckless-agent-skills/coding-stylenpx skills add Fuwn/suckless-agent-skills --skill coding-stylegit clone --depth 1 https://github.com/Fuwn/suckless-agent-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/fuwn/suckless-agent-skills/coding-style)<a href="https://agentmods.dev/skills/fuwn/suckless-agent-skills/coding-style"><img src="https://agentmods.dev/badge/skills/fuwn/suckless-agent-skills/coding-style.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00026 | $0.01218 |
| Opus 5 | $0.00013 | $0.00609 |
| Sonnet 5 | $0.00005 | $0.00244 |
| Haiku 4.5 | $0.00003 | $0.00122 |
Grade A, and why
coding-style scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 200 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Style
Note that the following are guidelines and the most important aspect of style is consistency. Strive to keep your style consistent with the project on which you are working. It is up to the project maintainer to take some liberty in the style guidelines.
Recommended Reading
The following contain good information, some of which is repeated below, some of which is contradicted below.
- https://man.openbsd.org/style
- http://doc.cat-v.org/bell_labs/pikestyle
- https://www.kernel.org/doc/Documentation/process/coding-style.rst
File Layout
- Comment with LICENSE and possibly short explanation of file/tool.
- Headers
- Macros
- Types
- Function declarations:
- Include variable names.
- For short files these can be left out.
- Group/order in logical manner.
- Global variables.
- Function definitions in same order as declarations.
main
C Features
- Use C99 without extensions (ISO/IEC 9899:1999).
- Use POSIX.1-2008:
- When using gcc define
_POSIX_C_SOURCE 200809L. - Alternatively define
_XOPEN_SOURCE 700.
- When using gcc define
- Do not mix declarations and code.
- Do not use for loop initial declarations.
- Use
/* */for comments, not//. - Variadic macros are acceptable, but remember:
__VA_ARGS__not a named parameter.- Arg list cannot be empty.
Blocks
- All variable declarations at top of block.
{on same line preceded by single space (except functions).}on own line unless continuing statement (if else,do while, ...).
Use block for single statement if inner statement needs a block.
for (;;) {
if (foo) {
bar;
baz;
}
}
Use block if another branch of the same statement needs a block:
if (foo) {
bar;
} else {
baz;
qux;
}
Leading Whitespace
Use tabs for indentation and spaces for alignment. This ensures everything will line up independent of tab size. This means:
- No tabs except beginning of line.
- Use spaces - not tabs - for multiline macros as the indentation level is 0,
where the
#definebegan.
Functions
- Return type and modifiers on own line.
- Function name and argument list on next line. This allows to grep for function
names simply using
grep ^functionname(. - Opening
{on own line (function definitions are a special case of blocks as they cannot be nested). - Functions not used outside translation unit should be declared and defined
static.
Example:
static void
usage(void)
{
eprintf("usage: %s [file ...]\n", argv0);
}
Variables
- Global variables not used outside translation unit should be declared
static. - In declaration of pointers the
*is adjacent to variable name, not type.
Keywords
- Use a space after
if,for,while,switch(they are not function calls). - Do not use a space after the opening
(and before the closing). - Preferably use
()withsizeof. - Do not use a space with
sizeof().
Switch
- Do not indent cases another level.
- Comment cases that FALLTHROUGH.
Example:
switch (value) {
case 0: /* FALLTHROUGH */
case 1:
case 2:
break;
default:
break;
}
Headers
- Place system/libc headers first in alphabetical order.
- If headers must be included in a specific order add a comment to explain.
- Place local headers after an empty line.
- When writing and using local headers.
- Try to avoid cyclic header inclusion dependencies.
- Instead ensure they are included where and when they are needed.
- Read https://talks.golang.org/2012/splash.article#TOC_5.
- Read http://plan9.io/sys/doc/comp.html
User Defined Types
- Do not use
type_tnaming (it is reserved for POSIX and less readable). - Typedef opaque structs.
- Do not typedef builtin types.
- Use
CamelCasefor typedef'd types.
Line Length
- Keep lines to reasonable length (max 79 characters).
Tests and Boolean Values
- Do not use C99
booltypes (stick to integer types). - Otherwise use compound assignment and tests unless the line grows too long:
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 6d ago First seen · 200 lines · 26 tokens per session scan A 0046806f8dc8
coding-style is a skill published in the GitHub repository Fuwn/suckless-agent-skills (18 stars, last pushed 5mo ago), licensed MIT. It adds 26 tokens to every session and 1,218 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
cpp-systems
Modern C++ patterns: RAII and ownership, rule of zero/five, exceptions and error handling, API and ABI boundaries, templates, and CMake tooling. Use when writing, reviewing, refactoring, or debugging C++, working with smart pointers, move semantics, memory leaks, template errors, or gtest. For plain C, see…
cpp
Use when writing modern C++ (17/20/23). Covers RAII, smart-pointer ownership, move semantics, ranges, concepts, and eliminating undefined behavior with sanitizers.
arduino-code-generator
Generate Arduino and embedded C++ snippets for sensors, actuators, buses, state machines, timing, data logging, and hardware abstraction. Use when a user requests implementation code and provide the exact board, framework, toolchain, pins, voltage, memory, and library versions first. Bundled templates target UNO…
add-rcpp-integration
Add Rcpp or RcppArmadillo integration to an R package for high-performance C++ code. Covers setup, writing C++ functions, RcppExports generation, testing compiled code, and debugging. Use when an R function is too slow and profiling confirms a bottleneck, when you need to interface with existing C/C++ libraries, or…
library-selection
Use when selecting, replacing, pinning, or auditing an Arduino, ESP32, RP2040, C++, or vendor-framework library. Compare architecture support, framework and version compatibility, API behavior, footprint, maintenance, provenance, security, and hardware assumptions before installation.
cpp-sanitizers
Use in C/C++ projects for crashes, hangs, UB, data races, memory errors. ASan/UBSan/TSan runtime checks. Build sanitizer config separately.