Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion generated/build-from-skills.manifest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"version": 1,
"generatedAt": "2026-05-05T21:44:59.479Z",
"generatedAt": "2026-05-19T03:50:38.812Z",
"templates": [
{
"template": "agents/ai-architect.md.tmpl",
Expand Down
2 changes: 1 addition & 1 deletion generated/skill-catalog.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Skill Catalog

> Auto-generated by `scripts/generate-catalog.ts` — do not edit manually.
> Generated: 2026-05-05T22:50:56.898Z
> Generated: 2026-05-19T03:50:40.894Z
> Skills: 26

## Table of Contents
Expand Down
6 changes: 3 additions & 3 deletions generated/skill-manifest.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"generatedAt": "2026-05-05T22:50:57.156Z",
"generatedAt": "2026-05-19T03:50:40.184Z",
"version": 2,
"skills": {
"vercel-agent": {
Expand Down Expand Up @@ -4273,7 +4273,7 @@
"phrases": [
"vercel firewall",
"vercel waf",
"attack challenge mode",
"attack mode",
"ddos protection",
"ip block",
"managed ruleset",
Expand Down Expand Up @@ -4339,7 +4339,7 @@
"Vercel Firewall",
"Vercel WAF",
"DDoS",
"Attack Challenge Mode",
"Attack Mode",
"Bot Protection",
"Managed Rulesets",
"System Bypass",
Expand Down
1 change: 0 additions & 1 deletion hooks/session-hooks-platform-compat.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ describe("session hook platform compatibility", () => {
);
expect(JSON.parse(formatSessionStartProfilerCursorOutput(envVars, ["profile ready"]))).toEqual({
env: {
VERCEL_PLUGIN_AGENT_BROWSER_AVAILABLE: "1",
VERCEL_PLUGIN_GREENFIELD: "true",
VERCEL_PLUGIN_LIKELY_SKILLS: "ai-sdk,nextjs",
VERCEL_PLUGIN_BOOTSTRAP_HINTS: "greenfield",
Expand Down
2 changes: 1 addition & 1 deletion hooks/src/telemetry.mts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ declare const __VERCEL_PLUGIN_VERSION__: string;

const BRIDGE_ENDPOINT = "https://telemetry.vercel.com/api/vercel-plugin/v1/events";
const FLUSH_TIMEOUT_MS = 3_000;
export const PLUGIN_VERSION = __VERCEL_PLUGIN_VERSION__;
export const PLUGIN_VERSION = typeof __VERCEL_PLUGIN_VERSION__ === "string" ? __VERCEL_PLUGIN_VERSION__ : "0.43.0";
const ACTIVE_SESSION_TTL_MS = 60 * 60 * 1000;

const DAU_STAMP_PATH = join(homedir(), ".config", "vercel-plugin", "dau-stamp");
Expand Down
2 changes: 1 addition & 1 deletion hooks/telemetry.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { join, dirname } from "path";
import { homedir } from "os";
var BRIDGE_ENDPOINT = "https://telemetry.vercel.com/api/vercel-plugin/v1/events";
var FLUSH_TIMEOUT_MS = 3e3;
var PLUGIN_VERSION = "0.43.0";
var PLUGIN_VERSION = true ? "0.43.0" : "0.43.0";
var ACTIVE_SESSION_TTL_MS = 60 * 60 * 1e3;
var DAU_STAMP_PATH = join(homedir(), ".config", "vercel-plugin", "dau-stamp");
var FIRST_USE_STAMP_PATH = join(homedir(), ".config", "vercel-plugin", "first-use-stamp");
Expand Down
22 changes: 11 additions & 11 deletions hooks/user-prompt-submit-skill-inject.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,7 @@ describe("user prompt seen-skills dedup state", () => {

expect(state.dedupOff).toBe(false);
expect(state.hasFileDedup).toBe(true);
expect("hasEnvDedup" in state).toBe(false);
expect("seenEnv" in state).toBe(false);
expect(state.seenEnv).toBe("skill-env,shared");
expect(state.seenClaims).toBe("skill-claim");
expect(state.seenState).toBe("shared,skill-claim,skill-file");
expect(readSessionFile(sessionId, SESSION_KIND)).toBe(state.seenState);
Expand Down Expand Up @@ -137,12 +136,12 @@ describe("user prompt cursor compatibility", () => {
conversation_id: "cursor-conversation",
workspace_roots: ["/tmp/cursor-workspace", "/tmp/ignored"],
cursor_version: "1.0.0",
prompt: "Use ai elements for streaming markdown in this chat UI",
prompt: "Use the AI SDK for streaming text generation",
}),
);

expect(parsed).toEqual({
prompt: "Use ai elements for streaming markdown in this chat UI",
prompt: "Use the AI SDK for streaming text generation",
platform: "cursor",
sessionId: "cursor-conversation",
cwd: "/tmp/cursor-workspace",
Expand Down Expand Up @@ -174,22 +173,23 @@ describe("user prompt cursor compatibility", () => {

it("test_formatOutput_returns_cursor_flat_shape_with_continue_and_env", () => {
const output = JSON.parse(formatOutput(
["You must run the Skill(ai-elements) tool."],
["ai-elements"],
["ai-elements"],
["You must run the Skill(ai-sdk) tool."],
["ai-sdk"],
["ai-sdk"],
[],
[],
[],
[],
{ "ai-elements": "matched streaming markdown" },
{ "ai-sdk": "matched AI SDK" },
undefined,
"cursor",
{ VERCEL_PLUGIN_SEEN_SKILLS: "ai-elements" },
{ VERCEL_PLUGIN_SEEN_SKILLS: "ai-sdk" },
));

expect(output.continue).toBe(true);
expect(output.additional_context).toContain("Skill(ai-elements)");
expect(output.additional_context).toContain("Skill(ai-sdk)");
expect(output.additional_context).toContain("skillInjection");
expect(output.env).toEqual({ VERCEL_PLUGIN_SEEN_SKILLS: "ai-elements" });
expect(output.env).toEqual({ VERCEL_PLUGIN_SEEN_SKILLS: "ai-sdk" });
expect(output.hookSpecificOutput).toBeUndefined();
});

Expand Down
4 changes: 3 additions & 1 deletion scripts/validate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1286,4 +1286,6 @@ async function main() {
process.exit(errorCount > 0 ? 1 : 0);
}

main();
if (import.meta.main) {
main();
}
123 changes: 123 additions & 0 deletions tests/__snapshots__/build-from-skills-integration.test.ts.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
// Bun Snapshot v1, https://bun.sh/docs/test/snapshots

exports[`dependency manifest manifest dependency snapshot 1`] = `
[
{
"dependencies": [
"ai-sdk",
],
"includeCount": 2,
"template": "agents/ai-architect.md.tmpl",
},
{
"dependencies": [
"deployments-cicd",
"vercel-functions",
],
"includeCount": 10,
"template": "agents/deployment-expert.md.tmpl",
},
{
"dependencies": [
"next-cache-components",
"nextjs",
],
"includeCount": 8,
"template": "agents/performance-optimizer.md.tmpl",
},
{
"dependencies": [
"bootstrap",
],
"includeCount": 9,
"template": "commands/bootstrap.md.tmpl",
},
{
"dependencies": [
"deployments-cicd",
],
"includeCount": 5,
"template": "commands/deploy.md.tmpl",
},
{
"dependencies": [
"env-vars",
],
"includeCount": 6,
"template": "commands/env.md.tmpl",
},
{
"dependencies": [
"marketplace",
],
"includeCount": 1,
"template": "commands/marketplace.md.tmpl",
},
{
"dependencies": [],
"includeCount": 0,
"template": "commands/status.md.tmpl",
},
]
`;

exports[`CLI --json output shape --json output shape snapshot 1`] = `
[
{
"dependencyCount": 1,
"diagnosticCount": 0,
"resolvedCount": 2,
"status": "unchanged",
"template": "agents/ai-architect.md",
},
{
"dependencyCount": 2,
"diagnosticCount": 0,
"resolvedCount": 10,
"status": "unchanged",
"template": "agents/deployment-expert.md",
},
{
"dependencyCount": 2,
"diagnosticCount": 0,
"resolvedCount": 8,
"status": "unchanged",
"template": "agents/performance-optimizer.md",
},
{
"dependencyCount": 1,
"diagnosticCount": 0,
"resolvedCount": 9,
"status": "unchanged",
"template": "commands/bootstrap.md",
},
{
"dependencyCount": 1,
"diagnosticCount": 0,
"resolvedCount": 5,
"status": "unchanged",
"template": "commands/deploy.md",
},
{
"dependencyCount": 1,
"diagnosticCount": 0,
"resolvedCount": 6,
"status": "unchanged",
"template": "commands/env.md",
},
{
"dependencyCount": 1,
"diagnosticCount": 0,
"resolvedCount": 1,
"status": "unchanged",
"template": "commands/marketplace.md",
},
{
"dependencyCount": 0,
"diagnosticCount": 0,
"resolvedCount": 0,
"status": "unchanged",
"template": "commands/status.md",
},
]
`;
Loading
Loading