PHPackages                             acobster/wp-cli-yaml-fixtures - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [File &amp; Storage](/categories/file-storage)
4. /
5. acobster/wp-cli-yaml-fixtures

ActiveWp-cli-command[File &amp; Storage](/categories/file-storage)

acobster/wp-cli-yaml-fixtures
=============================

Define WordPress database snapshots as simple YAML files

v0.7.0(5y ago)33.4k1[10 issues](https://github.com/acobster/wp-yaml-fixtures/issues)2MITPHPPHP &gt;=7.0CI failing

Since Jul 2Pushed 5y ago1 watchersCompare

[ Source](https://github.com/acobster/wp-yaml-fixtures)[ Packagist](https://packagist.org/packages/acobster/wp-cli-yaml-fixtures)[ RSS](/packages/acobster-wp-cli-yaml-fixtures/feed)WikiDiscussions master Synced today

READMEChangelog (8)Dependencies (7)Versions (15)Used By (2)

WP YAML Fixtures
================

[](#wp-yaml-fixtures)

[![Build Status](https://camo.githubusercontent.com/de6515357c3f8e055e266b1dd25d2a117a7a325c9e79078bad2a2d14676b2bc9/68747470733a2f2f7472617669732d63692e6f72672f61636f62737465722f77702d79616d6c2d66697874757265732e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/acobster/wp-yaml-fixtures)

A WP-CLI command for describing your WordPress database content in, and importing from, YAML files. Built for testing and scaffolding quickly.

### Getting Started

[](#getting-started)

Install and activate this repo as a plugin.

```
git clone git@github.com:acobster/wp-yaml-fixtures.git ./wp-content/plugins/yaml-fixtures
wp plugin activate yaml-fixtures

```

Set up a YAML file.

```
---
# my-example.yaml
name: My Test Site
description: Just another database described in YAML

users:
- email: admin@example.com
  login: admin
  role: administrator
  password: meep

posts:
- title: My Blog Post
  type: post

  content: 'Lorem ipsum dolor sit amet'

  terms:
    category:
    - special

taxonomies:
  category:
  - name: Special
  - name: Snowflake
  - name: Unicorn
...

```

Run the WP-CLI command.

```
wp fixture install my-example.yaml

```

💥 Your database has now been cleaned and populated with fresh data. 💥

### YAML for Days!

[](#yaml-for-days)

Here's a more in-depth example of the kinds of things you can describe in your YAML:

```
---
name: My Test Site
description: Just another database described in YAML

# tell me what **not** to delete
blank_slate:
  preserve_users:
  - me
  - myself
  - i@email.me
  - 123 # ID

# insert users
users:
- email: admin@example.com
  login: admin
  role: administrator
  password: meep
- email: johndoe@example.com
  login: johndoe
  role: editor
  password: mop
  meta:
    my_info: 'This info is v important'
    moar_info: 'here iz sum moar infoz'

# insert arbitrary post data
posts:
- title: My Blog Post
  type: post

- title: Page with a Custom Slug
  slug: yep-this-heres-a-completely-custom-slug
  type: page

  content: |
    Lorem ipsum dolor sit amet, consectetur adipiscing elit.
    Nunc haec primum fortasse audientis servire debemus.

    Sumenda potius quam expetenda.

    Mihi quidem Homerus huius modi quiddam vidisse videatur in iis,
    quae de Sirenum cantibus finxerit.
    Ut in geometria, prima si dederis, danda sunt omnia.

  # specify any number of terms, across taxonomies
  terms:
    page_type:
    - custom-term-slug
    category:
    - special

- title: A Post with Some Meta Fields
  type: page
  # oh and I want to nest this page
  parent: bar

  # specify arbitrary meta fields
  meta:
    my_custom_field: Some custom value

    # specify multiple values for the same key!
    # these will be inserted as three wp_postmeta rows
    another_field:
    - 'value #1'
    - 'value #2'
    - 'value #3'

  terms:
    page_type:
    - custom-term-slug
    - another
    - and-another

# Define taxonomy terms
taxonomies:
  category:
  - name: Special
  - name: Snowflake
  - name: Unicorn

  page_type:
  - name: Page Type
    slug: custom-term-slug
  - name: Another Page Type
    slug: another
  - name: And Another
...

```

Support
-------

[](#support)

WP YAML Fixtures supports WordPress 4.8+ and PHP 7.0 through 7.2.x. Support for PHP 7.3 is a work in progress.

License
-------

[](#license)

MIT

###  Health Score

26

—

LowBetter than 41% of packages

Maintenance0

Infrequent updates — may be unmaintained

Popularity24

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity56

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~76 days

Recently: every ~150 days

Total

11

Last Release

2159d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/320688?v=4)[Coby Tamayo](/maintainers/acobster)[@acobster](https://github.com/acobster)

---

Top Contributors

[![acobster](https://avatars.githubusercontent.com/u/320688?v=4)](https://github.com/acobster "acobster (3 commits)")

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/acobster-wp-cli-yaml-fixtures/health.svg)

```
[![Health](https://phpackages.com/badges/acobster-wp-cli-yaml-fixtures/health.svg)](https://phpackages.com/packages/acobster-wp-cli-yaml-fixtures)
```

###  Alternatives

[prestashop/prestashop

PrestaShop is an Open Source e-commerce platform, committed to providing the best shopping cart experience for both merchants and customers.

9.1k17.8k](/packages/prestashop-prestashop)[craftcms/cms

Craft CMS

3.6k3.6M3.1k](/packages/craftcms-cms)[tempest/framework

The PHP framework that gets out of your way.

2.2k34.4k15](/packages/tempest-framework)[sylius/resource-bundle

Resource component for Sylius.

23610.8M235](/packages/sylius-resource-bundle)[rcsofttech/audit-trail-bundle

Enterprise-grade, high-performance Symfony audit trail bundle. Automatically track Doctrine entity changes with split-phase architecture, multiple transports (HTTP, Queue, Doctrine), and sensitive data masking.

1189.8k](/packages/rcsofttech-audit-trail-bundle)[friendsoftypo3/content-blocks

TYPO3 CMS Content Blocks - Content Types API | Define reusable components via YAML

103519.9k53](/packages/friendsoftypo3-content-blocks)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
