mirror of
https://github.com/nix-community/home-manager
synced 2024-11-30 15:09:46 +01:00
f46972e466
Add modulesRight setting to instruct powerline-go to configure right side prompt. Use eval mode when this setting is set.
33 lines
800 B
Nix
33 lines
800 B
Nix
{ config, lib, pkgs, ... }:
|
|
|
|
with lib;
|
|
|
|
{
|
|
config = {
|
|
programs = {
|
|
bash.enable = true;
|
|
|
|
powerline-go = {
|
|
enable = true;
|
|
newline = true;
|
|
modules = [ "nix-shell" ];
|
|
pathAliases = { "\\~/project/foo" = "prj-foo"; };
|
|
settings = {
|
|
ignore-repos = [ "/home/me/project1" "/home/me/project2" ];
|
|
};
|
|
};
|
|
};
|
|
|
|
test.stubs.powerline-go = { };
|
|
|
|
nmt.script = ''
|
|
assertFileExists home-files/.bashrc
|
|
assertFileContains \
|
|
home-files/.bashrc \
|
|
'PS1='
|
|
assertFileContains \
|
|
home-files/.bashrc \
|
|
'/bin/powerline-go -error $old_exit_status -shell bash -modules nix-shell -newline -path-aliases \~/project/foo=prj-foo -ignore-repos /home/me/project1,/home/me/project2'
|
|
'';
|
|
};
|
|
}
|