Update installed gems

D

Dale Martenson

I build my own gems as a way to distribute a variety of utilities where
I work. What is the best way to install updates?

If I distribute a new gem file, provided by email/ftp/web how can a user
install the update? Should they just re-install? "gem update <blah>"
doesn't seem to have a "--local" option. If you place the file in your
current directory, it seems to be ignored and I am not sure how to
specify a gem update file. While "gem install" will automatically look
both for the gem locally and remotely, "gem update" doesn't.

Maybe, this is a bad question since "gem update" is meant to look for
updates that are not locally available. But this doesn't seem consistent
with the way "gem install works".

How difficult is it to implement a simple gem server?
 
E

Ezra Zygmuntowicz

I build my own gems as a way to distribute a variety of utilities
where I work. What is the best way to install updates?

If I distribute a new gem file, provided by email/ftp/web how can a
user install the update? Should they just re-install? "gem update
<blah>" doesn't seem to have a "--local" option. If you place the
file in your current directory, it seems to be ignored and I am not
sure how to specify a gem update file. While "gem install" will
automatically look both for the gem locally and remotely, "gem
update" doesn't.

Maybe, this is a bad question since "gem update" is meant to look
for updates that are not locally available. But this doesn't seem
consistent with the way "gem install works".

How difficult is it to implement a simple gem server?

$ gem_server
On the command line. This serves you rdoc documentation and it can
act as a local gem repository server. I've never set up the local
repo so perhaps someone else can chime in./ But it already has
features to do exactly what you want.
HTH-
-Ezra Zygmuntowicz
Yakima Herald-Republic
WebMaster
509-577-7732
(e-mail address removed)
 
D

Dale Martenson

---- Original message from Ezra Zygmuntowicz on 8/9/2005 12:28 PM:
$ gem_server
On the command line. This serves you rdoc documentation and it can
act as a local gem repository server. I've never set up the local
repo so perhaps someone else can chime in./ But it already has
features to do exactly what you want.
I will give that a try, but it seems like it is meant to serve your
installed gems. If someone wanted to host and variety of gems (different
versions of gems -- stable, bleeding edge, etc.), I don't think
"gem_server" is the answer. Any ideas what is? Or am I understanding
this incorrectly.
 
C

Chad Fowler

=20
---- Original message from Ezra Zygmuntowicz on 8/9/2005 12:28 PM:
=20
I will give that a try, but it seems like it is meant to serve your
installed gems. If someone wanted to host and variety of gems (different
versions of gems -- stable, bleeding edge, etc.), I don't think
"gem_server" is the answer. Any ideas what is? Or am I understanding
this incorrectly.
=20
=20

Hi. gem_server can definitely do what you want. You can serve gems
from an alternate directory (with the -d param) if you want to include
a lot of bleeding edge gems that you don't want "installed" on the
host system. Also, if you look in the rubygems distribution under the
"bin" directory, you'll find generate_yaml_index.rb, which you can
use to create a static yaml file that you could serve with your web
server of choice. So you'd have:

http://yourserver.whatever.org/yaml
and
http://youserver.whatever.org/gems/mygems.gem

If you have that structure available, you can serve gems from a
normal web server.

--=20
Chad Fowler
http://chadfowler.com
http://rubycentral.org=20
http://rubygarden.org=20
http://rubygems.rubyforge.org (over 700,000 gems served!)
 
D

Dale Martenson

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
---- Original message from Chad Fowler&nbsp; on 8/10/2005 6:41 AM:
<blockquote cite="(e-mail address removed)"
type="cite">
</pre>
<blockquote type="cite">
<pre wrap="">---- Original message from Ezra Zygmuntowicz on 8/9/2005 12:28 PM:

</pre>
<blockquote type="cite">
<pre wrap="">On Aug 9, 2005, at 10:18 AM, Dale Martenson wrote:

</pre>
<blockquote type="cite">
<pre wrap="">I build my own gems as a way to distribute a variety of utilities
where I work. What is the best way to install updates?

If I distribute a new gem file, provided by email/ftp/web how can a
user install the update? Should they just re-install? "gem update
&lt;blah&gt;" doesn't seem to have a "--local" option. If you place the
file in your current directory, it seems to be ignored and I am not
sure how to specify a gem update file. While "gem install" will
automatically look both for the gem locally and remotely, "gem
update" doesn't.

Maybe, this is a bad question since "gem update" is meant to look
for updates that are not locally available. But this doesn't seem
consistent with the way "gem install works".

How difficult is it to implement a simple gem server?
</pre>
</blockquote>
<pre wrap="">
$ gem_server
On the command line. This serves you rdoc documentation and it can
act as a local gem repository server. I've never set up the local
repo so perhaps someone else can chime in./ But it already has
features to do exactly what you want.

</pre>
</blockquote>
<pre wrap="">I will give that a try, but it seems like it is meant to serve your
installed gems. If someone wanted to host and variety of gems (different
versions of gems -- stable, bleeding edge, etc.), I don't think
"gem_server" is the answer. Any ideas what is? Or am I understanding
this incorrectly.


</pre>
</blockquote>
<pre wrap=""><!---->
Hi. gem_server can definitely do what you want. You can serve gems
from an alternate directory (with the -d param) if you want to include
a lot of bleeding edge gems that you don't want "installed" on the
host system. Also, if you look in the rubygems distribution under the
"bin" directory, you'll find generate_yaml_index.rb, which you can
use to create a static yaml file that you could serve with your web
server of choice. So you'd have:

<a class="moz-txt-link-freetext" href="http://yourserver.whatever.org/yaml">http://yourserver.whatever.org/yaml</a>
and
<a class="moz-txt-link-freetext" href="http://youserver.whatever.org/gems/mygems.gem">http://youserver.whatever.org/gems/mygems.gem</a>

If you have that structure available, you can serve gems from a
normal web server.

</pre>
</blockquote>
Thanks for the information. I will give it a try.<br>
</body>
</html>
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,596
Members
45,139
Latest member
JamaalCald
Top