1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-23 11:39:46 +01:00
home-manager/tests/modules/programs/tmate/tmate.nix
José Luis Lafuente 707cb75ed3
tmate: add module
2022-09-26 00:28:00 +02:00

25 lines
645 B
Nix

{ config, lib, pkgs, ... }:
{
programs.tmate = {
enable = true;
port = 222;
dsaFingerprint = "SHA256:1111111111111111111111111111111111111111111";
extraConfig = ''set tmate-session-name "session-name"'';
};
test.stubs.tmate = { };
nmt.script = let
expectedConfig = ''
set -g tmate-server-port 222
set -g tmate-server-ed25519-fingerprint "SHA256:1111111111111111111111111111111111111111111"
set tmate-session-name "session-name"
'';
in ''
assertFileExists home-files/.tmate.conf
assertFileContent home-files/.tmate.conf ${
builtins.toFile "config" expectedConfig
}
'';
}