4 ms·
It does work on m1, you might run into more issues compared to intel based Macs though. I wouldn't call nix painless. It might take some time to figure out the
by ananthakumaran 4y ago
It does work on m1, you might run into more issues compared to intel based Macs though. I wouldn't call nix painless. It might take some time to figure out the packages required, proper env variables to setup etc. But, once somebody in the team figures out the details, it will likely work for everyone in the team and others don't have to go through same pain. The whole setup is isolated to a single project and will not affect other projects. The setup for a old rails project pinned to a ruby version with few dependencies might look like below
let
pkgs = import (builtins.fetchTarball {
url =
"https://github.com/NixOS/nixpkgs/archive/c92ca95afb5043bc6faa0d526460584eccff2277.tar.gz";
}) { };
in pkgs.mkShell {
nativeBuildInputs = [
pkgs.ruby_2_6
pkgs.shared-mime-info
pkgs.mysql
pkgs.libmysqlclient
pkgs.imagemagick6.dev
pkgs.pkg-config
pkgs.cmake
];
PKG_CONFIG_PATH = "${pkgs.imagemagick6.dev}/lib/pkgconfig";
FREEDESKTOP_MIME_TYPES_PATH =
"${pkgs.shared_mime_info}/share/mime/packages/freedesktop.org.xml";
}