mirror of
https://github.com/zoriya/flake.git
synced 2025-12-06 06:36:19 +00:00
Init quickshell
This commit is contained in:
17
.editorconfig
Normal file
17
.editorconfig
Normal file
@@ -0,0 +1,17 @@
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
indent_style = tab
|
||||
indent_size = tab
|
||||
|
||||
[{*.yaml,*.yml,*.nix}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*.qml]
|
||||
indent_style = tab
|
||||
indent_size = 2
|
||||
42
flake.lock
generated
42
flake.lock
generated
@@ -81,11 +81,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1763424377,
|
||||
"narHash": "sha256-le7Pl92+UgbftZNQH8+nJnERVGTrfKMuQgaJIc4VsB0=",
|
||||
"lastModified": 1763683496,
|
||||
"narHash": "sha256-k20voxbsi+899PeXlvWpKU5tcgNYfNqC52rgrh+MOto=",
|
||||
"owner": "nix-community",
|
||||
"repo": "neovim-nightly-overlay",
|
||||
"rev": "f15729dbae4e51ffa77b62abdd59d555d73b6cfb",
|
||||
"rev": "1ddc8e956c8165df29735202b76bb0cfa827916d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -97,11 +97,11 @@
|
||||
"neovim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1763404442,
|
||||
"narHash": "sha256-2mWXjP4vKxUsfF/UNkfO587fbl7iyXv/ARf6fFv6Gik=",
|
||||
"lastModified": 1763682595,
|
||||
"narHash": "sha256-/dUf5I0DyLvPgFzjJj0/lUHKZ2M1sVlbYCgudDabxIo=",
|
||||
"owner": "neovim",
|
||||
"repo": "neovim",
|
||||
"rev": "c4ac36bfd9bc9826dde01839d10d0e65a7b3c9e2",
|
||||
"rev": "a8b9660ca3452a27b68bf914f618df2d78b64180",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -117,11 +117,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1763136804,
|
||||
"narHash": "sha256-6p2ljK42s0S8zS0UU59EsEqupz0GVCaBYRylpUadeBM=",
|
||||
"lastModified": 1763505477,
|
||||
"narHash": "sha256-nJRd4LY2kT3OELfHqdgWjvToNZ4w+zKCMzS2R6z4sXE=",
|
||||
"owner": "LnL7",
|
||||
"repo": "nix-darwin",
|
||||
"rev": "973db96394513fd90270ea5a1211a82a4a0ba47f",
|
||||
"rev": "3bda9f6b14161becbd07b3c56411f1670e19b9b5",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -192,11 +192,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1763385941,
|
||||
"narHash": "sha256-99CBNgyMvg3Zu/hxqixtShevrF4Kfr/qjtizQ6oseVI=",
|
||||
"lastModified": 1763587902,
|
||||
"narHash": "sha256-kYhcVG34C5MThK6JQp2UeGTooFgi3XEElGk2TNFcTWg=",
|
||||
"owner": "nix-community",
|
||||
"repo": "NixOS-WSL",
|
||||
"rev": "cc6483354b236c2fc95cc1d4ba1f0f40b7345e69",
|
||||
"rev": "cce7a45e8fb3398f669bfd54aaa15047e70c81a8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -223,11 +223,11 @@
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1763283776,
|
||||
"narHash": "sha256-Y7TDFPK4GlqrKrivOcsHG8xSGqQx3A6c+i7novT85Uk=",
|
||||
"lastModified": 1763421233,
|
||||
"narHash": "sha256-Stk9ZYRkGrnnpyJ4eqt9eQtdFWRRIvMxpNRf4sIegnw=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "50a96edd8d0db6cc8db57dab6bb6d6ee1f3dc49a",
|
||||
"rev": "89c2b2330e733d6cdb5eae7b899326930c2c0648",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -254,11 +254,11 @@
|
||||
"tmux": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1763114468,
|
||||
"narHash": "sha256-xL9lGjc/yN2F4faz2WW1QPoW63xXUA35T8AFczbBSWs=",
|
||||
"lastModified": 1763460067,
|
||||
"narHash": "sha256-TXApnm9VpHEeUnfzz+jKc8q5RJBqv54eBd8d2sVNW3E=",
|
||||
"owner": "tmux",
|
||||
"repo": "tmux",
|
||||
"rev": "f372112a8df8c4fa0de6f202ea4f707e312dcc97",
|
||||
"rev": "348f16093c35cbb318281e68f4405dae5b2627d1",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -274,11 +274,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1763352549,
|
||||
"narHash": "sha256-hzLnXm0v1snDENpF3KvUQBO8XOAh45qg+y4D46K3rz8=",
|
||||
"lastModified": 1763697957,
|
||||
"narHash": "sha256-p6CTJoeM3EK9tcqm6lgnKZFVJiGHCzcCftkko4EpEb0=",
|
||||
"owner": "youwen5",
|
||||
"repo": "zen-browser-flake",
|
||||
"rev": "5d002fcacbc5423090f2bba19818adda471fe0c8",
|
||||
"rev": "9eb198a4d7ea4bd1284254780e3c22533f743d55",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
||||
@@ -14,10 +14,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
qt = {
|
||||
enable = true;
|
||||
platformTheme.name = "gtk";
|
||||
};
|
||||
qt.enable = true;
|
||||
|
||||
home.pointerCursor = {
|
||||
gtk.enable = true;
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
in {
|
||||
imports = [
|
||||
./rofi
|
||||
./ags
|
||||
./quickshell
|
||||
./fcitx5.nix
|
||||
./hyprlock.nix
|
||||
];
|
||||
|
||||
1
modules/wm/quickshell/.qmlformat.ini
Normal file
1
modules/wm/quickshell/.qmlformat.ini
Normal file
@@ -0,0 +1 @@
|
||||
UseTabs=true
|
||||
1
modules/wm/quickshell/.qmlls.ini
Symbolic link
1
modules/wm/quickshell/.qmlls.ini
Symbolic link
@@ -0,0 +1 @@
|
||||
/run/user/1000/quickshell/vfs/61f729b565ae1eaaa7b71145d10755fe/.qmlls.ini
|
||||
10
modules/wm/quickshell/default.nix
Normal file
10
modules/wm/quickshell/default.nix
Normal file
@@ -0,0 +1,10 @@
|
||||
{
|
||||
programs.quickshell = {
|
||||
enable = true;
|
||||
systemd.enable = true;
|
||||
configs = {
|
||||
default = ./.;
|
||||
};
|
||||
activeConfig = "default";
|
||||
};
|
||||
}
|
||||
16
modules/wm/quickshell/shell.qml
Normal file
16
modules/wm/quickshell/shell.qml
Normal file
@@ -0,0 +1,16 @@
|
||||
import Quickshell
|
||||
import QtQuick
|
||||
import qs.widgets
|
||||
|
||||
|
||||
ShellRoot {
|
||||
Bar {}
|
||||
|
||||
Connections {
|
||||
function onReloadCompleted() {
|
||||
Quickshell.inhibitReloadPopup();
|
||||
}
|
||||
|
||||
target: Quickshell
|
||||
}
|
||||
}
|
||||
13
modules/wm/quickshell/utils/Settings.qml
Normal file
13
modules/wm/quickshell/utils/Settings.qml
Normal file
@@ -0,0 +1,13 @@
|
||||
pragma Singleton
|
||||
|
||||
import Quickshell
|
||||
import QtQuick
|
||||
|
||||
Singleton {
|
||||
id: root
|
||||
property QtObject colors
|
||||
|
||||
colors: QtObject {
|
||||
readonly property color base: "#313244"
|
||||
}
|
||||
}
|
||||
37
modules/wm/quickshell/widgets/Bar.qml
Normal file
37
modules/wm/quickshell/widgets/Bar.qml
Normal file
@@ -0,0 +1,37 @@
|
||||
import Quickshell
|
||||
import QtQuick
|
||||
|
||||
import qs.utils
|
||||
|
||||
Scope {
|
||||
Variants {
|
||||
model: Quickshell.screens
|
||||
|
||||
delegate: Component {
|
||||
PanelWindow {
|
||||
required property var modelData
|
||||
|
||||
screen: modelData
|
||||
anchors {
|
||||
top: true
|
||||
left: true
|
||||
right: true
|
||||
}
|
||||
color: Settings.colors.base
|
||||
|
||||
implicitHeight: 30
|
||||
|
||||
Text {
|
||||
anchors.centerIn: parent
|
||||
|
||||
text: Qt.formatDateTime(clock.date, "hh:mm")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
SystemClock {
|
||||
id: clock
|
||||
precision: SystemClock.Minutes
|
||||
}
|
||||
}
|
||||
@@ -11,13 +11,6 @@ vim.api.nvim_create_autocmd('LspAttach', {
|
||||
return {
|
||||
-- Disable lunching from node_modules (no nix binary)
|
||||
cmd = { "biome", "lsp-proxy" },
|
||||
-- Inline package.json (remove check for biome installed)
|
||||
root_dir = function(_, on_dir)
|
||||
-- To support monorepos, biome recommends starting the search for the root from cwd
|
||||
-- https://biomejs.dev/guides/big-projects/#use-multiple-configuration-files
|
||||
local cwd = vim.fn.getcwd()
|
||||
local root_files = { 'biome.json', 'biome.jsonc', 'package.json', 'package.json5' }
|
||||
local root_dir = vim.fs.dirname(vim.fs.find(root_files, { path = cwd, upward = true })[1])
|
||||
on_dir(root_dir)
|
||||
end,
|
||||
-- for json files
|
||||
workspace_required = false,
|
||||
}
|
||||
|
||||
@@ -140,6 +140,7 @@ in
|
||||
bash-language-server
|
||||
sqls
|
||||
biome
|
||||
kdePackages.qtdeclarative # qmlls
|
||||
|
||||
# gopls also needs go /shame
|
||||
gopls
|
||||
|
||||
@@ -35,6 +35,16 @@ return {
|
||||
modes = { n = "q", i = "<C-d>" },
|
||||
},
|
||||
},
|
||||
tools = {
|
||||
opts = {
|
||||
auto_submit_success = true,
|
||||
auto_submit_errors = true,
|
||||
default_tools = {
|
||||
"files",
|
||||
}
|
||||
},
|
||||
|
||||
}
|
||||
},
|
||||
inline = {
|
||||
adapter = "copilot",
|
||||
|
||||
@@ -18,6 +18,7 @@ vim.lsp.enable({
|
||||
"jsonls",
|
||||
"biome",
|
||||
"sqls",
|
||||
"qmlls"
|
||||
-- "roslyn_ls", we use roslyn.nvim plugin instead.
|
||||
})
|
||||
|
||||
|
||||
@@ -28,12 +28,6 @@ in {
|
||||
--set TMUX ""
|
||||
'';
|
||||
|
||||
# it doesn't start without this, no clue why.
|
||||
freecad = wrapProgram super.freecad ["freecad" "FreeCAD" "freecadcmd" "FreeCADCmd"] ''
|
||||
--set QT_QPA_PLATFORM 'wayland;xcb' \
|
||||
--set QT_QPA_PLATFORMTHEME qt5ct
|
||||
'';
|
||||
|
||||
# Gnome-control-center can only be launched if XDG_CURRENT_DESKTOP is GNOME.
|
||||
gnome-control-center = wrapProgram super.gnome-control-center ["gnome-control-center"] "--set XDG_CURRENT_DESKTOP GNOME";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user