Poprawa integracji z portalem XDG i wsparcie dla Ulaunchera
- Dodano `xdg-desktop-portal-hyprland` do konfiguracji systemowej, Hyprlanda oraz środowiska użytkownika. - Włączono obsługę `dbus` w `initrd`, co może być wymagane przez `xdg-desktop-portal`. - Rozszerzono konfigurację portali XDG o jawne ustawienia priorytetów (`gtk`, `hyprland`). - Dodano `ulauncher` oraz `wmctrl` do listy narzędzi, a także nowe skróty klawiszowe do jego uruchamiania. - Pomimo zmian, integracja portalu XDG nie działa jeszcze zgodnie z oczekiwaniami.
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
{
|
||||
lib,
|
||||
pkgs,
|
||||
username,
|
||||
host,
|
||||
config,
|
||||
@@ -18,6 +19,7 @@ in
|
||||
enable = true;
|
||||
xwayland.enable = true;
|
||||
systemd.enable = true;
|
||||
portalPackage = pkgs.xdg-desktop-portal-hyprland;
|
||||
extraConfig = let
|
||||
modifier = "SUPER";
|
||||
in
|
||||
@@ -192,6 +194,7 @@ in
|
||||
bind = ${modifier},SPACE,togglespecialworkspace
|
||||
bind = ${modifier},Return,exec,${terminal}
|
||||
bind = ${modifier}SHIFT,Return,exec,rofi-launcher
|
||||
bind = ${modifier}ALT,SPACE,exec,ulauncher-toggle
|
||||
bind = ${modifier}ALT,W,exec,wallsetter
|
||||
bind = ${modifier}SHIFT,S,exec,screenshootin
|
||||
bind = ${modifier},E,exec,emopicker9000
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
systemd-boot.enable = true;
|
||||
efi.canTouchEfiVariables = true;
|
||||
};
|
||||
initrd.systemd.dbus.enable = true;
|
||||
# Make /tmp a tmpfs
|
||||
tmp = {
|
||||
useTmpfs = false;
|
||||
|
||||
@@ -25,6 +25,11 @@
|
||||
nixpkgs.config = {
|
||||
allowUnfree = true;
|
||||
pulseaudio = true;
|
||||
# packageOverrides = pkgs: {
|
||||
# ulauncher = pkgs.ulauncher.override {
|
||||
# autoStart = true;
|
||||
# };
|
||||
# };
|
||||
};
|
||||
|
||||
# Extra Portal Configuration
|
||||
@@ -34,12 +39,19 @@
|
||||
wlr.enable = true;
|
||||
extraPortals = [
|
||||
pkgs.xdg-desktop-portal-gtk
|
||||
pkgs.xdg-desktop-portal
|
||||
pkgs.xdg-desktop-portal-hyprland
|
||||
];
|
||||
config = {
|
||||
common = {
|
||||
default = [
|
||||
"gtk"
|
||||
"hyprland"
|
||||
];
|
||||
};
|
||||
};
|
||||
configPackages = [
|
||||
pkgs.xdg-desktop-portal-gtk
|
||||
pkgs.xdg-desktop-portal-hyprland
|
||||
pkgs.xdg-desktop-portal
|
||||
];
|
||||
};
|
||||
|
||||
|
||||
@@ -13,5 +13,7 @@
|
||||
# lazygit
|
||||
docker-slim
|
||||
dex
|
||||
ulauncher
|
||||
wmctrl
|
||||
];
|
||||
}
|
||||
|
||||
@@ -69,6 +69,11 @@
|
||||
};
|
||||
};
|
||||
};
|
||||
hyprland = {
|
||||
enable = true;
|
||||
withUWSM = true;
|
||||
portalPackage = pkgs.xdg-desktop-portal-hyprland;
|
||||
};
|
||||
dconf.enable = true;
|
||||
seahorse.enable = true;
|
||||
fuse.userAllowOther = true;
|
||||
|
||||
@@ -1,10 +1,31 @@
|
||||
{...}: {
|
||||
{pkgs, ...}: {
|
||||
# Create XDG Dirs
|
||||
xdg = {
|
||||
enable = true;
|
||||
userDirs = {
|
||||
enable = true;
|
||||
createDirectories = true;
|
||||
};
|
||||
portal = {
|
||||
enable = true;
|
||||
xdgOpenUsePortal = true;
|
||||
extraPortals = [
|
||||
pkgs.xdg-desktop-portal-gtk
|
||||
pkgs.xdg-desktop-portal-hyprland
|
||||
];
|
||||
config = {
|
||||
common = {
|
||||
default = [
|
||||
"gtk"
|
||||
"hyprland"
|
||||
];
|
||||
};
|
||||
};
|
||||
configPackages = [
|
||||
pkgs.xdg-desktop-portal-gtk
|
||||
pkgs.xdg-desktop-portal-hyprland
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
dconf.settings = {
|
||||
|
||||
@@ -49,6 +49,7 @@ in
|
||||
" + Prawy przycisk myszy" "Zmień rozmiar okna" "resizewindow" \
|
||||
" + ENTER" "Otwórz terminal" "${terminal}" \
|
||||
" + SHIFT + ENTER" "Uruchom launcher aplikacji" "rofi-launcher" \
|
||||
" + ALT + SPACE" "Uruchom Ulauncher" "ulauncher-toggle" \
|
||||
" + ALT + W" "Zmień tapetę" "wallsetter" \
|
||||
" + SHIFT + S" "Zrób zrzut ekranu" "screenshootin" \
|
||||
" + E" "Uruchom selektor emotikon" "emopicker9000" \
|
||||
|
||||
@@ -1,43 +1,43 @@
|
||||
{pkgs}:
|
||||
pkgs.writeShellScriptBin "web-search" ''
|
||||
declare -A URLS
|
||||
declare -A URLS
|
||||
|
||||
URLS=(
|
||||
["🌎 Search"]="https://search.garandplg.com/search?q="
|
||||
["❄️ Unstable Packages"]="https://search.nixos.org/packages?channel=unstable&from=0&size=50&sort=relevance&type=packages&query="
|
||||
["🎞️ YouTube"]="https://www.youtube.com/results?search_query="
|
||||
["❄️ NixOS Wiki"]="https://nixos.wiki/index.php?search="
|
||||
["🔎 Wikipedia"]="https://pl.wikipedia.org/w/index.php?ns0=1&search="
|
||||
["👨💻 StackOverflow"]="https://stackoverflow.com/search?q="
|
||||
)
|
||||
URLS=(
|
||||
["🌎 Search"]="https://search.garandplg.com/search?q="
|
||||
["❄️ Unstable Packages"]="https://search.nixos.org/packages?channel=unstable&from=0&size=50&sort=relevance&type=packages&query="
|
||||
["🎞️ YouTube"]="https://www.youtube.com/results?search_query="
|
||||
["❄️ NixOS Wiki"]="https://nixos.wiki/index.php?search="
|
||||
["🔎 Wikipedia"]="https://pl.wikipedia.org/w/index.php?ns0=1&search="
|
||||
["👨💻 StackOverflow"]="https://stackoverflow.com/search?q="
|
||||
)
|
||||
|
||||
# List for rofi
|
||||
gen_list() {
|
||||
for i in "''${!URLS[@]}"
|
||||
do
|
||||
echo "$i"
|
||||
done
|
||||
}
|
||||
# List for rofi
|
||||
gen_list() {
|
||||
for i in "''${!URLS[@]}"
|
||||
do
|
||||
echo "$i"
|
||||
done
|
||||
}
|
||||
|
||||
main() {
|
||||
# Pass the list to rofi
|
||||
platform=$( (gen_list) | ${pkgs.wofi}/bin/wofi -dmenu )
|
||||
main() {
|
||||
# Pass the list to rofi
|
||||
platform=$( (gen_list) | ${pkgs.wofi}/bin/wofi -dmenu )
|
||||
|
||||
if [[ -n "$platform" ]]; then
|
||||
query=$( (echo ) | ${pkgs.wofi}/bin/wofi -dmenu )
|
||||
if [[ -n "$platform" ]]; then
|
||||
query=$( (echo ) | ${pkgs.wofi}/bin/wofi -dmenu )
|
||||
|
||||
if [[ -n "$query" ]]; then
|
||||
url=''${URLS[$platform]}$query
|
||||
xdg-open "$url"
|
||||
else
|
||||
exit
|
||||
fi
|
||||
else
|
||||
exit
|
||||
fi
|
||||
}
|
||||
if [[ -n "$query" ]]; then
|
||||
url=''${URLS[$platform]}$query
|
||||
xdg-open "$url"
|
||||
else
|
||||
exit
|
||||
fi
|
||||
else
|
||||
exit
|
||||
fi
|
||||
}
|
||||
|
||||
main
|
||||
main
|
||||
|
||||
exit 0
|
||||
exit 0
|
||||
''
|
||||
|
||||
Reference in New Issue
Block a user