seed-packs

0
0
Source

Create and manage seed packs for PropertyWebBuilder. Use when creating new scenario-based seed data bundles, adding properties to packs, or setting up new tenant websites with pre-configured content.

Install

mkdir -p .claude/skills/seed-packs && curl -L -o skill.zip "https://mcp.directory/api/skills/download/5633" && unzip -o skill.zip -d .claude/skills/seed-packs && rm skill.zip

Installs to .claude/skills/seed-packs

About this skill

Seed Packs for PropertyWebBuilder

What Are Seed Packs?

Seed packs are pre-configured bundles of seed data representing real-world property management scenarios. They provide a way to quickly spin up fully functional tenant websites with realistic data for testing, demonstrations, or initial setup.

Directory Structure

db/seeds/packs/
├── base/                     # Root pack (inherited by all others)
│   ├── pack.yml              # Pack metadata (REQUIRED)
│   ├── field_keys.yml        # Property types, states, features
│   └── links.yml             # Navigation structure
│
└── [pack_name]/              # Scenario pack (e.g., spain_luxury)
    ├── pack.yml              # Pack config (REQUIRED)
    ├── properties/           # Property YAML files
    │   └── *.yml             # One file per property
    ├── content/              # Page content by page slug
    │   ├── home.yml
    │   ├── about-us.yml
    │   └── contact-us.yml
    ├── translations/         # Custom i18n translations
    │   ├── en.yml
    │   └── es.yml
    └── images/               # Property photos (optional)

Core Files

1. pack.yml (REQUIRED)

The main configuration file for the pack:

name: pack_name                          # Unique identifier (matches folder name)
display_name: "Human Readable Name"      # Display name
description: "Description of the pack"   # Brief description
version: "1.0"                           # Version number

# Optional - inherit from another pack
inherits_from: base

# Website Configuration
website:
  theme_name: bristol                    # Theme to use
  default_client_locale: en              # Default locale
  supported_locales:                     # Supported languages
    - en
    - es
    - de
  currency: EUR                          # Default currency
  area_unit: sqm                         # sqm or sqft

# Agency Configuration
agency:
  display_name: "Agency Name"
  email: "info@example.com"
  phone: "+1 234 567 890"
  address:
    street_address: "123 Main Street"
    city: London
    region: Greater London
    country: UK
    postal_code: "SW1A 1AA"

# Page Parts - specify which templates to use per page
page_parts:
  home:
    - key: heroes/hero_centered
      order: 1
    - key: features/feature_grid_3col
      order: 2
  about-us:
    - key: content_html
      order: 1

# Users to create
users:
  - email: admin@example.com
    role: admin
    password: demo123
  - email: agent@example.com
    role: agent
    password: demo123

