From 8b728e4056734b906c0117d00010070470057a42 Mon Sep 17 00:00:00 2001 From: Gwendolyn Boatrite Date: Sat, 10 Dec 2022 15:38:46 -0600 Subject: [PATCH] Fix cloning gem when destination path contains spaces This was how clone command was previously being generated, for example: ``` git clone --recursive --branch "master" --depth 1 https://github.com/mattn/mruby-onig-regexp.git /path/to mruby with spaces/mruby-3.1.0/build/repos/wasm/mruby-onig-regexp ``` Now it's changed so the path is quoted and will work when containing spaces: ``` git clone --recursive --branch "master" --depth 1 https://github.com/mattn/mruby-onig-regexp.git "/path/to mruby with spaces/mruby-3.1.0/build/repos/wasm/mruby-onig-regexp" ``` Similar for the other commands. --- lib/mruby/build/command.rb | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lib/mruby/build/command.rb b/lib/mruby/build/command.rb index 31a595ef0..c8a3037ee 100644 --- a/lib/mruby/build/command.rb +++ b/lib/mruby/build/command.rb @@ -25,11 +25,7 @@ module MRuby end def shellquote(s) - if ENV['OS'] == 'Windows_NT' - "\"#{s}\"" - else - "#{s}" - end + "\"#{s}\"" end private