0.03
Low commit activity in last 3 years
A long-lived project that still receives updates
CLI tool to generate and manage Spree Commerce extensions
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Runtime

~> 1.0
 Project Readme

Spree Extension

Gem Version

CLI tool for generating and managing Spree Commerce extensions.

Compatibility

spree_extension Spree
2.x 6.0+
1.x 5.x

To scaffold an extension for Spree 5, install the 1.x version: gem install spree_extension -v '~> 1.0'.

Installation

gem install spree_extension

Usage

Create a new extension

spree-extension create my_extension

This creates a spree_my_extension directory with a complete extension scaffold: a Rails engine depending on spree_core and spree_api, directories for models, Store and Admin API controllers and serializers, services and event subscribers, an initializer for permission scopes and workflow hooks, a test setup based on spree_dev_tools, and CI configuration.

An extension is backend code only. Admin screens for your extension are built as a dashboard plugin, scaffolded with:

npx @spree/cli plugin new my-extension

Check version

spree-extension version

After generating

cd spree_my_extension
bundle install
bundle exec rake test_app
bundle exec rspec

Documentation

For a walkthrough of building an extension, see Creating a Spree extension.

License

Spree Extension is released under the MIT License.