Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where do I put non-Ruby files in my gem?

I want to put an Upstart config file in my Ruby gem. Here's my current best guess

Gem::Specification.new do |s|

  # ...

  s.files = %w(
    lib/rt_watchdog.rb
    lib/upstart/rt_watchdog.conf
    bin/rt_watchdog
  )
end

In general, where do configuration files and other types of scripts go in a gem?

Update: I changed the path in my example from Upstart/rt_watchdog.conf to lib/upstart/rt_watchdog.conf as that's what I've decided to go with for now, but I still don't feel great about it.

like image 634
Justin Force Avatar asked Nov 14 '22 11:11

Justin Force


1 Answers

Rails uses a config directory in the root of the app and Rails conventions are pretty well represented throughout the Ruby community.

like image 134
Patrick Klingemann Avatar answered Dec 10 '22 14:12

Patrick Klingemann