mirror of
https://github.com/nix-community/home-manager
synced 2024-12-21 02:23:16 +00:00
cb09a968e9
This option provides a more convenient way to overlay dummy packages. It also adds a function `config.lib.test.mkStubPackage` that can, e.g., be used for `package` options.
21 lines
469 B
Nix
21 lines
469 B
Nix
{ config, lib, pkgs, ... }:
|
|
|
|
{
|
|
config = {
|
|
programs.gh = {
|
|
enable = true;
|
|
aliases = { co = "pr checkout"; };
|
|
editor = "vim";
|
|
};
|
|
|
|
test.stubs.gh = { };
|
|
|
|
nmt.script = ''
|
|
assertFileExists home-files/.config/gh/config.yml
|
|
assertFileContent home-files/.config/gh/config.yml ${
|
|
builtins.toFile "config-file.yml" ''
|
|
{"aliases":{"co":"pr checkout"},"editor":"vim","git_protocol":"https"}''
|
|
}
|
|
'';
|
|
};
|
|
}
|