mirror of
https://github.com/supabase/agent-skills.git
synced 2026-01-26 19:09:51 +08:00
refactor: initial build system refactor for unified skills
- Renamed postgres-best-practices-build to skills-build - Moved postgres files to src/postgres/ subdirectory - Updated BUILD_DIR paths in postgres/config.ts - Updated type imports to reference ../types.js - Created IMPLEMENTATION_GUIDE.md with detailed step-by-step tasks This is the foundation for a unified build system that will support both postgres-best-practices (rule-based) and supabase (reference-based) skills. Next steps documented in IMPLEMENTATION_GUIDE.md (Tasks 1-6).
This commit is contained in:
@@ -2,7 +2,7 @@ import { existsSync, readdirSync, readFileSync, writeFileSync } from "node:fs";
|
||||
import { basename, join } from "node:path";
|
||||
import { AGENTS_OUTPUT, METADATA_FILE, RULES_DIR } from "./config.js";
|
||||
import { parseRuleFile } from "./parser.js";
|
||||
import type { Metadata, Rule, Section } from "./types.js";
|
||||
import type { Metadata, Rule, Section } from "../types.js";
|
||||
import { validateRuleFile } from "./validate.js";
|
||||
|
||||
/**
|
||||
@@ -4,8 +4,8 @@ import { fileURLToPath } from "node:url";
|
||||
const __filename = fileURLToPath(import.meta.url);
|
||||
const __dirname = dirname(__filename);
|
||||
|
||||
// Build package directory
|
||||
export const BUILD_DIR = join(__dirname, "..");
|
||||
// Build package directory (now we're in src/postgres/, so go up two levels)
|
||||
export const BUILD_DIR = join(__dirname, "../..");
|
||||
|
||||
// Skill directory (relative to build package)
|
||||
export const SKILL_DIR = join(
|
||||
@@ -1,7 +1,7 @@
|
||||
import { readFileSync } from "node:fs";
|
||||
import { basename } from "node:path";
|
||||
import { IMPACT_LEVELS } from "./config.js";
|
||||
import type { CodeExample, ImpactLevel, ParseResult, Rule } from "./types.js";
|
||||
import type { CodeExample, ImpactLevel, ParseResult, Rule } from "../types.js";
|
||||
|
||||
/**
|
||||
* Parse YAML-style frontmatter from markdown content
|
||||
@@ -3,7 +3,7 @@ import { basename, join } from "node:path";
|
||||
import { generateSectionMap, parseSections } from "./build.js";
|
||||
import { IMPACT_LEVELS, RULES_DIR } from "./config.js";
|
||||
import { parseRuleFile } from "./parser.js";
|
||||
import type { ValidationResult } from "./types.js";
|
||||
import type { ValidationResult } from "../types.js";
|
||||
|
||||
/**
|
||||
* Check if an example label indicates a "bad" pattern
|
||||
Reference in New Issue
Block a user