Install
$ agentstack add skill-abhatt-rh-redhat-docs-agent-tools-dita-line-break ✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
About
Line break removal skill
Remove hard line breaks from AsciiDoc files for DITA compatibility.
Overview
This skill uses the line_break.rb Ruby script to find and remove hard line breaks that are not supported in DITA. Hard line breaks in AsciiDoc can be created using:
- A space followed by
+at the end of a line (+) - The
:hardbreaks-option:document attribute - The
%hardbreaksoption on blocks - The
options=hardbreaksattribute
What it removes
Line continuation markers
Before:
This is the first line +
and this continues on a new line.
After:
This is the first line and this continues on a new line.
Document-level hardbreaks attribute
Before:
:hardbreaks-option:
This text has
forced line breaks
everywhere.
After:
This text has forced line breaks everywhere.
Block-level hardbreaks option
Before:
[%hardbreaks]
First line
Second line
Third line
After:
First line
Second line
Third line
Why this matters
Hard line breaks cannot be mapped to DITA output. The AsciiDocDITA Vale rule LineBreak.yml warns:
> Hard line breaks are not supported in DITA.
Usage
When the user asks to fix line breaks:
- Identify the target folder or file containing AsciiDoc content
- Find all
.adocfiles in the target location - Run the Ruby script against each file:
``bash ruby ${CLAUDE_SKILL_DIR}/scripts/line_break.rb ``
- Report the number of line breaks removed
Dry run mode
To preview changes without modifying files:
ruby ${CLAUDE_SKILL_DIR}/scripts/line_break.rb --dry-run
Output to different file
ruby ${CLAUDE_SKILL_DIR}/scripts/line_break.rb -o
Process all files in a directory
find -name "*.adoc" -exec ruby ${CLAUDE_SKILL_DIR}/scripts/line_break.rb {} \;
Example invocations
- "Fix line breaks in modules/"
- "Remove hard line breaks from the getting_started folder"
- "Remove all
+line continuations" - "Preview line break changes in modules/ --dry-run"
Behavior notes
- Joins lines: When removing
+at end of line, the following line is joined with a space - Removes attribute: The
:hardbreaks-option:attribute line is removed entirely - Removes block option: The
%hardbreaksoption is removed from block attribute lists - Skips code blocks: Line breaks inside code blocks (---- or ....) are not modified
- Skips comments: Line breaks inside comment blocks (////) are not modified
Output format
: Removed N hard line break(s)
Or:
: No hard line breaks found
Extension location
The Ruby script is located at: ${CLAUDE_SKILL_DIR}/scripts/line_break.rb
Related Vale rule
This skill addresses the warning from: .vale/styles/AsciiDocDITA/LineBreak.yml
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: abhatt-rh
- Source: abhatt-rh/redhat-docs-agent-tools
- License: Apache-2.0
- Homepage: https://redhat-documentation.github.io/redhat-docs-agent-tools/
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet — be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.