aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-04-19 15:16:46 -0500
committerCraig Jennings <c@cjennings.net>2026-04-19 15:16:46 -0500
commit11f5f003eef12bff9633ca8190e3c43c7dab6708 (patch)
treec74cb8c5cbb189a9b5aa8154ae4c898e9992b771 /Makefile
parentb3247d0b1aaf73cae6068e42e3df26b256d9008e (diff)
downloadrulesets-11f5f003eef12bff9633ca8190e3c43c7dab6708.tar.gz
rulesets-11f5f003eef12bff9633ca8190e3c43c7dab6708.zip
feat: adopt lackeyjb/playwright-skill (MIT verbatim fork) + deps target
Browser automation + UI testing skill forked verbatim from github.com/lackeyjb/playwright-skill (MIT, 2458 stars, active through Dec 2025). LICENSE preserved in skill dir with attribution footer added to SKILL.md. Bundle contents (from upstream): playwright-skill/SKILL.md playwright-skill/API_REFERENCE.md playwright-skill/run.js (universal executor with module resolution) playwright-skill/package.json playwright-skill/lib/helpers.js (detectDevServers, safeClick, safeType, takeScreenshot, handleCookieBanner, extractTableData, createContext with env-driven header injection) playwright-skill/LICENSE (MIT, lackeyjb) Makefile updates: - SKILLS extended with playwright-skill; make install symlinks it globally into ~/.claude/skills/ - deps target extended to check node + npm, and to run the skill's own `npm run setup` (installs Playwright + Chromium ~300 MB on first run). Idempotent: skipped if node_modules/playwright already exists. Stack fit: JavaScript Playwright aligns with Craig's TypeScript/React frontend work. Python-side (Django) browser tests would be better served by Anthropic's official webapp-testing skill (Python Playwright bindings), noted in the evaluation memory but not adopted here — minimal overlap, easy to add later if the need arises.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile39
1 files changed, 27 insertions, 12 deletions
diff --git a/Makefile b/Makefile
index eed34ae..c78bad6 100644
--- a/Makefile
+++ b/Makefile
@@ -5,7 +5,8 @@ SKILLS_DIR := $(HOME)/.claude/skills
RULES_DIR := $(HOME)/.claude/rules
SKILLS := c4-analyze c4-diagram debug add-tests respond-to-review review-pr fix-issue security-check \
arch-design arch-decide arch-document arch-evaluate \
- brainstorm codify root-cause-trace five-whys prompt-engineering
+ brainstorm codify root-cause-trace five-whys prompt-engineering \
+ playwright-skill
RULES := $(wildcard claude-rules/*.md)
LANGUAGES := $(notdir $(wildcard languages/*))
@@ -47,18 +48,32 @@ help: ## Show this help
##@ Dependencies
-deps: ## Install required tools (claude, jq, fzf, ripgrep, emacs)
+deps: ## Install required tools (claude, node, jq, fzf, ripgrep, emacs, playwright)
@echo "Checking dependencies..."
- @command -v claude >/dev/null 2>&1 && echo " claude: installed" || \
- { echo " claude: installing via npm..."; npm install -g @anthropic-ai/claude-code; }
- @command -v jq >/dev/null 2>&1 && echo " jq: installed" || \
- { echo " jq: installing..."; $(call install_pkg,jq); }
- @command -v fzf >/dev/null 2>&1 && echo " fzf: installed" || \
- { echo " fzf: installing..."; $(call install_pkg,fzf); }
- @command -v rg >/dev/null 2>&1 && echo " ripgrep: installed" || \
- { echo " ripgrep: installing..."; $(call install_pkg,ripgrep); }
- @command -v emacs >/dev/null 2>&1 && echo " emacs: installed" || \
- { echo " emacs: installing..."; $(call install_pkg,emacs); }
+ @command -v claude >/dev/null 2>&1 && echo " claude: installed" || \
+ { echo " claude: installing via npm..."; npm install -g @anthropic-ai/claude-code; }
+ @command -v node >/dev/null 2>&1 && echo " node: installed ($$(node --version))" || \
+ { echo " node: installing..."; $(call install_pkg,nodejs); }
+ @command -v npm >/dev/null 2>&1 && echo " npm: installed" || \
+ { echo " npm: installing..."; $(call install_pkg,npm); }
+ @command -v jq >/dev/null 2>&1 && echo " jq: installed" || \
+ { echo " jq: installing..."; $(call install_pkg,jq); }
+ @command -v fzf >/dev/null 2>&1 && echo " fzf: installed" || \
+ { echo " fzf: installing..."; $(call install_pkg,fzf); }
+ @command -v rg >/dev/null 2>&1 && echo " ripgrep: installed" || \
+ { echo " ripgrep: installing..."; $(call install_pkg,ripgrep); }
+ @command -v emacs >/dev/null 2>&1 && echo " emacs: installed" || \
+ { echo " emacs: installing..."; $(call install_pkg,emacs); }
+ @if [ -d "$(CURDIR)/playwright-skill" ]; then \
+ if [ -d "$(CURDIR)/playwright-skill/node_modules/playwright" ]; then \
+ echo " playwright: installed (skill node_modules present)"; \
+ else \
+ echo " playwright: running skill setup (npm install + chromium download ~300 MB)..."; \
+ (cd "$(CURDIR)/playwright-skill" && npm run setup); \
+ fi \
+ else \
+ echo " playwright: skipped (playwright-skill/ not present in this repo)"; \
+ fi
@echo "Done."
##@ Global install (symlinks into ~/.claude/)