about summary refs log blame commit diff stats
path: root/modules/home.legacy/conf/taskwarrior/firefox/default.nix
blob: fb5daaa844b3fd11bbe3951234b2dacb26aa6c0a (plain) (tree)
1
2
3
4
5
6
7
8
9
10
 
         




               
      
                                                         






                        
                                        

               
                             
                     
                             



                                                                                     
{
  config,
  lib,
  # options
  prefConfig,
  profile_size,
  search,
  userChrome,
  ...
}: let
  inherit (config.soispha.taskwarrior.projects) projects;

  mkFirefoxProfile = {
    name,
    id,
  }: {
    inherit name;
    value = {
      isDefault = false;
      extraConfig = prefConfig;
      inherit id name search userChrome;
    };
  };
  projects_id =
    lib.imap0 (id: project: {
      name = project;
      id = id + profile_size;
    })
    projects;
  firefoxProfiles = builtins.listToAttrs (builtins.map mkFirefoxProfile projects_id);
in
  firefoxProfiles