[Nix-dev] [newbie] ruby gem pkgs - bundler, bundler/setup
Peter Schuller
peter.schuller at infidyne.com
Thu Feb 4 08:15:51 CET 2016
Hi,
I'm attempting to add asciidoctor (http://asciidoctor.org/) to
nixpkgs. I'm following the instructions at:
https://nixos.org/nixpkgs/manual/#sec-language-ruby
with one deviation - I removed the source URL directive added by
bundix, based on the fact that nix complained about syntax and that
other gemspecs in nixpkgs don't have it (e.g., tools/misc/lolcat).
After that I have two problems.
The first is that bundler ends up in bin (and thus in the user's PATH).
I noticed this as I was installing lolcat without having uninstalled
my work-in-progress package - and it failed due to bundler being a
conflict in bin:
https://gist.github.com/scode/70bce8856634b23bbeda
Even assuming I did something wrong with asciidoc, the fact remains
that lolcat wants to expose bundler as a binary provided by it! From
my understanding, this seems wrong since it would make lolcat and
other packages using the same mechanism mutually exclusive. I am
probably missing something, but that's why I'm confused.
The second problem is that once I have my package installed, it fails
to run with:
https://gist.github.com/scode/c9ef2d698a04db8e5739
While the immediate cause of the problem is obvious, it's not obvious
to me, as a newbie to nixpkgs, what the root cause is or how the
mechanisms all fit together to try to ensure that bundler/setup is
visible to require at that point, and how my package is different than
lolcat to cause this problem.
My attempted package is here:
https://github.com/scode/nixpkgs/commit/d8798469d036c1cd6d758836b0e02fe1008b4baf
--
/ Peter Schuller (@scode, http://worldmodscode.wordpress.com)
More information about the nix-dev
mailing list