/xwiki:xwiki-doc-writingfrom xwiki
Writes, updates, or reviews XWiki documentation pages following the XWiki Documentation Guide (Diataxis types, style, versioning). Also handles deletion with backlink fixes.
Ships in xwiki. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
This skill is the procedure for producing and reviewing a page in the new /documentation tree.
The rules it applies (Diataxis types, titles/page-names, page-structure fields, style, location,
versioning) are declarative knowledge and live in the KB: read
kb/conventions/documentation.md first — it is the working summary, and it points to the live
XWiki Documentation Guide, which is the evolving source of truth. When a detail is borderline or
missing, consult the live guide and prefer it.
For converting legacy documentation (old Documentation space or the Extensions wiki) into the
new tree, use the xwiki-doc-convert skill instead — it builds on this one.
Well-structured page content in XWiki syntax plus, when reviewing, a list of concrete findings. Documentation pages are wiki pages, not files in a git repo: this skill does not commit files — the developer creates/edits the page on the wiki, usually through a Change Request.
Ask before starting the work, in one go, because each answer changes what you produce and two of them cannot be recovered later (a page saved directly cannot become a Change Request, and a screenshot cannot be taken without a running instance). Ask for authoring, updating and converting.
First look for ~/.xwiki-credentials (test -f, never print it) — when that file exists it
answers question 2, so drop that question. Its format, and how to use it without pulling the password
into the conversation, are in kb/servers/index.md.
Ask the remaining questions in a single AskUserQuestion call so the developer clicks options
instead of typing answers back (fall back to a numbered list in a message only on a host without that
tool). Question headers and options:
Save mode — Change Request or direct save? Change Request (Recommended) for anything but
a genuine minor fix, Save directly for a typo / broken link / small rephrasing (see step "Save"
below and kb/conventions/documentation.md) — but let the developer decide.Credentials — which xwiki.org account to write with, and where to find its credentials?
Create ~/.xwiki-credentials (Recommended) (you re-read the file afterwards), They are
elsewhere (environment variable, password manager entry, ~/.netrc…), Don't save (you
produce the content and the developer pastes it). Without this the whole task stops at the save
step, so it is not a question to leave for the end.Screenshots — is a local XWiki instance running for the screenshots? Yes, I will start
one, No — skip the screenshots. Suggest the Documentation Resources
XARs to get realistic content in it. Pages need images (see kb/conventions/documentation.md),
and xwiki.org itself is not the place to capture them. Don't ask which version it runs —
read it from the xwiki-version header of any /rest response, and check it is recent enough for
the screenshots to show the latest skin. The version is not recorded on the page: putting it in
an image caption is a misuse the guide names explicitly (kb/conventions/documentation.md).Local login — credentials for the local instance: Admin/admin (Recommended), the
default, or Other. These are never the xwiki.org credentials.If the developer declines the local instance, say plainly which images the page will be missing rather than shipping a page with none.
Placement is a fifth question, asked separately — once you know what pages there will be, and
before the first one is created. It is not a yes/no: propose two or three written-out page trees
with their costs and your recommendation, per "Choose the right location" in
kb/conventions/documentation.md. Getting it wrong is a rename/move with backlink handling, not an
edit.
tools/For every new or rewritten page, a single one included, use the scripts in this skill's tools/
directory rather than hand-rolling REST calls (only a minor fix, per step 13, is made by hand): draft
the pages as a pages.py data module, then
python3 tools/docpages.py lint # offline; the mechanical rules of documentation.md
python3 tools/docpages.py save # idempotent publish, every field read back
python3 tools/docpages.py pin # child order, verified via the tree service
python3 tools/docpages.py verify # audit + BOTH doc-checker surfaces
plus tools/docshot.sh and tools/checkredbox.py for screenshots. tools/README.md documents the
page-set contract and, for each step, the silent failure it protects against — a lost 202, an object
write blanked by a #-less field name, a finding that creates no violation object, a red box clipped
into three sides. Read it before writing the first page; the review checklist (see "Review") still
applies to everything a regex cannot decide.
/documentation (avoid duplication).kb/conventions/documentation.md). If it mixes types, split it into several pages. Before
drafting a type you have not written in this session, read the real pages for it listed in
references/live-examples.md to calibrate structure, title style and voice.kb/conventions/documentation.md#Choose the right location. A new
topic is a page of its own, an Explanation (kb/conventions/documentation.md), so a How-to
that opens one brings that topic page with it: put both in the placement proposal.tags/add-page, the title saying "Add a Tag to a Page").xwiki:<extension id>, or empty).
When the extension page's id is empty, completing it is a write to extensions.xwiki.org: propose
the value to the developer (from the module's pom.xml) and save it only on their yes.
Leave Highlights empty unless the page has many children: it is a list of links to the most
important child pages, described by their summaries, not a "key points" summary, and the automatic "More" table already lists
every child — see kb/conventions/documentation.md.kb/conventions/documentation.md → Content rules per type.Since / Version column — version information is a {{version}} badge on the rows that
need one, and only for versions at or after the LTS (step 11). The rule and its exceptions are in
kb/conventions/documentation.md → Content rules per type."quotes" for UI elements, uppercase-first XWiki terminology,
##literals##, link-reference syntax (never hardcoded URLs), {{scm}} for GitHub files, the
code macro with an explicit language, a content fragment to avoid duplication, and no overused
em dashes (use the comma, period, colon or parentheses the sentence needs; quoted text keeps its
dashes).kb/conventions/documentation.md → Show, don't only tell. Capture screenshots on the local
instance agreed above, using the
Documentation Resources
XARs for realistic content.{{image}} macro with an alt and the mandatory size, framed on the element plus the nearest
landmark that locates it and cropped to exactly that size's pixel width, with a red
(255, 0, 0) box around the element concerned, videos in webm displayed with the
{{embed}} macro and never as a link, Gallery for several images, PlantUML for diagrams. See kb/conventions/documentation.md.{{version}} (with before
for changed behavior) only for genuine new/changed behavior. A version is only ever a
{{version}} badge, never bare text and never a table column; and only versions at or after the
current LTS appear at all — anything older is deleted, not badged. The macro strips the
qualifier (since="18.8.0RC1" renders XWiki 18.8.0+), so a Java @since value can be passed to
it verbatim. See kb/conventions/documentation.md.lint decides for you — the sibling How-tos' step 1 and an attachment
name declared by more than one page, which it sees only among the pages of the set, so compare a
lone new page with its siblings by hand — then lay the page's intro next
to its own FAQ, then next to its parent/hub and sibling pages, and hunt for the same fact stated
twice in different words. Each hit: pick one home, and reduce the others to a clause with a link or
delete them. Then cut verbosity: take each sentence and ask does the reader lose something they
need in order to act if I delete it? — if not, delete it rather than compress it. Readers skim, so
length itself hides content. A How-to whose numbered list is wrapped in explanatory paragraphs, and
a hub page that narrates the feature without linking the children it introduces, or lists them bare
(see "A hub page's prose links"), both fail this step.Save mode (a Change
Request is recommended, adding to an existing open one on that page if there is one). A pure typo, broken-link
or small-rephrasing fix is a minor change: save it directly, ticked "minor", with a short
summary — do not open a Change Request for it. See kb/conventions/documentation.md.
Then read any automatic documentation-check violations the save reports.Keep the page a single Diataxis type. Re-check the title/page-name rules if the scope changed. Update for the latest version and prune version macros/content for versions no longer supported. Move any explanation that crept into How-to steps out to the FAQ field or a dedicated Explanation page. An update is also the moment to fix what the page is missing: add the result step if the procedure has none, add the screenshots / code examples / diagram the prose is doing badly, cut the prose the reader does not need, and add the links a hub page owes the pages below it. Review it (see "Review") before saving.
Never delete a page on xwiki.org before listing and handling its backlinks — including a page you
created yourself earlier in the task and then decided to remove. The breakage lands on other pages and
nothing in the delete flow names them for you. Follow kb/conventions/page-deletion.md, which holds
the procedure, what the deletion wizard does and does not repoint, and the triage.
Reviewing a page — when asked to, and on every page you wrote or updated, before step 13 saves it
— means applying references/review-checklist.md to it, page by item. Read that file at that point
each time: lint covers only its mechanical subset.
references/live-examples.md (opens in a new tab)references/review-checklist.md (opens in a new tab)tools/README.md (opens in a new tab)tools/checkredbox.py (opens in a new tab)tools/docpages.py (opens in a new tab)tools/docplan.py (opens in a new tab)tools/docshot.sh (opens in a new tab)tools/xwikidoc.py (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub xwiki/xwiki-dev-llm --plugin xwiki38 skills in this plugin
/xwiki-backportBackport any change (bug fix, feature, refactor, or test) to an older branch of an XWiki repo (xwiki-platform / xwiki-commons / xwiki-rendering / xwiki-contrib). Cherry-pick `-x` the source commit(s) into a worktree, ADAPT the result to the older branch (module pom versions, Java level, `@since` tags, data migration versions and skip ranges, style/API divergence), verify it compiles against that branch, and push / open a PR. Use whenever a commit that exists on one branch needs to be applied to an older/maintenance branch. For the `testneeded`-labelled test sweep use xwiki-backport-testneeded (which builds on this skill); for Maven commands use xwiki-build; for PR/commit conventions use xwiki-pull-request; for the versioning/`@since` conventions (the format and what carries `@since`) use xwiki-knowledge./xwiki-backport-testneededBackport the automated test of one JIRA issue labelled `testneeded` to the currently-supported stable branches, adjust its `@since` tags across all branches, and open the PRs. Use when asked to backport the test of a given testneeded issue, or to catch a stable branch up with a recently-added test. (For several issues at once, the user will say so — then apply this per issue.) This is the test-specific layer on top of xwiki-backport (which owns the generic cherry-pick / adapt-to-branch / verify mechanics — including the mandatory pom-version, Java-version and `@since` checks). For Maven use xwiki-build; for PR/commit conventions use xwiki-pull-request; for the `@since` rules use xwiki-knowledge; for querying JIRA (the testneeded sweep) use xwiki-jira.