Логотип Delete Initial Resource

Delete Initial Resource

ОрганізаціяПопулярне
marmelab
delete-initial-resource

Видаляє з кодової бази один або кілька початкових ресурсів CRM (контакти, компанії, угоди, теги, завдання). Використовуйте, коли користувач просить видалити один або кілька вбудованих ресурсів. Запускає скрипт delete-initial-resource.ts, який видаляє папку кожного ресурсу, а потім допомагає очистити всі файли, де є посилання на ці ресурси.

Огляд

Видавецьmarmelab
Репозиторійatomic-crm
Назва навичкиdelete-initial-resource
Зірки
1.4K
Форки
860
Файли в пакеті
6
ЛіцензіяMIT
Посилання
  • Інструкції у форматі Markdown

    Файл SKILL.md, який модель завантажує за потреби, тож токени витрачаються лише тоді, коли запит справді відповідає навичці.

  • Працює з будь-якою LLM

    Навички ШІ — це звичайний Markdown, а не код для певного постачальника, тому вони працюють із GPT, Claude, Gemini, Grok або локальною моделлю.

  • Файлів у комплекті: 6

    Скрипти, шаблони й довідкові матеріали, які модель може читати під час роботи. Файли доступні лише для читання й ніколи не виконуються.

  • Відкритий вихідний код

    Видавець на GitHub: marmelab. Перед установленням перегляньте вихідні файли навички.

Встановлення

Установіть навичку ШІ Delete Initial Resource у TypingMind, щоб використовувати її з будь-якою LLM, або додайте її до іншого агента, що читає SKILL.md.

1

Встановити в TypingMind

TypingMind встановлює навичку безпосередньо з її папки на GitHub — читає SKILL.md, збирає файли ресурсів у пакет і зберігає результат локально.

  1. Відкрийте застосунок і перейдіть до розділу «Плагіни» → «Навички».
  2. Виберіть «Встановити з GitHub».
  3. Вставте наведений нижче URL папки навички та підтвердьте встановлення.
    https://github.com/marmelab/atomic-crm/tree/main/.claude/skills/delete-initial-resource
  4. Увімкніть навичку в кожному чаті, де хочете її використовувати.
Плагіни → Навички → Додати навичку → За URL GitHub, потім вставте URL папки й натисніть «Продовжити».
2

Встановити в іншому агенті

Будь-який агент, що підтримує формат Agent Skills, може використовувати цю навичку — скопіюйте папку до каталогу навичок цього агента.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/marmelab/atomic-crm.git /tmp/atomic-crm
mkdir -p .claude/skills
cp -r /tmp/atomic-crm/.claude/skills/delete-initial-resource .claude/skills/delete-initial-resource
Після копіювання перезапустіть Claude Code, щоб завантажити нову навичку.

Використовуйте навичку в TypingMind

Увімкніть навичку Delete Initial Resource в будь-якому чаті TypingMind, і далі модель усе зробить сама. Назва й опис навички містяться в системному промпті, а щойно надходить відповідний запит, модель самостійно завантажує повні інструкції — вам не потрібно викликати навичку вручну, і до фактичного використання вона не витрачає токенів.

Модель самостійно завантажує навичку Delete Initial Resource, щойно надходить відповідний запит.

Працює з будь-якою моделлю ШІ

Навички ШІ — це звичайні інструкції у форматі Markdown, а не код для певного постачальника, тому навичка Delete Initial Resource не прив’язана до моделі, для якої її створено. Установіть її один раз у TypingMind і використовуйте з GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama або локальною моделлю, яку ви запускаєте самостійно, — усе з вашими власними ключами API.

  • Завантажується лише за потреби

    Системний промпт містить лише назву й опис. Інструкції завантажуються за першого відповідного запиту, тож поки навичка не потрібна, токени на її інструкції не витрачаються.

  • Змінюйте моделі під час чату

    Оскільки навичка — це інструкції, а не код, зміна моделі не порушує її роботу: наступна модель читає той самий файл SKILL.md.

Інструкції навички

Це вміст файлу SKILL.md, який завантажує модель. Прочитайте його перед установленням — навичка містить інструкції, яких дотримуватиметься ваша модель.

delete-initial-resource

Overview

