modules/calendar: add khal calendar to the modules
This commit is contained in:
parent
9f17dba58d
commit
d380f10983
3 changed files with 29 additions and 5 deletions
18
modules/home-manager/programs/calendar.nix
Normal file
18
modules/home-manager/programs/calendar.nix
Normal file
|
@ -0,0 +1,18 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
let
|
||||
cfg = config.local.programs.calendar;
|
||||
|
||||
mkCalOpts = name: {
|
||||
enable = lib.mkEnableOption name;
|
||||
package = lib.mkPackageOption pkgs name { };
|
||||
};
|
||||
in
|
||||
{
|
||||
options.local.programs.calendar = {
|
||||
khal = mkCalOpts "khal";
|
||||
};
|
||||
|
||||
config.home.packages =
|
||||
lib.optional cfg.khal.enable cfg.khal.package;
|
||||
}
|
|
@ -3,6 +3,7 @@
|
|||
{
|
||||
imports = [
|
||||
./aerc.nix
|
||||
./calendar.nix
|
||||
./communication.nix
|
||||
./dev-tools.nix
|
||||
./flameshot.nix
|
||||
|
|
|
@ -2,19 +2,24 @@
|
|||
|
||||
let
|
||||
cfg = config.local.programs.share-files;
|
||||
|
||||
mkShareFileOpts = name: {
|
||||
enable = lib.mkEnableOption name;
|
||||
package = lib.mkPackageOption pkgs name { };
|
||||
};
|
||||
in
|
||||
{
|
||||
options.local.programs.share-files = with lib; {
|
||||
onionshare.enable = mkEnableOption "onionshare";
|
||||
croc.enable = mkEnableOption "croc";
|
||||
options.local.programs.share-files = {
|
||||
onionshare.enable = mkShareFileOpts "onionshare-gui";
|
||||
croc.enable = mkShareFileOpts "croc";
|
||||
};
|
||||
|
||||
config.home.packages =
|
||||
# OnionShare is an open-source tool that lets you securely and anonymously share files,
|
||||
# host websites, and chat with friends using the Tor network.
|
||||
lib.optional cfg.onionshare.enable pkgs.onionshare-gui
|
||||
lib.optional cfg.onionshare.enable cfg.onionshare.package
|
||||
|
||||
# Easily and securely send things from one computer to another
|
||||
++ lib.optional cfg.croc.enable pkgs.croc;
|
||||
++ lib.optional cfg.croc.enable cfg.croc.package;
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue