From 64d5fa9f0438926eb0613a56dd3e97b3f53242e7 Mon Sep 17 00:00:00 2001 From: martyTF Date: Tue, 14 Apr 2026 17:56:06 +0200 Subject: [PATCH] noctalia --- home/desktop/shell/noctalia.nix | 606 ++++++++++++++++++++++++++++- modules/desktop/shell/noctalia.nix | 1 + modules/server/cloud/nextcloud.nix | 22 +- 3 files changed, 611 insertions(+), 18 deletions(-) diff --git a/home/desktop/shell/noctalia.nix b/home/desktop/shell/noctalia.nix index e4dcc31..4075fd7 100644 --- a/home/desktop/shell/noctalia.nix +++ b/home/desktop/shell/noctalia.nix @@ -16,36 +16,624 @@ else [ ]; config = { + programs.noctalia-shell = if osConfig.desktop.shell.noctalia.enable then { enable = true; + package = (pkgs.noctalia-shell.override { calendarSupport = true; }); settings = { + settingsVersion = 0; bar = { - density = "compact"; - position = "center"; + barType = "floating"; + position = "top"; + monitors = [ ]; + density = "comfortable"; + showOutline = true; showCapsule = true; + capsuleOpacity = 1; + capsuleColorKey = "none"; + widgetSpacing = 6; + contentPadding = 6; + fontScale = 1; + enableExclusionZoneInset = true; + backgroundOpacity = 0; + useSeparateOpacity = true; + marginVertical = 6; + marginHorizontal = 6; + frameThickness = 8; + frameRadius = 30; + outerCorners = true; + hideOnOverview = false; + displayMode = "always_visible"; + autoHideDelay = 500; + autoShowDelay = 150; + showOnWorkspaceSwitch = true; widgets = { left = [ { - id = "ControlCenter"; - useDistroLogo = true; + id = "Launcher"; } + { + id = "Clock"; + } + { + id = "SystemMonitor"; + } + { + id = "ActiveWindow"; + } + { + id = "MediaMini"; + } + ]; + center = [ + { + id = "Workspace"; + } + ]; + right = [ + { + id = "Tray"; + } + { + id = "NotificationHistory"; + } + { + id = "Battery"; + } + { + id = "Volume"; + } + { + id = "Brightness"; + } + { + id = "ControlCenter"; + } + ]; + }; + mouseWheelAction = "workspace"; + reverseScroll = false; + mouseWheelWrap = true; + middleClickAction = "settings"; + middleClickFollowMouse = true; + middleClickCommand = ""; + rightClickAction = "controlCenter"; + rightClickFollowMouse = true; + rightClickCommand = ""; + screenOverrides = [ ]; + }; + general = { + avatarImage = ""; + dimmerOpacity = 0.1; + showScreenCorners = false; + forceBlackScreenCorners = false; + scaleRatio = 1; + radiusRatio = 2; + iRadiusRatio = 2; + boxRadiusRatio = 1; + screenRadiusRatio = 1; + animationSpeed = 1; + animationDisabled = false; + compactLockScreen = false; + lockScreenAnimations = true; + lockOnSuspend = true; + showSessionButtonsOnLockScreen = true; + showHibernateOnLockScreen = false; + enableLockScreenMediaControls = true; + enableShadows = true; + enableBlurBehind = true; + shadowDirection = "bottom_right"; + shadowOffsetX = 2; + shadowOffsetY = 3; + language = ""; + allowPanelsOnScreenWithoutBar = true; + showChangelogOnStartup = true; + telemetryEnabled = false; + enableLockScreenCountdown = true; + lockScreenCountdownDuration = 5000; + autoStartAuth = true; + allowPasswordWithFprintd = true; + clockStyle = "custom"; + clockFormat = "HH:mm - dd.MM.yyyy"; + passwordChars = true; + lockScreenMonitors = [ ]; + lockScreenBlur = 0.05; + lockScreenTint = 0; + keybinds = { + keyUp = [ + "Up" + ]; + keyDown = [ + "Down" + ]; + keyLeft = [ + "Left" + ]; + keyRight = [ + "Right" + ]; + keyEnter = [ + "Return" + "Enter" + ]; + keyEscape = [ + "Esc" + ]; + keyRemove = [ + "Del" + ]; + }; + reverseScroll = false; + smoothScrollEnabled = true; + }; + ui = { + fontDefault = "FiraCode Nerd Font"; + fontFixed = "FiraCode Nerd Font"; + fontDefaultScale = 1; + fontFixedScale = 1; + tooltipsEnabled = true; + scrollbarAlwaysVisible = true; + boxBorderEnabled = true; + panelBackgroundOpacity = 1; + translucentWidgets = false; + panelsAttachedToBar = false; + settingsPanelMode = "centered"; + settingsPanelSideBarCardStyle = true; + }; + location = { + name = ""; + weatherEnabled = true; + weatherShowEffects = true; + useFahrenheit = false; + use12hourFormat = false; + showWeekNumberInCalendar = true; + showCalendarEvents = true; + showCalendarWeather = true; + analogClockInCalendar = false; + firstDayOfWeek = 1; + hideWeatherTimezone = false; + hideWeatherCityName = true; + autoLocate = true; + }; + calendar = { + cards = [ + { + enabled = true; + id = "calendar-header-card"; + } + { + enabled = true; + id = "calendar-month-card"; + } + { + enabled = true; + id = "weather-card"; + } + ]; + }; + wallpaper = { + enabled = true; + overviewEnabled = true; + directory = "/home/${osConfig.user.userName}/.local/share/wallpapers"; + monitorDirectories = [ ]; + enableMultiMonitorDirectories = false; + showHiddenFiles = false; + viewMode = "recursive"; + setWallpaperOnAllMonitors = true; + linkLightAndDarkWallpapers = true; + fillMode = "crop"; + fillColor = "#000000"; + useSolidColor = false; + solidColor = "#1a1a2e"; + automationEnabled = true; + wallpaperChangeMode = "random"; + randomIntervalSec = 300; + transitionDuration = 1500; + transitionType = [ + "fade" + "disc" + "stripes" + "wipe" + "pixelate" + "honeycomb" + ]; + skipStartupTransition = false; + transitionEdgeSmoothness = 0.05; + panelPosition = "follow_bar"; + hideWallpaperFilenames = false; + useOriginalImages = false; + overviewBlur = 0.4; + overviewTint = 0.6; + useWallhaven = false; + wallhavenQuery = ""; + wallhavenSorting = "relevance"; + wallhavenOrder = "desc"; + wallhavenCategories = "111"; + wallhavenPurity = "100"; + wallhavenRatios = ""; + wallhavenApiKey = ""; + wallhavenResolutionMode = "atleast"; + wallhavenResolutionWidth = ""; + wallhavenResolutionHeight = ""; + sortOrder = "name"; + favorites = [ ]; + }; + appLauncher = { + enableClipboardHistory = true; + autoPasteClipboard = false; + enableClipPreview = true; + clipboardWrapText = true; + enableClipboardSmartIcons = true; + enableClipboardChips = true; + clipboardWatchTextCommand = "wl-paste --type text --watch cliphist store"; + clipboardWatchImageCommand = "wl-paste --type image --watch cliphist store"; + position = "top_center"; + pinnedApps = [ ]; + sortByMostUsed = true; + terminalCommand = "kitty -e"; + customLaunchPrefixEnabled = false; + customLaunchPrefix = ""; + viewMode = "grid"; + showCategories = true; + iconMode = "native"; + showIconBackground = true; + enableSettingsSearch = true; + enableWindowsSearch = true; + enableSessionSearch = true; + ignoreMouseInput = false; + screenshotAnnotationTool = "gradia"; + overviewLayer = true; + density = "default"; + }; + controlCenter = { + position = "close_to_bar_button"; + diskPath = "/"; + shortcuts = { + left = [ { id = "Network"; } { id = "Bluetooth"; } - ]; - center = [ { - id = "Workspace"; - labelMode = "none"; - hideUnoccupied = false; + id = "WallpaperSelector"; + } + { + id = "NoctaliaPerformance"; + } + ]; + right = [ + { + id = "Notifications"; + } + { + id = "PowerProfile"; + } + { + id = "NightLight"; } ]; }; + cards = [ + { + enabled = true; + id = "profile-card"; + } + { + enabled = true; + id = "shortcuts-card"; + } + { + enabled = true; + id = "audio-card"; + } + { + enabled = false; + id = "brightness-card"; + } + { + enabled = true; + id = "weather-card"; + } + { + enabled = true; + id = "media-sysmon-card"; + } + ]; + }; + systemMonitor = { + cpuWarningThreshold = 80; + cpuCriticalThreshold = 90; + tempWarningThreshold = 80; + tempCriticalThreshold = 90; + gpuWarningThreshold = 80; + gpuCriticalThreshold = 90; + memWarningThreshold = 80; + memCriticalThreshold = 90; + swapWarningThreshold = 80; + swapCriticalThreshold = 90; + diskWarningThreshold = 80; + diskCriticalThreshold = 90; + diskAvailWarningThreshold = 20; + diskAvailCriticalThreshold = 10; + batteryWarningThreshold = 20; + batteryCriticalThreshold = 5; + enableDgpuMonitoring = false; + useCustomColors = false; + warningColor = ""; + criticalColor = ""; + externalMonitor = "resources || missioncenter || jdsystemmonitor || corestats || system-monitoring-center || gnome-system-monitor || plasma-systemmonitor || mate-system-monitor || ukui-system-monitor || deepin-system-monitor || pantheon-system-monitor"; + }; + noctaliaPerformance = { + disableWallpaper = true; + disableDesktopWidgets = true; + }; + dock = { + enabled = false; + position = "bottom"; + displayMode = "auto_hide"; + dockType = "floating"; + backgroundOpacity = 1; + floatingRatio = 1; + size = 1; + onlySameOutput = true; + monitors = [ ]; + pinnedApps = [ ]; + colorizeIcons = false; + showLauncherIcon = false; + launcherPosition = "end"; + launcherUseDistroLogo = false; + launcherIcon = ""; + launcherIconColor = "none"; + pinnedStatic = false; + inactiveIndicators = false; + groupApps = false; + groupContextMenuMode = "extended"; + groupClickAction = "cycle"; + groupIndicatorStyle = "dots"; + deadOpacity = 0.6; + animationSpeed = 1; + sitOnFrame = false; + showDockIndicator = false; + indicatorThickness = 3; + indicatorColor = "primary"; + indicatorOpacity = 0.6; + }; + network = { + bluetoothRssiPollingEnabled = false; + bluetoothRssiPollIntervalMs = 60000; + networkPanelView = "wifi"; + wifiDetailsViewMode = "grid"; + bluetoothDetailsViewMode = "grid"; + bluetoothHideUnnamedDevices = false; + disableDiscoverability = false; + bluetoothAutoConnect = true; + }; + sessionMenu = { + enableCountdown = true; + countdownDuration = 5000; + position = "center"; + showHeader = true; + showKeybinds = true; + largeButtonsStyle = true; + largeButtonsLayout = "single-row"; + powerOptions = [ + { + action = "lock"; + enabled = true; + keybind = "1"; + } + { + action = "suspend"; + enabled = true; + keybind = "2"; + } + { + action = "hibernate"; + enabled = true; + keybind = "3"; + } + { + action = "reboot"; + enabled = true; + keybind = "4"; + } + { + action = "logout"; + enabled = true; + keybind = "5"; + } + { + action = "shutdown"; + enabled = true; + keybind = "6"; + } + { + action = "rebootToUefi"; + enabled = true; + keybind = "7"; + } + ]; + }; + notifications = { + enabled = true; + enableMarkdown = true; + density = "compact"; + monitors = [ ]; + location = "top"; + overlayLayer = true; + backgroundOpacity = 1; + respectExpireTimeout = true; + lowUrgencyDuration = 3; + normalUrgencyDuration = 8; + criticalUrgencyDuration = 15; + clearDismissed = true; + saveToHistory = { + low = true; + normal = true; + critical = true; + }; + sounds = { + enabled = false; + volume = 0.5; + separateSounds = false; + criticalSoundFile = ""; + normalSoundFile = ""; + lowSoundFile = ""; + excludedApps = "discord,firefox,chrome,chromium,edge"; + }; + enableMediaToast = false; + enableKeyboardLayoutToast = true; + enableBatteryToast = true; + }; + osd = { + enabled = true; + location = "top_right"; + autoHideMs = 2000; + overlayLayer = true; + backgroundOpacity = 1; + enabledTypes = [ + 0 + 1 + 2 + ]; + monitors = [ ]; + }; + audio = { + volumeStep = 5; + volumeOverdrive = false; + spectrumFrameRate = 30; + visualizerType = "linear"; + spectrumMirrored = true; + mprisBlacklist = [ ]; + preferredPlayer = ""; + volumeFeedback = false; + volumeFeedbackSoundFile = ""; + }; + brightness = { + brightnessStep = 5; + enforceMinimum = true; + enableDdcSupport = false; + backlightDeviceMappings = [ ]; + }; + colorSchemes = { + useWallpaperColors = true; + predefinedScheme = "Noctalia (default)"; + darkMode = true; + schedulingMode = "off"; + manualSunrise = "06:30"; + manualSunset = "18:30"; + generationMethod = "tonal-spot"; + monitorForColors = ""; + syncGsettings = true; + }; + templates = { + activeTemplates = [ + { id = alacritty; + enable = true; + } + { id = btop; + enable = true; + } + { id = cava; + enable = true; + } + { id = emacs; + enable = true; + } + { id = gtk; + enable = true; + } + { id = hyprland; + enable = true; + } + { id = hyprtoolkit; + enable = true; + } + { id = kcolorscheme; + enable = true; + } + { id = kitty; + enable = true; + } + { id = mango; + enable = true; + } + { id = niri; + enable = true; + } + { id = qt; + enable = true; + } + { id = steam; + enable = true; + } + { id = sway; + enable = true; + } + { id = code; + enable = true; + } + { id = walker; + enable = true; + } + { id = zed; + enable = true; + } + { id = zenBrowser; + enable = true; + } + ]; + enableUserTheming = false; + }; + nightLight = { + enabled = false; + forced = false; + autoSchedule = true; + nightTemp = "4000"; + dayTemp = "6500"; + manualSunrise = "06:30"; + manualSunset = "18:30"; + }; + hooks = { + enabled = false; + wallpaperChange = ""; + darkModeChange = ""; + screenLock = ""; + screenUnlock = ""; + performanceModeEnabled = ""; + performanceModeDisabled = ""; + startup = ""; + session = ""; + colorGeneration = ""; + }; + plugins = { + autoUpdate = false; + notifyUpdates = true; + }; + idle = { + enabled = false; + screenOffTimeout = 600; + lockTimeout = 660; + suspendTimeout = 1800; + fadeDuration = 5; + screenOffCommand = ""; + lockCommand = ""; + suspendCommand = ""; + resumeScreenOffCommand = ""; + resumeLockCommand = ""; + resumeSuspendCommand = ""; + customCommands = "[]"; + }; + desktopWidgets = { + enabled = false; + overviewEnabled = true; + gridSnap = false; + gridSnapScale = false; + monitorWidgets = [ ]; }; }; } diff --git a/modules/desktop/shell/noctalia.nix b/modules/desktop/shell/noctalia.nix index bd8eaaf..2bdab48 100644 --- a/modules/desktop/shell/noctalia.nix +++ b/modules/desktop/shell/noctalia.nix @@ -12,4 +12,5 @@ noctalia.enable = lib.mkEnableOption "enable noctalia"; }; }; + config.services.gnome.evolution-data-server.enable = true; } diff --git a/modules/server/cloud/nextcloud.nix b/modules/server/cloud/nextcloud.nix index 5977065..138051d 100644 --- a/modules/server/cloud/nextcloud.nix +++ b/modules/server/cloud/nextcloud.nix @@ -32,7 +32,7 @@ dbuser = "nextcloud"; dbhost = "/run/postgresql"; # nextcloud will add /.s.PGSQL.5432 by itself dbname = "nextcloud"; - adminpassFile = "/home/marty/secrets/nextcloud"; + adminpassFile = "/home/${config.user.userName}/secrets/nextcloud"; adminuser = "admin"; }; settings = { @@ -53,16 +53,20 @@ loglevel = 0; }; }; - postgresql = { - enable = true; - ensureDatabases = [ "nextcloud" ]; - ensureUsers = [ + postgresql = + if config.server.cloud.nextcloud.enable then { - name = "nextcloud"; - ensureDBOwnership = true; + enable = true; + ensureDatabases = [ "nextcloud" ]; + ensureUsers = [ + { + name = "nextcloud"; + ensureDBOwnership = true; + } + ]; } - ]; - }; + else + { }; nginx = { virtualHosts = { "nextcloud-net".listen = [