Removes one or more of the five initial Atomic CRM resources (contacts, companies, deals, tags, tasks) and every reference to them. Irreversible confirm the target(s) with the user first; rely on git to recover. Exit criterion: make typecheck && make lint is clean and no live reference to the deleted resource(s) survives in src/ or supabase/.

When to Use

  • The user asks to delete, remove, or strip out one or several built-in CRM resources.
  • Not for custom entities added during setup only the five built-ins above.

For the backend migration mechanics, see Skill({skill: "backend-dev"}) and Skill({skill: "writing-migrations"}).

Steps

  1. Confirm the target(s), then read each one's file before editing:
  2. Run the script (below) — deletes each src/components/atomic-crm/<resource>/ folder and prints the dependent files to clean.
  3. Clean each dependent file using the "Shapes" patterns below + the per-resource file.
  4. Verify (below).

Deleting several at once: clean from the most-coupled resource outward; clean a shared file once for both; and reconcile interacting union guidance — deleting both contacts and deals removes the notes/activity-log reference entirely rather than each narrowing it, so don't half-apply each file's "narrow the union" note.

The script

bash
node .claude/skills/delete-initial-resource/delete-initial-resource.ts <resource> [<resource> ...]

Validates the names, deletes each resource's folder, and prints the merged, de-duplicated dependent-file list (files inside a just-deleted folder are dropped). It does not edit those files — that's your job. Each entry in the script's dependentFiles map has a // comment saying what to remove; read it alongside the printed list, and update the map if the codebase grows new references.

Shapes a resource takes

A resource is rarely just a folder. The later shapes are invisible to a \b<resource>\b grep:

  • Standalone — imports, JSX, routes, menu/nav, dashboard widgets, the <Resource> entry in root/CRM.tsx. Wrapper components outside the folder that only render the resource: delete outright, then clean importers.
  • Field/column on another record — fans out far wider: the types.ts type, providers/commons/mergeContacts.ts, CSV/JSON import, i18n, stories/tests, StoryWrapper builders, and the sample CSVs (header and every row). For a link column, decide per-link: orphaned shell (typed, defaulted) or drop — remove the UI either way.
  • Aggregated nb_<resource> (from the _summary views) lands on a record type, read across shows/lists/filters/generators. Invisible to a \b<resource>\b grep (the _ is a word char) — grep nb_<resource> and the denormalized company_name separately.
  • Shared subsystems — notes (reference: "contacts" | "deals") and the activity log ("company" | "contact" | "deal" | "all" union). Narrow the union, delete the per-type render components (ActivityLog*Created.tsx) + dead branches, prune the providers/commons/activity.ts fetcher + consts.ts/types.ts members. Surviving === "<other>" checks stay valid — only the deleted member's branches go.
  • Config props (taskTypes, dealStages, companySectors) live in root/defaultConfiguration.ts, ConfigurationContext.tsx, CRM.tsx (default + jsdoc + store seed), App.tsx, and SettingsPage.tsx (the <Card> and the section-list entry). Not always named after the resource — grep the settings <Card> for other keys (Deals owned currency) and flag borderline-general ones rather than dropping them silently.
  • Custom dataProvider methods live in both providers; CrmDataProvider derives from the supabase one, so removing them there drops them from the type. Also clean the lifecycle-callback blocks in both providers, the sales beforeDelete reassignment, the supabase <resource> -> <resource>_summary getList routing, and the FakeRest generators (which drive record creation).
  • JSON importer (misc/useImportFromJson.ts) treats contacts/companies/notes/tasks as top-level types (import<X> fn, $.<x>.* path, a TYPES arm + switch, guards, stats/failedImports/idsMaps keys). Mirror in ImportPage.tsx + import-sample.json; the CSV importer (useContactImport.tsx) has parallel mappings.
  • Check useCallback/useMemo deps — a stale getTags/getCompanies there is invisible until tsc.

Backend (the script only touches frontend)

