removing quickshell and spicetify

This commit is contained in:
Charlie Root 2024-08-20 21:47:59 +02:00
commit 8c28805def
16 changed files with 42 additions and 383 deletions

View file

@ -4,7 +4,6 @@ _: {
./foot.nix
./mpv.nix
./zathura.nix
./spicetify.nix
./steam.nix
./waybar.nix
./schizofox.nix

View file

@ -1,31 +0,0 @@
{
config,
pkgs,
lib,
inputs,
inputs',
...
}: let
cfg = config.modules.system.programs.spotify;
inherit (config.modules.other.system) username;
spicePkgs = inputs'.spicetify-nix.legacyPackages;
in {
config = lib.mkIf cfg.enable {
home-manager.users.${username} = {
imports = [inputs.spicetify-nix.homeManagerModules.default];
programs.spicetify = {
enable = true;
spotifyPackage = pkgs.spotify;
theme = spicePkgs.themes.catppuccin;
colorScheme = "mocha";
enabledExtensions = with spicePkgs.extensions; [
# shuffle
# popupLyrics
adblock
# betterGenres
# playlistIcons
];
};
};
};
}

View file

@ -10,6 +10,7 @@
in {
config = {
home-manager.users.${username}.programs.fuzzel = mkIf cfg.enable {
# enable schizo dnklware!
enable = true;
package = pkgs.fuzzel;
settings = {

View file

@ -1,6 +1,5 @@
_: {
imports = [
./quickshell
./qt.nix
./gtk.nix
./module.nix

View file

@ -1,27 +0,0 @@
import Quickshell // for ShellRoot and PanelWindow
import Quickshell.Io // For Processes
import QtQuick // For Text
Scope {
Variants {
model: Quickshell.screens
PanelWindow {
property var modelData
screen: modelData
anchors {
bottom: true
left: true
right: true
}
height: 25
ClockWidget {
anchors.centerIn: parent
}
}
}
}

View file

@ -1,31 +0,0 @@
import Quickshell.Io
import QtQuick
import QtQuick.Layouts
Item {
property string time
Text {
text: time
}
Process {
id: dateProc
command: ["date", "-u", "+%a, %d %b %H:%M:%S"]
running: true
stdout: SplitParser {
onRead: data => time = data
}
}
Timer {
interval: 1000
running: true
repeat: true
onTriggered: dateProc.running = true
}
}

View file

@ -1,6 +0,0 @@
import Quickshell // for ShellRoot and PanelWindow
ShellRoot {
Bar {}
}

View file

@ -1,28 +0,0 @@
// with this line our type becomes a singleton
pragma Singleton
import Quickshell
import Quickshell.Io
import QtQuick
// your singletons should always have Singleton as the type
Singleton {
property string time
Process {
id: dateProc
command: ["date"]
running: true
stdout: SplitParser {
onRead: data => time = data
}
}
Timer {
interval: 1000
running: true
repeat: true
onTriggered: dateProc.running = true
}
}

View file

@ -1,110 +0,0 @@
import QtQuick
import QtQuick.Layouts
import Quickshell.Hyprland
import ".."
import "root:."
MouseArea {
id: root
required property var bar;
required property int wsBaseIndex;
property int wsCount: 10;
property bool hideWhenEmpty: false;
implicitHeight: column.implicitHeight + 10;
acceptedButtons: Qt.NoButton
onWheel: event => {
event.accepted = true;
const step = -Math.sign(event.angleDelta.y);
const targetWs = currentIndex + step;
if (targetWs >= wsBaseIndex && targetWs < wsBaseIndex + wsCount) {
Hyprland.dispatch(`workspace ${targetWs}`)
}
}
readonly property HyprlandMonitor monitor: Hyprland.monitorFor(bar.screen);
property int currentIndex: 0;
property int existsCount: 0;
visible: !hideWhenEmpty || existsCount > 0;
property real animPos: 0;
Behavior on animPos { SmoothedAnimation { velocity: 100 } }
// destructor takes care of nulling
signal workspaceAdded(workspace: HyprlandWorkspace);
ColumnLayout {
id: column
spacing: 0
anchors {
fill: parent;
topMargin: 0;
margins: 5;
}
Repeater {
model: 10
MouseArea {
id: wsItem
onPressed: Hyprland.dispatch(`workspace ${wsIndex}`);
Layout.fillWidth: true
implicitHeight: 15
required property int index;
property int wsIndex: wsBaseIndex + index;
property HyprlandWorkspace workspace: null;
property bool exists: workspace != null;
property bool active: (monitor?.activeWorkspace ?? false) && monitor.activeWorkspace == workspace;
onActiveChanged: {
if (active) root.currentIndex = wsIndex;
}
onExistsChanged: {
root.existsCount += exists ? 1 : -1;
}
Connections {
target: root
function onWorkspaceAdded(workspace: HyprlandWorkspace) {
if (workspace.id == wsItem.wsIndex) {
wsItem.workspace = workspace;
}
}
}
property real animActive: active ? 100 : 0
Behavior on animActive { NumberAnimation { duration: 100 } }
property real animExists: exists ? 100 : 0
Behavior on animExists { NumberAnimation { duration: 100 } }
Rectangle {
anchors.centerIn: parent
height: 10
width: parent.width
scale: 1 + animActive * 0.003
radius: height / 2
border.color: ShellGlobals.colors.widgetOutline
border.width: 1
color: ShellGlobals.interpolateColors(animExists * 0.01, ShellGlobals.colors.widget, ShellGlobals.colors.widgetActive);
}
}
}
}
Connections {
target: Hyprland.workspaces
function onObjectInsertedPost(workspace) {
root.workspaceAdded(workspace);
}
}
Component.onCompleted: {
Hyprland.workspaces.values.forEach(workspace => {
root.workspaceAdded(workspace)
});
}
}

View file

@ -1,28 +0,0 @@
{
config,
lib,
inputs,
pkgs,
impurity,
...
}: let
inherit (inputs) quickshell;
inherit (lib) mkIf mkEnableOption;
inherit (lib.generators) toKeyValue;
inherit (config.modules.other.system) username;
cfg = config.modules.theming.quickshell;
in {
options.modules.theming.quickshell.enable = mkEnableOption "quickshell";
config = mkIf cfg.enable {
environment.systemPackages = with pkgs; [
qt6.qtimageformats
qt6.qt5compat
quickshell.packages."x86_64-linux".default
pamtester
];
home-manager.users.${username}.xdg.configFile."quickshell/manifest.conf".text = toKeyValue {} {
# bar = "${impurity.link ./bar}";
# bar = "${./bar}";
};
};
}

View file

@ -7,7 +7,6 @@
}: let
cfg = config.modules.usrEnv.desktops.hyprland;
inherit (config.modules.other.system) username;
inherit (inputs'.anyrun.packages) anyrun;
inherit (config.modules.style) cursor;
inherit
(inputs'.nixpkgs-wayland.packages)
@ -218,7 +217,7 @@ in {
"$mainMod, RETURN, exec, ${foot}/bin/foot"
"$mainMod, Q, killactive"
"$mainMod, F, fullscreen, 0"
"$mainMod, D, exec, ${pkgs.procps}/bin/pkill fuzzel || ${anyrun}/bin/fuzzel"
"$mainMod, D, exec, ${pkgs.procps}/bin/pkill fuzzel || ${pkgs.fuzzel}/bin/fuzzel"
"$mainMod, SPACE, togglefloating, active"
# workspaces