开发者

Create Local Ruby Gem Repository on Windows

I am trying to create a local gem repository on a Windows box that is just a folder, no web server involved at all. This way I can stick the repository on a Windows share like you can with Mercurial or Git.

Now when I try to create a repo I get the following error:

C:\TestLocalrepo>gem generate_index -d
C:\TestLocalrepo ERROR:  While
executing gem ... (RuntimeError)
    Gem::Indexer requires that the XML Builder library be installed:
        gem install builder

I have tried running gem install builder which installs ok (3.0.0) but I still get the above error.

I read somewhere else to try installing builder-2.1.2.gem which I have but that also made no difference.

Setup Details:

OS: Windows 7 x64 Enterprise

ruby 1.9.2p0 (2010-08-18) [i386-mingw32] - installed via msi package.

Any suggestion on how to get this to work? Or is there another way I can create a gem re开发者_运维技巧pository?


When you refer to the installer, there is no MSI package, is an executable installer provided by RubyInstaller team.

Now, in relation to the error you're receiving, did you try uninstall builder 3.0.0 before?

In my case:

C:\Foo>tree
Folder PATH listing for volume Keore HD
Volume serial number is FC6C-E785
C:.
└───gems

Where gems contains rake-compiler-0.7.5.gem and having the following builder gem installed:

>gem list builder

*** LOCAL GEMS ***

builder (2.1.2)

Doing gem generate_index -d C:\Foo works using ruby 1.9.2p136 (2010-12-25) [i386-mingw32]

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