# Proper way to indicate dependencies?

**URL:** <https://www.ruby-forum.com/t/proper-way-to-indicate-dependencies/69659>\
**Category:** Engines\
**Created:** [September 22, 2006, 7:13pm UTC](https://www.ruby-forum.com/t/proper-way-to-indicate-dependencies/69659 "2006-09-22T19:13:58Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![folke](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/a9a28c/32.png) [@folke](https://www.ruby-forum.com/u/folke)\
**Post date:** [September 22, 2006, 7:13pm UTC](https://www.ruby-forum.com/t/proper-way-to-indicate-dependencies/69659/1 "2006-09-22T19:13:58Z")

</div>

I’m writing an engine for reuse that requires some other plugins -  
what’s the right way to indicate those dependencies? Obviously, since  
there’s no vendor directory under the engine, that code can’t be  
bundled with the engine itself.

Thanks!

–  
- Adam

\*\* Expert Technical Project and Business Management  
\*\*\*\* System Performance Analysis and Architecture  
\*\*\*\*\*\* [[http://www.adamfields.com](http://www.adamfields.com) ]

[[Adam Fields (weblog) - - entertaining hundreds of millions of eyeball atoms every day](http://www.aquick.org/blog) ] … Blog  
[[Adam Fields Resume](http://www.adamfields.com/resume.html) ]… Experience  
[[Adam Fields | Flickr](http://www.flickr.com/photos/fields) ] … Photos  
[[http://www.aquicki.com/wiki](http://www.aquicki.com/wiki) ]…Wiki

---

<div class="post-metadata">

**Author:** ![folke](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/a9a28c/32.png) [@folke](https://www.ruby-forum.com/u/folke)\
**Post date:** [September 24, 2006, 9:00pm UTC](https://www.ruby-forum.com/t/proper-way-to-indicate-dependencies/69659/2 "2006-09-24T21:00:23Z")

</div>

The simplest way is just to check/install those plugins when  
installing the engine - see the install.rb in the login engine for an  
example.

Adding the information to the README is also a great idea.

- james

---

<div class="post-metadata">

**Author:** ![folke](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/a9a28c/32.png) [@folke](https://www.ruby-forum.com/u/folke)\
**Post date:** [October 24, 2006, 10:48pm UTC](https://www.ruby-forum.com/t/proper-way-to-indicate-dependencies/69659/3 "2006-10-24T22:48:54Z")

</div>

I seen a pretty cool hook in one of the engines I installed…

Create an install.rb file that contains something like the following.

# Install the engines plugin if it has been already

unless File.exist?(File.dirname( **FILE** ) + “/…/engines”)  
Commands::Plugin.parse!([‘install’,  
‘[http://svn.rails-engines.org/plugins/engines](http://svn.rails-engines.org/plugins/engines)’])  
end

-NSHB

On 9/24/06, James A. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> > what’s the right way to indicate those dependencies? Obviously, since  
> > \*\*\*\*\*\* [[http://www.adamfields.com](http://www.adamfields.com) ]
> 
> –
> 
> - J \*  
> ~
> 
> * * *
> 
> engine-users mailing list  
> removed\_email\_address@domain.invalid  
> [http://lists.rails-engines.org/listinfo.cgi/engine-users-rails-engines.org](http://lists.rails-engines.org/listinfo.cgi/engine-users-rails-engines.org)

–  
Nathaniel Steven Henry Brown

Open Source Insight - [http://nshb.net](http://nshb.net)  
Open Source Development - [http://inimit.com](http://inimit.com)  
Open Source Training - [http://osevents.com](http://osevents.com)
