Skip to content

Commit

Permalink
nixos/cosmic: init
Browse files Browse the repository at this point in the history
  • Loading branch information
nyabinary committed Feb 26, 2024
1 parent cd2ec84 commit 84c49b9
Showing 1 changed file with 46 additions and 0 deletions.
46 changes: 46 additions & 0 deletions nixos/modules/services/x11/desktop-managers/cosmic.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
{ config, pkgs, lib, ... }:

let
cfg = config.services.xserver.desktopManager.cosmic;
in
{
meta.maintainers = with lib.maintainers; [ nyanbinary ];

options.services.xserver.desktopManager.cosmic = {
enable = lib.mkEnableOption (lib.mdDoc "COSMIC desktop environment");
};

config = lib.mkIf cfg.enable {
# components that need to be in PATH
environment.systemPackages = with pkgs; [
cosmic-applibrary
cosmic-applets
cosmic-bg
cosmic-comp
cosmic-edit
cosmic-files
cosmic-greeter
cosmic-icons
cosmic-launcher
cosmic-notifications
cosmic-osd
cosmic-panel
cosmic-randr
cosmic-screenshot
cosmic-settings
cosmic-settings-daemon
cosmic-term
cosmic-workspaces-epoch
];

# COSMIC portal doesn't support everything yet
xdg.portal.extraPortals = with pkgs; [
xdg-desktop-portal-cosmic
xdg-desktop-portal-gtk
];

# session files for display manager and systemd
services.xserver.displayManager.sessionPackages = with pkgs; [ cosmic-session ];
systemd.packages = with pkgs; [ cosmic-session ];
};
}

0 comments on commit 84c49b9

Please sign in to comment.