Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // To install
- # Install dependency
- apt install libtool -y
- # The version of your Ruby instance
- version=3.3
- underVersion=3.3.0
- wget https://cache.ruby-lang.org/pub/ruby/$version/ruby-$underVersion.tar.gz
- gunzip ruby-$underVersion.tar.gz
- tar xvf ruby-$underVersion.tar
- mv ruby-$underVersion /usr/local/ruby
- rm -r ruby-$underVersion.tar
- cd /usr/local/ruby
- cp -r /usr/lib/x86_64-linux-gnu/pkgconfig/* /usr/local/lib/pkgconfig
- bash configure --disable-install-rdoc --disable-install-capi --prefix=/usr/local --with-ext=psych
- make install
- ln ruby /usr/bin
- ln bin/* /usr/bin
- // To uninstall
- [[ -d /usr/local/ruby ]] && rm -r /usr/local/ruby
- [[ -f /usr/local/bin/gem ]] && rm -r /usr/local/bin/gem
- [[ -f /usr/local/bin/ruby ]] && rm -r /usr/local/bin/ruby
- [[ -d /usr/local/share/doc/ruby ]] && rm -r /usr/local/share/doc/ruby
- [[ -d /usr/local/include/$underVersion ]] && rm -r /usr/local/include/$underVersion
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement