ruby鐗堟湰鍗囩骇(杞笘)

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了ruby鐗堟湰鍗囩骇(杞笘)相关的知识,希望对你有一定的参考价值。

鏍囩锛?a href='http://www.mamicode.com/so/1/login' title='login'>login   source   ror   鍗囩骇   ISE   func   nta   code   gemset   

鍙傝€冭繛鎺ワ細https://blog.csdn.net/qq_26440803/article/details/82717244

 

鍦ㄧ嚎瀹夎ruby

浣跨敤yum鍦ㄧ嚎瀹夎ruby锛屽畨瑁呯殑鐗堟湰涓?.0.0銆?br>
yum install ruby

ruby -v

 娣诲姞ruby浠撳簱

    娣诲姞aliyun闀滃儚骞舵娴婻uby鐗堟湰

gem sources -a http://mirrors.aliyun.com/rubygems/

ruby -v

瀹夎RAM

    RAM锛圧uby Version Manager 锛夋槸涓€娆綬AM鐨勫懡浠よ宸ュ叿锛屽彲浠ヤ娇鐢≧AM杞绘澗瀹夎锛岀鐞哛uby鐗堟湰銆俁VM鍖呭惈浜哛uby鐨勭増鏈鐞嗗拰Gem搴撶鐞?gemset)

鍙互浣跨敤濡備笅鍛戒护杩涜瀹夎RAM锛?br>
    gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
     
    curl -sSL https://get.rvm.io | bash -s stable

鍑虹幇濡備笅淇℃伅浠h〃瀹夎鎴愬姛锛?/p>

1
2
3
4
5
6
7
8
9
10
11
12
GPG verified 鈥?home/sidian/.rvm/archives/rvm-1.29.10.tgz鈥?/code>
Installing RVM to /home/sidian/.rvm/
    Adding rvm PATH line to /home/sidian/.profile /home/sidian/.mkshrc /home/sidian/.bashrc /home/sidian/.zshrc.
    Adding rvm loading line to /home/sidian/.profile /home/sidian/.bash_profile /home/sidian/.zlogin.
Installation of RVM in /home/sidian/.rvm/ is almost complete:
 
  * To start using RVM you need to run `source /home/sidian/.rvm/scripts/rvm`
    in all your open shell windows, in rare cases you need to reopen all shell windows.
Thanks for installing RVM ??
Please consider donating to our open collective to help us maintain RVM.
 
??  Donate: https://opencollective.com/rvm/donate

 


鏇存柊閰嶇疆鏂囦欢锛屼娇鍏剁珛椹敓鏁堬細

source /etc/profile.d/rvm.sh  鎴戞槸鎵ц杩欎釜`source /home/sidian/.rvm/scripts/rvm`



鏌ョ湅RVM鐗堟湰淇℃伅锛屽鏋滃彲浠ヤ唬琛ㄥ畨瑁呮垚鍔熴€?br>
rvm -v

鎺ヤ笅鏉ユ煡鐪婻uby鐗堟湰锛?br>
    rvm list known
     
    # MRI Rubies
    [ruby-]1.8.6[-p420]
    [ruby-]1.8.7[-head] # security released on head
    [ruby-]1.9.1[-p431]
    [ruby-]1.9.2[-p330]
    [ruby-]1.9.3[-p551]
    [ruby-]2.0.0[-p648]
    [ruby-]2.1[.10]
    [ruby-]2.2[.10]
    [ruby-]2.3[.7]
    [ruby-]2.4[.4]
    [ruby-]2.5[.1]
    [ruby-]2.6[.0-preview2]
    ruby-head
     
    # for forks use: rvm install ruby-head-<name> --url https://github.com/github/ruby.git --branch 2.2
     
    # JRuby
    jruby-1.6[.8]
    jruby-1.7[.27]
    jruby-9.1[.17.0]
    jruby[-9.2.0.0]
    jruby-head
     
    # Rubinius
    rbx-1[.4.3]
    rbx-2.3[.0]
    rbx-2.4[.1]
    rbx-2[.5.8]
    rbx-3[.100]
    rbx-head
     
    # TruffleRuby
    truffleruby[-1.0.0-rc2]
     
    # Opal
    opal
     
    # Minimalistic ruby implementation - ISO 30170:2012
    mruby-1.0.0
    mruby-1.1.0
    mruby-1.2.0
    mruby-1.3.0
    mruby-1[.4.0]
    mruby[-head]
     
    # Ruby Enterprise Edition
    ree-1.8.6
    ree[-1.8.7][-2012.02]
     
    # Topaz
    topaz
     
    # MagLev
    maglev-1.0.0
    maglev-1.1[RC1]
    maglev[-1.2Alpha4]
    maglev-head
     
    # Mac OS X Snow Leopard Or Newer
    macruby-0.10
    macruby-0.11
    macruby[-0.12]
    macruby-nightly
    macruby-head
     
    # IronRuby
    ironruby[-1.1.3]

瀹夎Ruby锛屼粠涓婇潰鏌ュ埌鐨勪俊鎭殢渚挎壘涓€涓瘮2.2.2鐗堟湰瑕侀珮鐨勫氨琛岋細

rvm install 2.5

鍑虹幇濡備笅淇℃伅锛屼唬琛ㄥ畨瑁呮垚鍔燂細

1
2
3
4
5
6
7
8
9
10
11
12
13
[sidian@VM_0_17_centos ruby_study]$ rvm install 2.5
Searching for binary rubies, this might take some time.
No binary rubies available for: centos/7/x86_64/ruby-2.5.7.
Continuing with compilation. Please read 鈥榬vm help mount鈥?/code> to get more information on binary rubies.
Checking requirements for centos.
Installing requirements for centos.
Installing required packages: patch, autoconf, automake, bison, gcc-c++, libtool, patch, readline-devel, sqlite-devel......|
Requirements installation successful.
Installing Ruby from source to: /home/sidian/.rvm/rubies/ruby-2.5.7, this may take a while depending on your cpu(s)...
ruby-2.5.7 - #downloading ruby-2.5.7, this may take a while depending on your connection...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
 77 13.1M   77 10.2M    0     0  14986      0  0:15:20  0:11:55  0:03:25 23048

 杩欓噷鐨勪笅杞芥瘮杈冩參锛岄渶瑕佺瓑寰呮瘮杈冮暱鏃堕棿
楠岃瘉鐗堟湰锛?br>
鎴愬姛鍗囩骇銆?br> 娉ㄦ剰锛?br>
濡傛灉浣跨敤rvm瀹夎鍙戠幇涓嬭浇缂撴參锛屽彲浠ヨ€冭檻鍒犻櫎鍘熸潵鐨勪粨搴撳湴鍧€锛屽彧淇濈暀闃块噷浜戦暅鍍忋€?/p>

gem sources --remove https://rubygems.org/
















































































































以上是关于ruby鐗堟湰鍗囩骇(杞笘)的主要内容,如果未能解决你的问题,请参考以下文章

杞欢宸ョ▼鐞嗚

KaliLinux鍒囨崲python鐗堟湰

svn鐗堟湰鎺у埗

浣跨敤Pycharm鑷甫Git瀹炵幇鐗堟湰绠$悊

iOS13.6GM鏉ヨ銆乮OS14鍏祴鐗堛€乮OS13.5鎵嬫満绔鍚嶇画绛俱€乽nc0ver5.2.1