A new start
This commit is contained in:
commit
f4e2368893
93 changed files with 7621 additions and 0 deletions
28
modules/home/cli-apps/bash/default.nix
Normal file
28
modules/home/cli-apps/bash/default.nix
Normal file
|
@ -0,0 +1,28 @@
|
|||
{ lib
|
||||
, config
|
||||
, pkgs
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
|
||||
cfg = config.metacfg.cli-apps.bash;
|
||||
in
|
||||
{
|
||||
options.metacfg.cli-apps.bash = {
|
||||
enable = mkEnableOption "BASH shell";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
home.packages = with pkgs; [
|
||||
bashInteractive
|
||||
];
|
||||
programs.bash = {
|
||||
enable = true;
|
||||
initExtra = ''
|
||||
function msh() { mosh "$@" -- bash -c 'if type -f tmux; then tmux new-session -A -s 0; else screen -R; fi;' ; };
|
||||
function tsh() { ssh -t "$@" -- bash -c 'if type -f tmux; then tmux new-session -A -s 0; else screen -R; fi;' ; };
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue