+1
-1
doc/languages-frameworks/ruby.section.md
+1
-1
doc/languages-frameworks/ruby.section.md
···
8
9
There are two main approaches for using Ruby with gems. One is to use a specifically locked `Gemfile` for an application that has very strict dependencies. The other is to depend on the common gems, which we'll explain further down, and rely on them being updated regularly.
10
11
-
The interpreters have common attributes, namely `gems`, and `withPackages`. So you can refer to `ruby.gems.nokogiri`, or `ruby_3_2.gems.nokogiri` to get the Nokogiri gem already compiled and ready to use.
12
13
Since not all gems have executables like `nokogiri`, it's usually more convenient to use the `withPackages` function like this: `ruby.withPackages (p: with p; [ nokogiri ])`. This will also make sure that the Ruby in your environment will be able to find the gem and it can be used in your Ruby code (for example via `ruby` or `irb` executables) via `require "nokogiri"` as usual.
14
···
8
9
There are two main approaches for using Ruby with gems. One is to use a specifically locked `Gemfile` for an application that has very strict dependencies. The other is to depend on the common gems, which we'll explain further down, and rely on them being updated regularly.
10
11
+
The interpreters have common attributes, namely `gems`, and `withPackages`. So you can refer to `ruby.gems.nokogiri`, or `ruby_3_4.gems.nokogiri` to get the Nokogiri gem already compiled and ready to use.
12
13
Since not all gems have executables like `nokogiri`, it's usually more convenient to use the `withPackages` function like this: `ruby.withPackages (p: with p; [ nokogiri ])`. This will also make sure that the Ruby in your environment will be able to find the gem and it can be used in your Ruby code (for example via `ruby` or `irb` executables) via `require "nokogiri"` as usual.
14
+1
-1
nixos/modules/services/misc/redmine.nix
+1
-1
nixos/modules/services/misc/redmine.nix
-6
pkgs/development/interpreters/ruby/default.nix
-6
pkgs/development/interpreters/ruby/default.nix
···
393
mkRubyVersion = rubyVersion;
394
mkRuby = generic;
395
396
-
ruby_3_2 = generic {
397
-
version = rubyVersion "3" "2" "9" "";
398
-
hash = "sha256-q7rZjbmusVJ3Ow01ho5QADuMRn89BhUld8Tf7Z2I7So=";
399
-
cargoHash = "sha256-CMVx5/+ugDNEuLAvyPN0nGHwQw6RXyfRsMO9I+kyZpk=";
400
-
};
401
-
402
ruby_3_3 = generic {
403
version = rubyVersion "3" "3" "9" "";
404
hash = "sha256-0ZkWkKThcjPsazx4RMHhJFwK3OPgDXE1UdBFhGe3J7E=";
+4
-2
pkgs/development/ruby-modules/with-packages/test.nix
+4
-2
pkgs/development/ruby-modules/with-packages/test.nix
···
5
lib = pkgs.lib;
6
stdenv = pkgs.stdenv;
7
8
+
rubyVersions = [
9
+
# TODO FIXME: All versions listed here were dropped from Nixpkgs.
10
+
# Add current versions here or remove this file if it’s no longer
11
+
# being used.
12
];
13
14
gemTests = (lib.mapAttrs (name: gem: [ name ]) pkgs.ruby.gems) // (import ./require_exceptions.nix);
+2
pkgs/top-level/aliases.nix
+2
pkgs/top-level/aliases.nix
···
2355
rr-unstable = rr; # Added 2022-09-17
2356
rtx = mise; # Added 2024-01-05
2357
ruby_3_1 = throw "ruby_3_1 has been removed, as it is has reached end‐of‐life upstream"; # Added 2025-10-12
2358
rubyPackages_3_1 = throw "rubyPackages_3_1 has been removed, as it is has reached end‐of‐life upstream"; # Added 2025-10-12
2359
ruby-zoom = throw "'ruby-zoom' has been removed due to lack of maintaince and had not been updated since 2020"; # Added 2025-08-24
2360
runCommandNoCC = runCommand; # Added 2021-08-15
2361
runCommandNoCCLocal = runCommandLocal; # Added 2021-08-15
···
2355
rr-unstable = rr; # Added 2022-09-17
2356
rtx = mise; # Added 2024-01-05
2357
ruby_3_1 = throw "ruby_3_1 has been removed, as it is has reached end‐of‐life upstream"; # Added 2025-10-12
2358
+
ruby_3_2 = throw "ruby_3_2 has been removed, as it will reach end‐of‐life upstream during Nixpkgs 25.11’s support cycle"; # Added 2025-10-12
2359
rubyPackages_3_1 = throw "rubyPackages_3_1 has been removed, as it is has reached end‐of‐life upstream"; # Added 2025-10-12
2360
+
rubyPackages_3_2 = throw "rubyPackages_3_2 has been removed, as it will reach end‐of‐life upstream during Nixpkgs 25.11’s support cycle"; # Added 2025-10-12
2361
ruby-zoom = throw "'ruby-zoom' has been removed due to lack of maintaince and had not been updated since 2020"; # Added 2025-08-24
2362
runCommandNoCC = runCommand; # Added 2021-08-15
2363
runCommandNoCCLocal = runCommandLocal; # Added 2021-08-15
-2
pkgs/top-level/all-packages.nix
-2
pkgs/top-level/all-packages.nix
···
6036
})
6037
mkRubyVersion
6038
mkRuby
6039
-
ruby_3_2
6040
ruby_3_3
6041
ruby_3_4
6042
ruby_3_5
···
6045
ruby = ruby_3_3;
6046
rubyPackages = rubyPackages_3_3;
6047
6048
-
rubyPackages_3_2 = recurseIntoAttrs ruby_3_2.gems;
6049
rubyPackages_3_3 = recurseIntoAttrs ruby_3_3.gems;
6050
rubyPackages_3_4 = recurseIntoAttrs ruby_3_4.gems;
6051
rubyPackages_3_5 = recurseIntoAttrs ruby_3_5.gems;
···
6036
})
6037
mkRubyVersion
6038
mkRuby
6039
ruby_3_3
6040
ruby_3_4
6041
ruby_3_5
···
6044
ruby = ruby_3_3;
6045
rubyPackages = rubyPackages_3_3;
6046
6047
rubyPackages_3_3 = recurseIntoAttrs ruby_3_3.gems;
6048
rubyPackages_3_4 = recurseIntoAttrs ruby_3_4.gems;
6049
rubyPackages_3_5 = recurseIntoAttrs ruby_3_5.gems;