2013-06-05 52 views
0

我是Ruby新手,并且正在使用终端。我安装了rvm,但我似乎无法安装Ruby 1.9.3。这个问题似乎与rsync和端口树同步。我不知道这是什么意思。安装RVM:同步本地端口树失败rsync

我试过寻找其他的解决方案,但没有一个与rvm相关(我可以理解,他们都只关注autoupdated macports自身)。我也看到了有关proxys的一些事情,但是如果那是真的,我不知道我需要做什么。他们都主要关注macports,并使用诸如“sudo”或-d这样的词语进行环绕,当我试图安装Ruby时,我不知道该如何做。以下是我得到:

$ rvm install 1.9.3 
Searching for binary rubies, this might take some time. 
No binary rubies available for: osx/10.7/x86_64/ruby-1.9.3-p429. 
Continuing with compilation. Please read 'rvm mount' to get more information on binary rubies. 
Installing requirements for osx, might require sudo password. 
Installing macports............................................................................................................................................................................................................................................................................................................................Password: 
............................................................................................................................................................................................................................................. 
DEBUG: Copying /Users/Elvis/Library/Preferences/com.apple.dt.Xcode.plist to /opt/local/var/macports/home/Library/Preferences 
DEBUG: MacPorts sources location: /opt/local/var/macports/sources/rsync.macports.org/release/tarballs 
---> Updating MacPorts base sources using rsync 
receiving file list ... done 
base.tar 

sent 58 bytes received 955032 bytes 272882.86 bytes/sec 
total size is 3594240 speedup is 3.76 
receiving file list ... done 
base.tar.rmd160 

sent 58 bytes received 635 bytes 1386.00 bytes/sec 
total size is 512 speedup is 0.74 
DEBUG: successful verification with key /opt/local/share/macports/macports-pubkey.pem 
DEBUG: /usr/bin/tar -C /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/tmp -xf /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/base.tar 
MacPorts base version 2.1.3 installed, 
DEBUG: Rebuilding and reinstalling MacPorts if needed 
MacPorts base version 2.1.3 downloaded. 
---> Updating the ports tree 
Synchronizing local ports tree from rsync://rsync.macports.org/release/tarballs/ports.tar 
DEBUG: /usr/bin/rsync -rtzv --delete-after rsync://rsync.macports.org/release/tarballs/ports.tar /opt/local/var/macports/sources/rsync.macports.org/release/tarballs 
receiving file list ... done 
ports.tar 
WARNING: ports.tar failed verification -- update discarded (will try again). 
rsync: read errors mapping "/tarballs/ports.tar" (in release): No data available (61) 
ports.tar 

sent 80 bytes received 11948570 bytes 682780.00 bytes/sec 
total size is 53186560 speedup is 4.45 
rsync error: some files could not be transferred (code 23) at /SourceCache/rsync/rsync-42/rsync/main.c(1400) [generator=2.6.9] 
Command failed: /usr/bin/rsync -rtzv --delete-after rsync://rsync.macports.org/release/tarballs/ports.tar /opt/local/var/macports/sources/rsync.macports.org/release/tarballs 
Exit code: 23 
Error: Synchronization of the local ports tree failed doing rsync 
DEBUG: Couldn't sync the ports tree: Synchronization of 1 source(s) failed 
    while executing 
"macports::selfupdate [array get global_options] base_updated" 
Error: /Users/Elvis/.rvm/bin/port: port selfupdate failed: Couldn't sync the ports tree: Synchronization of 1 source(s) failed 
Elviss-MacBook-Pro:~ Elvis$ ./port -d selfupdate 
-bash: ./port: No such file or directory 

我试着使用一些关键字/答案我在最后,这也解释了./port线下线上看到的。我从xcode安装了命令行。安装自制软件可以解决这个问题吗?我会很感激任何帮助!

回答

-1

确保下面的命令正确

运行
port selfupdate 

,然后再次尝试

+0

甜那肯定帮我到正确的方向@mpapis!非常感谢!对于将来出现此问题的其他人,此行对我有用: sudo port -d selfupdate – xulander

+0

“-d”标志是做什么的?如果没有它,它有什么不同? – mpapis

+0

-d标志用于更“详细的输出”。运行只是端口selfupdate给了我这个错误: 错误:/Users/Elvis/.rvm/bin/port:端口selfupdate失败:错误同步MacPorts源:命令执行失败 我认为sudo可能刚刚完成了这项工作! – xulander