See the backend-dev skill for the migration workflow. In supabase/schemas/:

  • Drop/adjust the table + view, generate a migration (npx supabase db diff --local -f remove_<resource>); update contacts_summary/companies_summary if they aggregated it.
  • activity_log is a UNION ALL with the same column set per branch — remove the resource's columns from every branch (keep them aligned), delete its dedicated branch(es), and drop the matching snake→camel rename in the supabase getList("activity_log").
  • 06_grants.sql grants the table and its <resource>_id_seq (drop both). 05_policies.sql has an RLS-enable line and create policy statements (drop both).
  • A resource used inside a SQL function (merge_contacts): drop those lines + the unused local var. Editing 02_functions.sql regenerates the whole function (expected) — renumber leftover step comments.
  • Orphan check: deleting triggers can orphan helpers — but verify shared callers first (get_domain_favicon survives a companies delete because contact avatars also call it).
  • Edge functions are separate and easy to miss: merge_contacts/, _shared/db.ts (Kysely types), postmark/ (inbound email), and mcp/ (an AI subsystem whose depth varies per resource). When a surviving function loses a capability, flag it to the user.

Rationalizations

RationalizationReality
"I deleted the folder, the resource is gone."A resource is also fields on other records, nb_<resource> aggregates, shared subsystems, config props, dataProvider methods, and SQL — the folder is the easy part.
"A \b<resource>\b grep came back clean, so it's clean."nb_<resource> and denormalized company_name are invisible to that grep (_ is a word char). Grep them separately.
"I'll remove the i18n key from English only."The French catalog is type-checked against English — a one-sided removal is a tsc error. Remove from both or neither.
"The script edits the dependent files for me."The script only deletes folders and prints the list. Editing every dependent file is your job.
"Typecheck passes, so the deletion is complete."tsc misses broken views/functions/grants. Reset the DB and grep for live references too.

Red Flags

  • Editing files inside supabase/migrations/ (never — they are append-only history).
  • A one-sided i18n key removal (English without French, or vice versa).
  • Relying on a single \b<resource>\b grep and skipping nb_<resource> / company_name.
  • Deleting a shared SQL helper or edge-function capability without checking surviving callers.
  • Deleting several resources but half-applying each file's "narrow the union" note.
  • Skipping the db reset check when Supabase is running.

Verification

bash
make typecheck && make lint

Resolve whatever tsc surfaces (the dependent-file list is a guide, not a guarantee). Then grep -rniE "\b<resource>\b" over src/+supabase/, plus separate greps for nb_<resource>, company_name, and config-prop names (<resource>Types, companySectors, currency). Watch for benign/substring false positives (each resource file lists its own); never edit supabase/migrations/.

  • make typecheck && make lint is clean.
  • \b<resource>\b, nb_<resource>, company_name, and config-prop greps return only benign matches.
  • i18n keys removed from both catalogs, or neither.
  • Backend: table/view/policies/grants/sequences and any function references handled in supabase/schemas/ (not migrations/).
  • If Supabase is running, npx supabase db reset --local replays cleanly.
  • Any lost edge-function capability flagged to the user.

i18n is all-or-nothing: frenchCrmMessages.ts is type-checked against the type derived from englishCrmMessages.ts, so remove a key from both catalogs or neither (a one-sided removal is a tsc error). Dead resources.<x>.* keys are harmless — flag rather than force. frenchCrmMessages.ts uses literal … escapes; if an exact-string Edit fails on a block spanning one, fall back to sed -i '<from>,<to>d'.

If Supabase is running, npx supabase db reset --local replays the chain + seed.sql and catches a broken view/function/grant db diff misses (benign index "…_pkey" does not exist NOTICEs expected). On Node 24 (see .nvmrc), make test (vitest) is also available.

Файли в пакеті

Модель читає ці файли за потреби, поки навичку завантажено. Вони доступні для читання й ніколи не виконуються.

Поширені запитання

Що робить навичка ШІ Delete Initial Resource?

Видаляє з кодової бази один або кілька початкових ресурсів CRM (контакти, компанії, угоди, теги, завдання). Використовуйте, коли користувач просить видалити один або кілька вбудованих ресурсів. Запускає скрипт delete-initial-resource.ts, який видаляє папку кожного ресурсу, а потім допомагає очистити всі файли, де є посилання на ці ресурси.

Навіщо використовувати Delete Initial Resource у TypingMind?

