diff --git a/doc/language-support.xml b/doc/language-support.xml index 5fb123ddfc17..f2b64c93d22a 100644 --- a/doc/language-support.xml +++ b/doc/language-support.xml @@ -612,15 +612,45 @@ sed -i '/ = data_files/d' setup.py
Ruby - For example, to package yajl-ruby package, use gem-nix: + There currently is support to bundle applications that are packaged as Ruby gems. The utility "bundix" allows you to write a Gemfile, let bundler create a Gemfile.lock, and then convert + this into a nix expression that contains all Gem dependencies automatically. + + For example, to package sensu, we did: -$ nix-env -i gem-nix -$ gem-nix --no-user-install --nix-file=pkgs/development/interpreters/ruby/generated.nix yajl-ruby -$ nix-build -A rubyPackages.yajl-ruby - -
+ Gemfile +source 'https://rubygems.org' +gem 'sensu' +$ bundler package --path /tmp/vendor/bundle +$ $(nix-build '&nixpkgs>' -A bundix)/bin/bundix +$ cat > default.nix +{ lib, bundlerEnv, ruby }: +bundlerEnv { + name = "sensu-0.17.1"; + + inherit ruby; + gemfile = ./Gemfile; + lockfile = ./Gemfile.lock; + gemset = ./gemset.nix; + + meta = with lib; { + description = "A monitoring framework that aims to be simple, malleable, +and scalable."; + homepage = http://sensuapp.org/; + license = with licenses; mit; + maintainers = with maintainers; [ theuni ]; + platforms = platforms.unix; + }; +}]]> + + +Please check in the Gemfile, Gemfile.lock and the gemset.nix so future updates can be run easily. + + +
Go