2.home-manager/tests/modules/programs/tmux/tmuxinator-projects.nix
Benedikt Ritter b399348e9d tmuxinator: move to dedicated module with projects support
Extract tmuxinator from tmux.nix into its own programs/tmuxinator.nix
module. The new module adds:

- programs.tmux.tmuxinator.package for customising the tmuxinator package
- programs.tmux.tmuxinator.projects for declaring projects declaratively;
  each project is written to $HOME/.config/tmuxinator/<name>.yaml

Co-authored-by: Austin Horstman <khaneliman12@gmail.com>
2026-03-31 14:05:50 -05:00

40 lines
1.1 KiB
Nix

{
config = {
programs.tmux = {
enable = true;
tmuxinator = {
enable = true;
projects = {
myproject = {
name = "myproject";
root = "~/code/myproject";
windows = [
{
editor = {
layout = "main-vertical";
panes = [
{ editor = [ "vim" ]; }
"guard"
];
};
}
{ server = "bundle exec rails s"; }
{ logs = "tail -f log/development.log"; }
];
};
my-second-project = {
name = "my-second-project";
root = "~/code/my-second-project";
};
};
};
};
nmt.script = ''
assertFileExists home-files/.config/tmuxinator/myproject.yaml
assertFileContent home-files/.config/tmuxinator/myproject.yaml ${./tmuxinator-projects-1.yaml}
assertFileExists home-files/.config/tmuxinator/my-second-project.yaml
assertFileContent home-files/.config/tmuxinator/my-second-project.yaml ${./tmuxinator-projects-2.yaml}
'';
};
}