bashmount: add module
This commit is contained in:
parent
f5e9879e74
commit
389f2b2037
4 changed files with 44 additions and 0 deletions
34
modules/programs/bashmount.nix
Normal file
34
modules/programs/bashmount.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
|
||||
cfg = config.programs.bashmount;
|
||||
|
||||
in {
|
||||
meta.maintainers = [ maintainers.AndersonTorres ];
|
||||
|
||||
options.programs.bashmount = {
|
||||
enable = mkEnableOption "bashmount";
|
||||
|
||||
extraConfig = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
description = ''
|
||||
Configuration written to
|
||||
<filename>$XDG_CONFIG_HOME/bashmount/config</filename>. Look at
|
||||
<link xlink:href="https://github.com/jamielinux/bashmount/blob/master/bashmount.conf" />
|
||||
for explanation about possible values.
|
||||
'';
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
home.packages = [ pkgs.bashmount ];
|
||||
|
||||
xdg.configFile."bashmount/config" =
|
||||
mkIf (cfg.extraConfig != "") { text = cfg.extraConfig; };
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue