asdf-ruby
asdf-ruby copied to clipboard
"No preset version installed" error while using mruby
Complete log:
No preset version installed for command ruby2d
Please install a version by running one of the following:
asdf install ruby mruby-3.0.0
or add one of the following versions in your config file at /home/ashvith/Documents/ruby2d/.tool-versions
ruby 3.1.1
I've also tried asdf reshim, and even restarted my shell, but it won't work. One thing that I've noticed, is that when I start with a fresh installation of asdf-ruby, without any Ruby installed, it throws a build error. MRuby only builds when vanilla Ruby is installed.
Hi @Ashvith , what command did you run that generated this output?
Are you sure you have installed and configured asdf correctly? Have you installed all dependencies for ruby and mruby on your system?
Can you provide the output of asdf info? Thanks!
@Stratus3D this is the log from asdf-info
OS:
Linux fedora 5.16.15-201.fc35.x86_64 #1 SMP PREEMPT Thu Mar 17 05:45:13 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
SHELL:
GNU bash, version 5.1.8(1)-release (x86_64-redhat-linux-gnu)
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
ASDF VERSION:
v0.9.0-9ee24a3
ASDF ENVIRONMENT VARIABLES:
ASDF_DIR=/home/ashvith/.asdf
ASDF INSTALLED PLUGINS:
java https://github.com/halcyon/asdf-java.git master e0fdc17
nodejs https://github.com/asdf-vm/asdf-nodejs.git master 364c078
python https://github.com/danhper/asdf-python.git master 57a4d72
ruby https://github.com/asdf-vm/asdf-ruby.git master de49662
yarn https://github.com/twuni/asdf-yarn.git main 376c540
I am pretty sure that I have installed all the dependencies for both asdf and asdf-ruby.
Hi @Ashvith , what command did you run that generated this output?
Can you provide the full sequence of commands and output that resulted in the issue you reported? I am not familiar with Fedora.
Hi @Ashvith , what command did you run that generated this output?
Can you provide the full sequence of commands and output that resulted in the issue you reported? I am not familiar with Fedora.
- Install asdf and asdf-ruby.
- Execute
asdf install ruby mruby-3.0.0 - Install ruby2d for mruby using
gem install ruby2d - Log prints on screen:
No preset version installed for command gem
Please install a version by running one of the following:
asdf install ruby mruby-3.0.0
or add one of the following versions in your config file at /home/ashvith/.tool-versions
ruby 3.1.1
ruby 2.7.5
ruby 3.0.3
If after running asdf install ruby mruby-3.0.0 you do:
asdf reshimgem install ruby2d
Does that change the output at all?
Also, what does asdf which gem output? Did you try any other version of mruby? I don't know much about mruby so I'd assume gem ships with it, but it might be good to verify.
What I've noticed is that none of the binstubs (I'm assuming that's why they're called?) are working. Neither bundler, nor gem, the only exception being ruby and irb (there is another one called mruby but that one also probably does not work). I've tried irb, and except for a few basic operations, the rest of them do not work.
@Ashvith correct me if I am wrong, but it doesn't appear that mruby 3.0.0 ships with gem or bundler. On my system all I see this:
$ ls ~/.asdf/installs/ruby/mruby-3.0.0/bin
irb mirb mrbc mruby mruby-config mruby-strip ruby
As such I don't think this is a bug with asdf-ruby.