How to use uutils-coreutils instead of the builtin coreutils?

I just installed the uutils-coreutils package but it gives me prefixed binaries like uutils-cp instead of just cp. I’m trying to live on the edge and use uutils-coreutils instead of any built-ins. Is there a way to do this, preferably home-manager-friendly?

It looks like there’s indeed an option for this: It’s just not clear to me how to adjust prefix from within home-manager. Does anyone know how to do this?

Usually when you want to live on the edge, its best not to ask for a complete solution but mention the steps you’ve taken and where you’re stuck.

When you add the package you need to override the prefix argument. Set it null or whatever you want.

Gotcha, I’m not having much success with .override and .overrideAttrs unfortunately:

home.packages = [
    pkgs.uutils-coreutils.override { prefix = ""; }

gives me an error:

❯ home-manager switch             
error: The option value `home.packages.[definition 16-entry 10]' in `/home/skainswo/.config/nixpkgs/home.nix' is not of type `package'.

You need brackets:

home.packages = [
    (pkgs.uutils-coreutils.override { prefix = ""; })
1 Like

Awesome, thanks @Ninlives! That did the trick.