Adds Nix-based local Playwright e2e runs via a self-contained tests/shell.nix and justfile recipe, using nixpkgs-latest for playwright-driver.browsers. Works on NixOS where npx playwright install --with-deps cannot.
Ships in juspay. 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.
None: SKILL.md is the whole skill.
For projects that already have a Playwright e2e suite (typically under tests/) and need it to run locally on NixOS / pure-Nix hosts, where Playwright's bundled Chromium download depends on apt-get + sudo.
GitHub Actions CI is left untouched — apt-provided Chromium on Ubuntu runners is cheaper than spinning up a Nix devshell. This skill is for local runs (and Nix-based CI like Vira); GHA continues to use its own apt path.
nixpkgs-latest flake inputIn top-level flake.nix, add an independent pin so the Playwright rev moves on its own cadence (decoupled from the main nixpkgs your build uses):
inputs.nixpkgs-latest.url = "github:nixos/nixpkgs/nixpkgs-unstable";
tests/shell.nixSelf-contained. Reads the parent flake's lock to resolve nixpkgs-latest without needing a flake context:
let
lock = builtins.fromJSON (builtins.readFile ../flake.lock);
nixpkgsLocked = lock.nodes.nixpkgs-latest.locked;
pkgs = import (builtins.fetchTree {
type = "github";
inherit (nixpkgsLocked) owner repo rev narHash;
}) { };
in
pkgs.mkShell {
packages = [ pkgs.nodejs ];
PLAYWRIGHT_BROWSERS_PATH = "${pkgs.playwright-driver.browsers}";
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD = "1";
}
e2e:
nix-shell tests/shell.nix --run "cd tests && { [ -d node_modules ] || npm ci; } && npm test"
pkgs.playwright-driver version must match the playwright version in tests/package.json. Drift raises "browser revision X not found at <PLAYWRIGHT_BROWSERS_PATH>" at launch.
Bump both together:
nix flake update nixpkgs-latestplaywright in tests/package.json to the new driver versionnpm install in tests/ to regenerate the lockfilePattern extracted from emanote#660.
What SKILL.md sets; muted values are Claude Code's defaults
/juspay:nix-playwrightfrom juspay
npx claudepluginhub juspay/skills --plugin juspay17 skills in this plugin
/cargo-watchRun cargo-watch in the background for continuous clippy feedback during code editing./nix-bunUse this when building a Bun (bun.lock) project with Nix. Covers bun2nix, the bun.nix dependency workflow, the bun --compile top-level-await pitfall, and a CI drift check./nix-ciUse this when setting up CI for a GitHub repository — offers GitHub Actions or Vira depending on the project/nix-for-devUse this when setting up Nix for a development project (devShell + package build) and you care about `nix develop` being fast. Covers the zero-inputs flake.nix + npins + default.nix/shell.nix layout, sub-flakes for non-user-facing Nix, and language-specific recommendations./nix-haskellUse this when working on a Haskell project with Nix. Covers haskell-flake setup, adding/overriding dependencies, package settings, and devShell configuration./nix-healthUse this when diagnosing or fixing a user's Nix installation — checks flakes, version, caches, max-jobs, direnv, rosetta, trusted-users, and shell configOther plugins' skills for the same job