Switch from firefox to chrome

This commit is contained in:
Filippo Berto 2023-10-12 09:14:28 +02:00
parent 0d02437fd6
commit 3595f3f517
No known key found for this signature in database
GPG key ID: FE98AE5EC52B1056
3 changed files with 23 additions and 21 deletions

View file

@ -1,14 +1,27 @@
{ pkgs, lib, ... }:
# Categories: https://specifications.freedesktop.org/menu-spec/latest/apa.html#main-category-registry
let
# cmd = link: "${pkgs.google-chrome}/bin/google-chrome-stable --app=${link}";
cmd = link: "firefox --new-window ${link}";
chrome-cmd = link: "${pkgs.google-chrome}/bin/google-chrome-stable --app=${link}";
# firefox-cmd = link: "firefox --new-window ${link}";
webAppBuilder =
{ desktopName
, name ? builtins.replaceStrings [ " " ] [ "_" ] desktopName
, link
, cmd ? chrome-cmd
, icon ? lib.toLower name
, comment ? null
, categories ? [ "Network" ]
}:
pkgs.makeDesktopItem {
inherit name icon desktopName comment categories;
exec = cmd link;
};
links = [
# {
# desktopName = "Microsoft Teams";
# link = "https://teams.microsoft.com";
# categories = [ "Office" ];
# }
{
desktopName = "Microsoft Teams";
link = "https://teams.microsoft.com";
categories = [ "Office" ];
}
{
desktopName = "Chess.com";
link = "https://chess.com";
@ -80,17 +93,6 @@ let
categories = [ "AudioVideo" ];
}
];
webAppBuilder =
{ desktopName
, name ? builtins.replaceStrings [ " " ] [ "_" ] desktopName
, link
, icon ? lib.toLower name
, comment ? null
, categories ? [ "Network" ]
}:
pkgs.makeDesktopItem {
inherit name icon desktopName comment categories;
exec = cmd link;
};
in
{ home.packages = map webAppBuilder links; }