Тому що ви встановлюєте її один раз і використовуєте з будь-якою моделлю. Delete Initial Resource — це звичайний Markdown, а не код для конкретного постачальника, тому та сама навичка працює з GPT-5, Claude, Gemini, Grok або локальною моделлю. Ви можете змінити модель навіть посеред чату, і навичка продовжить працювати. TypingMind використовує ваші власні ключі API, тож ви платите безпосередньо постачальникам замість передплати за кожне місце користувача, а ваші навички й чати залишаються у вашому сховищі.

Як встановити Delete Initial Resource у TypingMind?

Відкрийте в TypingMind Плагіни → Навички → Встановити з GitHub і вставте https://github.com/marmelab/atomic-crm/tree/main/.claude/skills/delete-initial-resource. TypingMind прочитає файл SKILL.md, додасть супровідні файли та встановить навичку, яку можна вмикати окремо для кожного чату.

Які моделі ШІ можуть використовувати Delete Initial Resource?

Будь-яка модель, яку ви підключите в TypingMind. Навички ШІ — це звичайні інструкції у форматі Markdown, а не код для конкретного постачальника, тому GPT, Claude, Gemini, Grok і локальні моделі можуть завантажувати цю навичку, коли запит їй відповідає.

Зі скількома моделями ШІ можна використовувати Delete Initial Resource?

Зі скількома забажаєте. У TypingMind ви можете використовувати Delete Initial Resource із будь-якою моделлю, яка підтримує навички, зокрема з GPT, Claude, Gemini, Grok, DeepSeek, Mistral чи Llama. Для цього ви використовуєте власні ключі API.

Чи безкоштовна навичка ШІ Delete Initial Resource?

Так. На GitHub цю навичку публікує marmelab за ліцензією MIT. Ви платите лише своєму постачальнику ШІ за використані токени.

Що таке навички ШІ?

Навичка ШІ — це набір інструкцій для повторного використання, який навчає модель ШІ виконувати одне конкретне завдання. Він відповідає відкритому формату Agent Skills: файл SKILL.md із назвою та описом, а також скрипти, шаблони чи довідкові файли, які можуть знадобитися моделі. Модель читає інструкції лише тоді, коли ваш запит відповідає навичці, тому встановлена навичка нічого не коштує, доки її не використано.

Чим навички ШІ відрізняються від плагінів або серверів MCP?

Плагін або сервер MCP надає моделі нові інструменти, які вона може викликати, — код, який десь виконується й повертає результат. Натомість навичка ШІ дає моделі знання й пояснює порядок дій: як підійти до завдання, яких кроків дотримуватися та яким має бути якісний результат. Навички — це звичайний Markdown, тож їм не потрібні ні сервер, ні ключ API, ні середовище виконання, і вони працюють із будь-якою моделлю.

Усі
Логотип openclaw

Graincrawl

openclaw
ОрганізаціяПопулярне

Архів Granola: пошук, актуальність синхронізації, нотатки, транскрипти, панелі, підрахунки SQL і робота з репозиторіями Graincrawl.

82.2K
391K
Файлів: 1
Відкрити
Логотип openclaw

Openclaw Changelog Update

openclaw
ОрганізаціяПопулярне

Повторно створюйте розділи журналу змін релізу OpenClaw на основі історії git перед випусками beta, stable або extended-stable.

82.2K
391K
Файлів: 1
Відкрити
Логотип openclaw

Openclaw Ci Limits

openclaw
ОрганізаціяПопулярне

Керуйте GitHub Actions для OpenClaw і пропускною здатністю CI у Blacksmith, бюджетами реєстрації раннерів, обмеженнями fanout, одночасним запуском лише одного завдання для кожного push у main, розміром шард, перенесенням завдань на хостовані раннери, станом черги та безпечним…

82.2K
391K
Файлів: 1
Відкрити
Логотип openclaw

Openclaw Debugging

openclaw
ОрганізаціяПопулярне

Діагностуйте проблеми з моделями, провайдерами, інтерфейсом інструментів, режимом коду, потоковою передачею та роботою OpenClaw у реальному часі/Crabbox. Перш ніж змінювати код, добирайте потрібні журнали, перевірки та спосіб підтвердження, зокрема отримуйте збережені…

82.2K
391K
Файлів: 1
Відкрити

Створіть власний робочий простір зі ШІ вже зараз

Підпишіться на нашу розсилку, щоб дізнаватися про нові функції та майбутні розіграші 👇