Share parts of config.rb in multiple middleman projects

Hi Guys,

I have a few websites that I have built with middleman and would like to share a few common settings between them. Particularly caching policies like:

caching_policy ‘text/css’, max_age: (60 * 60 * 24 * 365)
caching_policy ‘text/javascript’, max_age: (60 * 60 * 24 * 365)

I have tried to put them into a separate .rb file and then
require “…/cache_settings.rb”

But unfortunately I am getting this error:
middleman_shared/cache_settings.rb:1:in <top (required)>': undefined method caching_policy’ for main:Object (NoMethodError)

I hope you have an answer for this!

Greetings, Kim