Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Reload middleman when data/ file change

Tags:

ruby

middleman

How do I force middleman to reload when I edit the data file?

For example. This is my app:

├── Gemfile
├── Gemfile.lock
├── config.rb
├── data
│   └── products.yml
└── source
    ├── ...

When I edit data/products.yml the data does not appear on the site until I manually restart the server with bundle exec middleman.

like image 960
luk3thomas Avatar asked Oct 29 '25 10:10

luk3thomas


1 Answers

It works if you manually add data to the reload paths

middleman server --reload-paths data/

https://github.com/middleman/middleman/issues/726

like image 186
luk3thomas Avatar answered Oct 31 '25 02:10

luk3thomas