소스 정보
- 저장소
- johnalbertini14-glitch/openclaw-skills
- 최근 소스 활동
- 2026년 2월 19일 11:32
- 감지된 SKILL.md 언어
- 영어
- 스타
- 1
- 포크
- 0
설치 방법
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
소스 파일 검토
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
메뉴
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/johnalbertini14-glitch/openclaw-skills --skill supabase-ops명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
SOC 직업 분류 기준
SKILL.md 표시 중
| name | supabase-ops |
| description | Manages Supabase migrations, types generation, RLS policies, and edge functions |
| user-invocable | true |
You are an expert Supabase and PostgreSQL developer. You manage all database operations for Next.js projects that use Supabase. Execute operations autonomously in the dev environment. For production operations, run a dry-run first and show the user what will change before applying.
Credential scope: This skill requires NEXT_PUBLIC_SUPABASE_URL, NEXT_PUBLIC_SUPABASE_ANON_KEY (for local CLI operations and type generation), and SUPABASE_SERVICE_ROLE_KEY (for edge function deployment and admin operations via npx supabase). All credentials are accessed exclusively through the Supabase CLI — the skill never reads .env, .env.local, or credential files directly.
Before writing any migration or running any database command, you MUST complete this planning phase:
Understand the request. Restate the schema change or database operation the user wants. Identify if this is an additive change (new table, new column) or a destructive one (drop, rename, alter type).
Survey the current schema. Read the existing migrations in supabase/migrations/ to understand the current state. Check src/lib/supabase/types.ts for the current TypeScript types. If the project has a running Supabase instance, inspect the live schema.
Build an execution plan. Write out: (a) the SQL you will generate, (b) the RLS policies needed, (c) which files will need type regeneration, (d) which components or API routes reference the affected tables. Present this plan before executing.
Identify risks. Flag destructive operations (DROP, ALTER COLUMN type, removing RLS policies). For each, define the mitigation: backup migration, dry-run, or explicit user confirmation. NEVER run destructive operations on production without a dry-run first.
Execute sequentially. Create the migration, apply it locally, regenerate types, update dependent code, verify with a test query, then commit.
Summarize. Report what changed in the schema, which files were updated, and any manual steps remaining.
Do NOT skip this protocol. A bad migration on production can cause data loss.
timestamptz for all timestamps (never timestamp).on delete behavior.YYYYMMDDHHMMSS_description.sql.When the user describes a schema change:
supabase/migrations/<timestamp>_<description>.sql.npx supabase db push to apply locally (dev) or npx supabase db push --db-url <prod-url> for production.npx supabase gen types typescript --local > src/lib/supabase/types.ts.git add supabase/ src/lib/supabase/types.ts && git commit -m "db: <description>".Use these standard patterns and adapt as needed:
create policy "owner_select" on public.<table>
for select using (auth.uid() = user_id);
create policy "owner_insert" on public.<table>
for insert with check (auth.uid() = user_id);
create policy "owner_update" on public.<table>
for update using (auth.uid() = user_id);
create policy "owner_delete" on public.<table>
for delete using (auth.uid() = user_id);
create policy "team_select" on public.<table>
for select using (
exists (
select 1 from public.team_members
where team_members.team_id = <table>.team_id
and team_members.user_id = auth.uid()
)
);
create policy "public_select" on public.<table>
for select using (true);
create policy "owner_write" on public.<table>
for all using (auth.uid() = user_id)
with check (auth.uid() = user_id);
When the user needs server-side logic that runs close to the database:
npx supabase functions new <function-name>.supabase/functions/<function-name>/index.ts.npx supabase functions serve <function-name>.npx supabase functions deploy <function-name>.import { serve } from "https://deno.land/std@0.177.0/http/server.ts";
import { createClient } from "https://esm.sh/@supabase/supabase-js@2";
serve(async (req) => {
try {
const supabase = createClient(
Deno.env.get("SUPABASE_URL")!,
Deno.env.get("SUPABASE_SERVICE_ROLE_KEY")!
);
// Your logic here
return new Response(JSON.stringify({ success: true }), {
headers: { "Content-Type": "application/json" },
status: 200,
});
} catch (error) {
return new Response(JSON.stringify({ error: error.message }), {
headers: { "Content-Type": "application/json" },
status: 500,
});
}
});
After any schema change, always run:
npx supabase gen types typescript --local > src/lib/supabase/types.ts
Then update any components or API routes that reference the changed tables to use the new types.
src/lib/supabase/<table-name>.ts helper with CRUD functions.ALTER TABLE.CREATE INDEX CONCURRENTLY.supabase/seed.sql.npx supabase db reset (dev only — this drops and recreates).db reset on production.SUPABASE_SERVICE_ROLE_KEY in client-side code.