2. properties/*.yml

One YAML file per property:

# Property identifier
reference: UK-VILLA-001

# Property classification (uses field_keys)
prop_type: types.villa
prop_state: states.excellent

# Location
address: "123 Park Lane"
city: London
region: Greater London
country: UK
postal_code: "W1K 7AA"
latitude: 51.5074
longitude: -0.1278

# Property Details
bedrooms: 5
bathrooms: 4
garages: 2
constructed_area: 450      # In configured area_unit
plot_area: 800
year_built: 2020

# Sale Listing (optional - omit if not for sale)
sale:
  highlighted: true
  price_cents: 500000000   # Price in cents (e.g., 5000000.00 GBP)
  title:
    en: "Luxury Villa in Mayfair"
    es: "Villa de lujo en Mayfair"
  description:
    en: "Stunning 5-bedroom villa with private garden..."
    es: "Impresionante villa de 5 dormitorios..."

# Rental Listing (optional - omit if not for rent)
rental:
  highlighted: false
  long_term: true
  short_term: false
  furnished: true
  monthly_price_cents: 1500000  # Monthly price in cents
  title:
    en: "Modern Apartment for Rent"
  description:
    en: "Beautiful modern apartment..."

# Features (reference field_keys)
features:
  - features.private_pool
  - features.private_garden
  - features.terrace
  - amenities.air_conditioning
  - amenities.alarm_system

# Image filename (from pack's images/ dir or db/seeds/images/)
image: villa_luxury.jpg

3. content/*.yml

Page content organized by page slug:

# Content keys match page part templates
heroes/hero_centered:
  pretitle:
    en: "Welcome"
    es: "Bienvenido"
  title:
    en: "Find Your Dream Home"
    es: "Encuentra tu hogar soñado"
  subtitle:
    en: "Luxury properties in prime locations"
    es: "Propiedades de lujo en ubicaciones privilegiadas"
  cta_text:
    en: "View Properties"
    es: "Ver propiedades"
  cta_link: "/search/buy"
  background_image: "db/example_images/hero_background.jpg"

features/feature_grid_3col:
  section_title:
    en: "Our Services"
    es: "Nuestros servicios"
  feature_1_icon: "fa-home"
  feature_1_title:
    en: "Buying"
    es: "Compra"
  feature_1_description:
    en: "We guide you through the buying process"
    es: "Te guiamos en el proceso de compra"

4. field_keys.yml

Property taxonomy (types, states, features, amenities):

# Property Types
types:
  villa:
    en: Villa
    es: Villa
  apartment:
    en: Apartment
    es: Apartamento
  penthouse:
    en: Penthouse
    es: Ático

# Property States
states:
  new_build:
    en: New Build
    es: Obra nueva
  excellent:
    en: Excellent
    es: Excelente
  good:
    en: Good
    es: Bueno

# Features
features:
  private_pool:
    en: Private Pool
    es: Piscina privada
  sea_views:
    en: Sea Views
    es: Vistas al mar

# Amenities
amenities:
  air_conditioning:
    en: Air Conditioning
    es: Aire acondicionado
  elevator:
    en: Elevator
    es: Ascensor

5. links.yml

Navigation structure:

# Top Navigation
- slug: home
  page_slug: home
  link_title: Home
  placement: top_nav
  sort_order: 1
  visible: true

- slug: buy
  page_slug: buy
  link_title: Buy
  placement: top_nav
  sort_order: 2
  visible: true

# Footer Navigation
- slug: footer_privacy
  page_slug: privacy
  link_title: Privacy Policy
  placement: footer
  sort_order: 1
  visible: true

Implementation

Core Class: Pwb::SeedPack

Located at lib/pwb/seed_pack.rb:

# Find and apply a pack
pack = Pwb::SeedPack.find('spain_luxury')
pack.apply!(website: website)

# Preview what will be created (dry run)
pack.preview

# Apply with options
pack.apply!(
  website: website,
  options: {
    skip_properties: false,
    skip_users: true,
    skip_content: false,
    dry_run: false,
    verbose: true
  }
)

# List all available packs
Pwb::SeedPack.available

Rake Tasks

# List available packs
rails pwb:seed_packs:list

# Preview what a pack would create
rails pwb:seed_packs:preview[pack_name]

# Apply pack to default website
rails pwb:seed_packs:apply[pack_name]

# Apply pack to specific website
rails pwb:seed_packs:apply[pack_name,website_id]

# Apply with skip options
rails pwb:seed_packs:apply_with_options[pack_name,'skip_users,skip_properties']

# Reset and apply (WARNING: destroys existing data)
rails pwb:seed_packs:reset_and_apply[pack_name]

Creating a New Seed Pack

Step 1: Create Directory Structure

mkdir -p db/seeds/packs/my_new_pack/{properties,content,translations,images}

Step 2: Create pack.yml

Start with the minimum required configuration:

name: my_new_pack
display_name: "My New Pack"
description: "Description of what this pack represents"
version: "1.0"
inherits_from: base

website:
  theme_name: bristol
  default_client_locale: en
  supported_locales: [en]
  currency: GBP
  area_unit: sqft

agency:
  display_name: "My Agency Name"
  email: "info@myagency.com"

Step 3: Add Properties

Create property files in properties/ directory:

# properties/property_001.yml
reference: MY-001
prop_type: types.house
prop_state: states.good
city: London
bedrooms: 3
bathrooms: 2
constructed_area: 1500

sale:
  price_cents: 45000000
  title:
    en: "Charming Family Home"
  description:
    en: "Beautiful 3-bedroom house..."

features:
  - features.private_garden
  - amenities.central_heating

Step 4: Add Content (Optional)

Create content files for each page:

# content/home.yml
heroes/hero_centered:
  title:
    en: "Welcome to My Agency"
  cta_text:
    en: "Browse Properties"

Step 5: Test the Pack

# Preview first
rails pwb:seed_packs:preview[my_new_pack]

# Apply to test website
rails pwb:seed_packs:apply[my_new_pack]

Inheritance

Packs can inherit from parent packs:

# Child pack inherits field_keys, links from base
inherits_from: base

When applied:

  1. Parent pack is applied first (with skip_website and skip_agency)
  2. Child pack is applied, overriding parent where specified

Key Patterns

Multi-Language Content

Always provide translations for supported locales:

title:
  en: "English Title"
  es: "Título en Español"
  de: "Deutscher Titel"

Price Format

Prices are always in cents to avoid floating-point issues:

sale:
  price_cents: 395000000  # = 3,950,000.00
rental:
  monthly_price_cents: 150000  # = 1,500.00/month

Feature References

Features reference field_keys using dot notation:

features:
  - features.private_pool      # from field_keys.yml features section
  - amenities.air_conditioning # from field_keys.yml amenities section
  - types.villa                # from field_keys.yml types section

Image Handling

Images are looked up in order:

  1. Pack's images/ directory
  2. Shared db/seeds/images/ directory
image: villa_ocean.jpg  # Filename only, no path

Existing Packs Reference

base

  • Foundation pack inherited by all others
  • Contains common field_keys and navigation links
  • No properties or users

spain_luxury

  • Spanish Costa del Sol luxury real estate scenario
  • 7 properties (villas, apartments, penthouses)
  • 3 languages (es, en, de)
  • Complete home page content

Files Reference

FileLocationPurpose
SeedPack classlib/pwb/seed_pack.rbMain implementation
Rake taskslib/tasks/seed_packs.rakeCLI interface
Base packdb/seeds/packs/base/Foundation

Content truncated.

You might also like

flutter-development

aj-geddes

Build beautiful cross-platform mobile apps with Flutter and Dart. Covers widgets, state management with Provider/BLoC, navigation, API integration, and material design.

643969

drawio-diagrams-enhanced

jgtolentino

Create professional draw.io (diagrams.net) diagrams in XML format (.drawio files) with integrated PMP/PMBOK methodologies, extensive visual asset libraries, and industry-standard professional templates. Use this skill when users ask to create flowcharts, swimlane diagrams, cross-functional flowcharts, org charts, network diagrams, UML diagrams, BPMN, project management diagrams (WBS, Gantt, PERT, RACI), risk matrices, stakeholder maps, or any other visual diagram in draw.io format. This skill includes access to custom shape libraries for icons, clipart, and professional symbols.

591705

ui-ux-pro-max

nextlevelbuilder

"UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 8 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient."

318398

godot

bfollington

This skill should be used when working on Godot Engine projects. It provides specialized knowledge of Godot's file formats (.gd, .tscn, .tres), architecture patterns (component-based, signal-driven, resource-based), common pitfalls, validation tools, code templates, and CLI workflows. The `godot` command is available for running the game, validating scripts, importing resources, and exporting builds. Use this skill for tasks involving Godot game development, debugging scene/resource files, implementing game systems, or creating new Godot components.

339397

nano-banana-pro

garg-aayush

Generate and edit images using Google's Nano Banana Pro (Gemini 3 Pro Image) API. Use when the user asks to generate, create, edit, modify, change, alter, or update images. Also use when user references an existing image file and asks to modify it in any way (e.g., "modify this image", "change the background", "replace X with Y"). Supports both text-to-image generation and image-to-image editing with configurable resolution (1K default, 2K, or 4K for high resolution). DO NOT read the image file first - use this skill directly with the --input-image parameter.

451339

fastapi-templates

wshobson

Create production-ready FastAPI projects with async patterns, dependency injection, and comprehensive error handling. Use when building new FastAPI applications or setting up backend API projects.

304231

Stay ahead of the MCP ecosystem

Get weekly updates on new skills and servers.