I’m looking to install multiple of the same software like vscode/vscodium/firefox et cetera. Each having a different configuration.
Currently, this installs microsoft’s vscode.
# home.nix
programs.vscode = {
enable = true;
};
Using the package option sets the source to vscodium but how would I do this simultaneously with the above.
# home.nix
programs.vscode = {
enable = true;
package = pkgs.vscodium
};
If I set both of the together, I get the following error. on nixos-rebuild
command.
building the system configuration...
error:
… while calling the 'head' builtin
at /nix/store/2lagifgqw760xch048spv2a0v46ya1vb-source/lib/attrsets.nix:922:11:
921| || pred here (elemAt values 1) (head values) then
922| head values
| ^
923| else
… while evaluating the attribute 'value'
at /nix/store/2lagifgqw760xch048spv2a0v46ya1vb-source/lib/modules.nix:807:9:
806| in warnDeprecation opt //
807| { value = builtins.addErrorContext "while evaluating the option `${showOption loc}':" value;
| ^
808| inherit (res.defsFinal') highestPrio;
(stack trace truncated; use '--show-trace' to show the full trace)
error: attribute 'enable' already defined at /nix/store/kjh3zz4lvsc1z6x0f8dc9hn6mr18g5f0-source/home.nix:33:5
at /nix/store/kjh3zz4lvsc1z6x0f8dc9hn6mr18g5f0-source/home.nix:30:5:
29| programs.vscode = {
30| enable = true;
| ^
31| };
Is there a way to install multiple of the same applications, with and without the same version number and commit hash, with different configurations with a custom name like VSCode-1, VSCode-2 and so on? Thank you for any assistance.