fix(RubyGems): support no-sudo updating for rbenv and rvm (#820)

This commit is contained in:
Yaroslav Markin
2024-06-06 14:37:06 +03:00
committed by GitHub
parent c748bb5d7a
commit 8e16174ce7

View File

@@ -120,7 +120,10 @@ pub fn run_rubygems(ctx: &ExecutionContext) -> Result<()> {
print_separator("RubyGems"); print_separator("RubyGems");
let gem_path_str = gem.as_os_str(); let gem_path_str = gem.as_os_str();
if gem_path_str.to_str().unwrap().contains("asdf") { if gem_path_str.to_str().unwrap().contains("asdf")
|| gem_path_str.to_str().unwrap().contains(".rbenv")
|| gem_path_str.to_str().unwrap().contains(".rvm")
{
ctx.run_type() ctx.run_type()
.execute(gem) .execute(gem)
.args(["update", "--system"]) .args(["update", "--system"])