summary refs log tree commit diff
diff options
context:
space:
mode:
authornonsequitur <cornelius.mika@gmail.com>2017-08-07 15:42:16 +0200
committerzimbatm <zimbatm@zimbatm.com>2017-08-07 14:42:16 +0100
commitf37972588db25ef22f5071fab64ab1a3e3a86c0a (patch)
tree90938516ab3b707796af69248121d7d29be55b15
parent2203908e5fa7529183f43b6a9e7e11559b1fcde6 (diff)
downloadnixpkgs-f37972588db25ef22f5071fab64ab1a3e3a86c0a.tar
nixpkgs-f37972588db25ef22f5071fab64ab1a3e3a86c0a.tar.gz
nixpkgs-f37972588db25ef22f5071fab64ab1a3e3a86c0a.tar.bz2
nixpkgs-f37972588db25ef22f5071fab64ab1a3e3a86c0a.tar.lz
nixpkgs-f37972588db25ef22f5071fab64ab1a3e3a86c0a.tar.xz
nixpkgs-f37972588db25ef22f5071fab64ab1a3e3a86c0a.tar.zst
nixpkgs-f37972588db25ef22f5071fab64ab1a3e3a86c0a.zip
ruby docs: fix text and example (#28006)
1. 'wrapper' has been renamed to 'wrappedRuby', so use this instead.
2. mkDerivation isn't called with a 'src' attribute, so skip the 'unpackPhase' to avoid an error.
3. Simplify the build command. 'mkdir' and 'patchShebangs' don't need to be called explicitly.
-rw-r--r--doc/languages-frameworks/ruby.xml10
1 files changed, 3 insertions, 7 deletions
diff --git a/doc/languages-frameworks/ruby.xml b/doc/languages-frameworks/ruby.xml
index 4b48f7ffa1b..89b7a8986c3 100644
--- a/doc/languages-frameworks/ruby.xml
+++ b/doc/languages-frameworks/ruby.xml
@@ -82,7 +82,7 @@ versions available from various packages.
 </para>
 
 <para>Resulting derivations for both builders also have two helpful
-attributes, <literal>env</literal> and <literal>wrapper</literal>.
+attributes, <literal>env</literal> and <literal>wrappedRuby</literal>.
 The first one allows one to quickly drop into
 <command>nix-shell</command> with the specified environment present.
 E.g. <command>nix-shell -A sensu.env</command> would give you an
@@ -110,15 +110,11 @@ the needed dependencies. For example, to make a derivation
 
 in stdenv.mkDerivation {
   name = "my-script";
-
-  buildInputs = [ env.wrapper ];
-
+  buildInputs = [ env.wrappedRuby ];
+  phases = [ "installPhase" "fixupPhase" ];
   script = ./my-script.rb;
-
   buildCommand = ''
-    mkdir -p $out/bin
     install -D -m755 $script $out/bin/my-script
-    patchShebangs $out/bin/my-script
   '';
 }]]>
 </programlisting>