开发者

I deleted a rails gem in the wrong way - what should I do?

开发者 https://www.devze.com 2023-01-16 23:08 出处:网络
So I installed rspec 2.0 beta 22 and then I deleted the folder in the library fold开发者_Python百科er on my mac (I know i\'m an idiot).

So I installed rspec 2.0 beta 22 and then I deleted the folder in the library fold开发者_Python百科er on my mac (I know i'm an idiot).

Now I can't reinstall or uninstall.

HELP!!

Thanks


Manually unpack the files from the gem (or copy them from elsewhere, eg another computer). After this, uninstall the gem to get a clean state. You may now reinstall it if you want to keep it.

Unpacking should be easy, as a gem file is just a tar with meta information and data file inside:

$ tar xvf gemfile.gem
data.tar.gz
metadata.gz

Extract the data.tar.gz and copy the lib directory back to the location you deleted before. Look at the other gem directories to find out about the structure.


I was running it from the directory. Problem solved.

0

精彩评论

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