Worthwhile to build a gem?

Discussion in 'Ruby' started by Greg Willits, Jul 2, 2008.

  1. Greg Willits

    Greg Willits Guest

    I have a project where a number of internally-developed Ruby libraries
    will need to be installed on numerous machines. Small apps will then be
    written using this set of libraries almost like a framework really.

    Is it worth considering building a gem out of this library and running a
    private gem server in order to manage these libraries? The alternative
    would be to maintain working copies (maybe in site_ruby?) from an svn
    server -- much like you'd typically maintain a Rails app on servers.

    This site seems to to be very out of date http://docs.rubygems.org/
    based on the version numbers and self-proclaimed recent updates page.

    This page http://docs.rubygems.org/read/chapter/5 says to see the
    DevelopersGuide, but I can't find such a critter anywhere, so where is
    there current info available on building gems?

    Thx.

    -- gw
    --
    Posted via http://www.ruby-forum.com/.
     
    Greg Willits, Jul 2, 2008
    #1
    1. Advertising

  2. Greg Willits

    Trans Guest

    On Jul 2, 5:14=A0pm, Greg Willits <> wrote:
    > I have a project where a number of internally-developed Ruby libraries
    > will need to be installed on numerous machines. Small apps will then be
    > written using this set of libraries almost like a framework really.


    Will these libraries all be in single project (ie. gem), or do your
    see them each as separate projects?

    > Is it worth considering building a gem out of this library and running a
    > private gem server in order to manage these libraries? The alternative
    > would be to maintain working copies (maybe in site_ruby?) from an svn
    > server -- much like you'd typically maintain a Rails app on servers.


    your using svn rather than git I take it.

    T.
     
    Trans, Jul 2, 2008
    #2
    1. Advertising

  3. Greg Willits

    Greg Willits Guest

    Trans wrote:
    > On Jul 2, 5:14pm, Greg Willits wrote:
    >> I have a project where a number of internally-developed Ruby libraries
    >> will need to be installed on numerous machines. Small apps will then be
    >> written using this set of libraries almost like a framework really.

    >
    > Will these libraries all be in single project (ie. gem), or do your
    > see them each as separate projects?


    The libraries form a single core of tools and logic upon which to build
    server side data aggregation apps.


    >> Is it worth considering building a gem out of this library and running a
    >> private gem server in order to manage these libraries? The alternative
    >> would be to maintain working copies (maybe in site_ruby?) from an svn
    >> server -- much like you'd typically maintain a Rails app on servers.

    >
    > your [you're] using svn rather than git I take it.


    svn, yes. If I changed my code with every new fasionable thing, I'd
    never get anything done. svn works just fine for me.

    -- gw


    --
    Posted via http://www.ruby-forum.com/.
     
    Greg Willits, Jul 2, 2008
    #3
  4. Greg Willits

    Eric Hodel Guest

    On Jul 2, 2008, at 14:14 PM, Greg Willits wrote:
    > I have a project where a number of internally-developed Ruby libraries
    > will need to be installed on numerous machines. Small apps will then
    > be
    > written using this set of libraries almost like a framework really.
    >
    > Is it worth considering building a gem out of this library and
    > running a
    > private gem server in order to manage these libraries? The alternative
    > would be to maintain working copies (maybe in site_ruby?) from an svn
    > server -- much like you'd typically maintain a Rails app on servers.
    >
    > This site seems to to be very out of date http://docs.rubygems.org/
    > based on the version numbers and self-proclaimed recent updates page.
    >
    > This page http://docs.rubygems.org/read/chapter/5 says to see the
    > DevelopersGuide, but I can't find such a critter anywhere, so where is
    > there current info available on building gems?


    Rake::GemPackageTask is probably what you'll find easiest for this:

    Rake::packageTask.new("package") do |p|
    p.name = PKG_NAME # string
    p.version = PKG_VERSION # string
    p.package_files = PKG_FILES # array
    end
     
    Eric Hodel, Jul 3, 2008
    #4
  5. Greg Willits

    Trans Guest

    On Jul 2, 6:59=A0pm, Greg Willits <> wrote:
    > Trans wrote:
    > > On Jul 2, 5:14pm, Greg Willits wrote:
    > >> I have a project where a number of internally-developed Ruby libraries
    > >> will need to be installed on numerous machines. Small apps will then be=


    > >> written using this set of libraries almost like a framework really.

    >
    > > Will these libraries all be in single project (ie. gem), or do your
    > > see them each as separate projects?

    >
    > The libraries form a single core of tools and logic upon which to build
    > server side data aggregation apps.


    Cool. I'd say create a gem for it. Would Capistrano be helpful?

    > >> Is it worth considering building a gem out of this library and running =

    a
    > >> private gem server in order to manage these libraries? The alternative
    > >> would be to maintain working copies (maybe in site_ruby?) from an svn
    > >> server -- much like you'd typically maintain a Rails app on servers.

    >
    > > your [you're] using svn rather than git I take it.

    >
    > svn, yes. If I changed my code with every new fasionable thing, I'd
    > never get anything done. svn works just fine for me.


    :) i can relate.

    T.
     
    Trans, Jul 3, 2008
    #5
  6. On Thu, Jul 03, 2008 at 06:14:49AM +0900, Greg Willits wrote:
    > I have a project where a number of internally-developed Ruby libraries
    > will need to be installed on numerous machines. Small apps will then be
    > written using this set of libraries almost like a framework really.
    >
    > Is it worth considering building a gem out of this library and running a
    > private gem server in order to manage these libraries? The alternative
    > would be to maintain working copies (maybe in site_ruby?) from an svn
    > server -- much like you'd typically maintain a Rails app on servers.


    yes, it is always worthwhile to build a gem :). Its good experience
    and something every ruby developer should know how to do. And if the
    code is useful outside your specific application it makes it easy to
    distribute to the rest of the world.

    This is exactly what we do at my job. Currently we have 18 gems that
    define our private codebase. We maintain an internal gem server, and
    capistrano deployment scripts to manage the installation of the gems on
    the various machines depending on their role. Our infrastructure is a
    mixture of command line, rails and merb apps, and this approach is
    working pretty well for us.

    enjoy,

    -jeremy

    --
    ========================================================================
    Jeremy Hinegardner
     
    Jeremy Hinegardner, Jul 3, 2008
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    5
    Views:
    419
    Shahid Siddiqui
    Apr 25, 2005
  2. Rashrashetta
    Replies:
    2
    Views:
    353
    kaeli
    Mar 3, 2005
  3. Luc The Perverse

    Sweet! I found a worthwhile game engine!

    Luc The Perverse, Dec 18, 2005, in forum: Java
    Replies:
    4
    Views:
    501
    Luc The Perverse
    Dec 19, 2005
  4. Developwebsites

    worthwhile learning?

    Developwebsites, Nov 23, 2003, in forum: HTML
    Replies:
    4
    Views:
    541
    Nick Howes
    Nov 24, 2003
  5. Austin 7873
    Replies:
    5
    Views:
    193
    Eric Hodel
    Jan 27, 2007
Loading...

Share This Page