Escape all shell arguments uniformly
This commit is contained in:
@@ -18,8 +18,8 @@
|
||||
# Normal gem packages can be used outside of bundler; a binstub is created in
|
||||
# $out/bin.
|
||||
|
||||
{ lib, ruby, bundler, fetchurl, fetchgit, makeWrapper, git,
|
||||
buildRubyGem, darwin
|
||||
{ lib, fetchurl, fetchgit, makeWrapper, git, darwin
|
||||
, ruby, bundler
|
||||
} @ defs:
|
||||
|
||||
lib.makeOverridable (
|
||||
@@ -53,7 +53,6 @@ lib.makeOverridable (
|
||||
, ...} @ attrs:
|
||||
|
||||
let
|
||||
shellEscape = x: "'${lib.replaceChars ["'"] [("'\\'" + "'")] x}'";
|
||||
src = attrs.src or (
|
||||
if type == "gem" then
|
||||
fetchurl {
|
||||
@@ -165,7 +164,7 @@ stdenv.mkDerivation (attrs // {
|
||||
${src} \
|
||||
${attrs.rev} \
|
||||
${version} \
|
||||
${shellEscape (toString buildFlags)}
|
||||
${lib.escapeShellArgs buildFlags}
|
||||
''}
|
||||
|
||||
${lib.optionalString (type == "gem") ''
|
||||
|
||||
Reference in New Issue
Block a user