|
Sheerpower with Claude Code and Claude.ai |
Claude Code is Anthropic's AI coding assistant. You tell it in plain words what you want, and it reads, writes and runs code in your project folder. It works in a terminal, in the Claude desktop app and inside VS Code (see the Claude Code documentation).
Sheerpower has rules of its own, and many habits from Python, C and JavaScript do not compile in it. The Sheerpower plugin teaches Claude the difference, and checks its work with the real compiler.
.spsrc or
.spinc file, sp4gl /validate runs, and any errors, with the compiler's own
Help>> advice, go straight back to Claude, which fixes them before going on./sheerpower:help, /sheerpower:new,
/sheerpower:validate and /sheerpower:run (below).sp4gl.exe is in C:\Sheerpower -- see
Installing Sheerpower Step-by-Step.claude --version in a Command Prompt.In Claude Code, type these two commands:
The first adds the Sheerpower plugin catalog; the second shows the plugin, where you choose Install. Then
start a new Claude Code session (or type /reload-plugins). The same two steps work from a Command
Prompt:
claude plugin list should now show sheerpower@sheerpower as enabled. The plugin is
installed for you, in every folder you open with Claude Code.
You do not need special commands. Ask for what you want in plain words. When Sheerpower is involved, Claude loads the rules, looks up anything it is not sure of and writes the code -- and the compile check makes sure it builds. Some things to try:
findrow() with a working example.+=; it is
total = total + amount./sheerpower:help <name or task> -- looks it up in the catalog: the form to write, what it does,
a working example with the output it really printed, and the known traps. For example:/sheerpower:help findrow/sheerpower:help lists the plugin's commands./sheerpower:new <program name> <what it should do> -- writes a new program in house
style and compiles it clean before handing it over. For example:/sheerpower:new invoice_report read invoices.csv and total by customer, highest first/sheerpower:validate <file> -- compiles a program and fixes every error until it builds
clean. An include file (.spinc) is compiled through the program that includes it. For example:/sheerpower:validate weather_web.spsrc/sheerpower:run -- runs a program, in one of three ways:
/sheerpower:run guess_number.spsrc -- compiles the program and opens it in its own window, where you
use it as usual (the .spsrc may be left off). If it does not compile, nothing opens: Claude shows the
errors and asks before changing your program. When it ends, Claude tells you how it ended -- and if it stopped on an
error, why./sheerpower:run on its own -- opens the Sheerpower REPL console, where you can try statements, write
short programs, and run programs with run 'guess_number.spsrc'./sheerpower:run guess_number.spsrc answers.txt -- for testing: runs the program without a window,
types each line of answers.txt in as if you had typed it, and reports what it printed, its exit code and
any error.
Suppose Claude writes total += 5 on line 3 of add_prices.spsrc. As soon as the file is
saved, the check compiles it and hands this back to Claude:
Claude changes the line to total = total + 5, the file is compiled again, and the build is clean -- so
the code Claude hands you has already been through the compiler.
claude plugin update sheerpower@sheerpowerclaude plugin disable sheerpower@sheerpower (and
claude plugin enable sheerpower@sheerpower to turn it back on)claude plugin uninstall sheerpower@sheerpowersp4gl will not run a program from a temporary folder (a
security guard).If you talk to Claude in a web browser at claude.ai rather than in Claude Code, you can give it the same Sheerpower knowledge as two skills:
On claude.ai, Claude cannot run sp4gl.exe, so there is no compile
check there and none of the four
commands that Claude Code supports. Claude
tells you plainly that it has not compiled
what it wrote: instead, you compile it with
sp4gl prog.spsrc /validate and paste any errors
back into Claude.ai for it to fix.
To install them:
Claude.ai:
Bottom left, choose Settings > Capabilities.findrow(), a verified example and its traps.
From then on, Claude uses the skills on its own whenever a mention of
Sheerpower comes up -- just ask like you do for any other question:
In sheerpower, how do I count from 1 to 10
|
Hide Description
|
|
|
Enter or modify the code below, and then click on RUN |
|
Looking for the full power of Sheerpower?
Check out the Sheerpower website. Free to download. Free to use. |