Update modules + webapps
This commit is contained in:
parent
f00fe93ec4
commit
c996e57264
10 changed files with 54 additions and 130 deletions
30
modules/webapp.nix
Normal file
30
modules/webapp.nix
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
{ 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}";
|
||||
links = [
|
||||
{ name = "YouTube"; link = "https://www.youtube.com"; categories = "AudioVideo"; }
|
||||
{ name = "Twitch"; link = "https://www.twitch.tv"; icon = builtins.fetchurl "https://static.twitchcdn.net/assets/favicon-32-e29e246c157142c94346.png"; categories = "AudioVideo"; }
|
||||
{ name = "Netflix"; link = "https://www.netflix.com"; categories = "AudioVideo"; }
|
||||
{ name = "Prime Video"; link = "https://primevideo.com"; categories = "AudioVideo"; }
|
||||
{ name = "Google Keep"; link = "https://keep.google.com"; categories = "Office"; }
|
||||
{ name = "Google Calendar"; link = "https://google.com/calendar"; icon = "calendar"; categories = "Calendar;Office"; }
|
||||
{ name = "Notion"; link = "https://notion.so"; categories = "Office"; }
|
||||
{ name = "WhatsApp"; link = "https://web.whatsapp.com/"; }
|
||||
];
|
||||
webAppBuilder =
|
||||
{ name
|
||||
, link
|
||||
, icon ? lib.toLower name
|
||||
, desktopName ? name
|
||||
, comment ? null
|
||||
, categories ? "Network"
|
||||
}: pkgs.makeDesktopItem {
|
||||
inherit name icon desktopName comment categories;
|
||||
type = "Application";
|
||||
exec = cmd link;
|
||||
};
|
||||
in
|
||||
{
|
||||
home.packages = map webAppBuilder links;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue