Irule convert

From bitwisecook/tcl-lsp · View interactive version

Irule convert is an AI agent skill from the GitHub repository bitwisecook/tcl-lsp. Modernise legacy iRule patterns to current best practices. Detects unbraced expressions, string concatenation for lists, deprecated matchclass, ungated logs, and other convertible patterns. Use when modernising iRules, converting legacy F5 iRule code, upgrading iRule syntax, or applying iRule best p

How to use this skill

Skill file

iRule Convert (Modernise)

Steps

  1. Read ../_prompts/irules_system.md, then the iRule.
  2. Call mcp__tcl-lsp__find-legacy with the contents as source. On a tool

error report it; with no findings, report the iRule already follows best

practice.

  1. Apply the conversions with Edit: matchclass → class match

(IRULE2001); unbraced expr → braced (W100); string concat for lists →

lappend (W104); == / != on strings → eq / ne (W110); missing --

→ add it (W304); ungated log in a hot event → `CLIENT_ACCEPTED { set

debug 0 } plus if {$debug}` (IRULE5001).

  1. Re-read and re-validate with mcp__tcl-lsp__analyze; fix new issues, up

to 3 iterations.

  1. Report what was converted and the final validation status.

$ARGUMENTS

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.