update
and adapt setup to changes
This commit is contained in:
@@ -56,11 +56,4 @@
|
||||
};
|
||||
|
||||
programs.home-manager.enable = true;
|
||||
|
||||
nixpkgs.config = {
|
||||
allowUnfree = true;
|
||||
permittedInsecurePackages = [
|
||||
"electron-32.3.3"
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -198,8 +198,18 @@
|
||||
:text "${date}")))
|
||||
|
||||
;; ── River State ─────────────────────────────────────────────────────
|
||||
(deflisten river_tag
|
||||
:initial ""
|
||||
`ristate -t | jq -r '.tags.Unknown[0] // empty'`)
|
||||
|
||||
(deflisten river_title
|
||||
:initial "-"
|
||||
`ristate -w | jq -r '.title // "-"'`)
|
||||
|
||||
(deflisten river_layout
|
||||
:initial "-"
|
||||
`ristate -l | jq -r '.layout // "-"'`)
|
||||
|
||||
(defvar ws1 "ws-empty")
|
||||
(defvar ws2 "ws-empty")
|
||||
(defvar ws3 "ws-empty")
|
||||
(defvar ws4 "ws-empty")
|
||||
@@ -220,7 +230,7 @@
|
||||
:orientation "horizontal"
|
||||
:class "workspace-buttons"
|
||||
|
||||
(button :onclick "riverctl set-focused-tags 1" :class "workspace-button ${ws1}" (label :text "1"))
|
||||
(button :onclick "riverctl set-focused-tags 1" :class "workspace-button ${if river_tag == \"1\" {\"ws-current\"} {\"ws-empty\"}}" (label :text "1"))
|
||||
(label :text " ")
|
||||
(button :onclick "riverctl set-focused-tags 2" :class "workspace-button ${ws2}" (label :text "2"))
|
||||
(label :text " ")
|
||||
@@ -232,7 +242,7 @@
|
||||
(label :text " ")
|
||||
(button :onclick "riverctl set-focused-tags 6" :class "workspace-button ${ws6}" (label :text "6"))
|
||||
(label :text " ")
|
||||
(button :onclick "riverctl set-focused-tags 7" :class "workspace-button ${ws7}" (label :text "7"))
|
||||
(button :onclick "riverctl set-focused-tags 7" :class "workspace-button {if river_tag == \"1\" {\"ws-current\"} {\"ws-empty\"}}" (label :text "s"))
|
||||
(label :text " ")
|
||||
(button :onclick "riverctl set-focused-tags 8" :class "workspace-button ${ws8}" (label :text "8"))
|
||||
(label :text " ")
|
||||
@@ -241,11 +251,11 @@
|
||||
|
||||
(defwidget widgetWindows []
|
||||
(label
|
||||
:text "${windows}"))
|
||||
:text "${river_title}"))
|
||||
|
||||
(defwidget widgetLayouts []
|
||||
(label
|
||||
:text "${layouts}"))
|
||||
:text "${river_layout}"))
|
||||
|
||||
(defwidget widgetLogSeperator []
|
||||
(label
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
TEMP_FILE="/tmp/river-eww-status"
|
||||
|
||||
while true; do
|
||||
ristate -t >"$TEMP_FILE.tmp"
|
||||
ristate -w >>"$TEMP_FILE.tmp"
|
||||
mv "$TEMP_FILE.tmp" "$TEMP_FILE"
|
||||
sleep 1
|
||||
done
|
||||
@@ -1,32 +1,35 @@
|
||||
TEMP_FILE="/tmp/river-eww-status"
|
||||
layout=$(ristate -l 2>/dev/null | jq -r '.layout // ""')
|
||||
title=$(ristate -w 2>/dev/null | jq -r '.title // ""')
|
||||
tags_json=$(ristate -t 2>/dev/null)
|
||||
views_json=$(ristate -vt 2>/dev/null)
|
||||
|
||||
# Read last two lines (layout/tags and focused window)
|
||||
json=$(tail -n2 "$TEMP_FILE" | head -n1)
|
||||
win_json=$(tail -n1 "$TEMP_FILE")
|
||||
mapfile -t focused_tags < <(
|
||||
printf '%s\n' "$views_json" |
|
||||
jq -r '.viewstag.Unknown // [] | .[] | tostring'
|
||||
)
|
||||
|
||||
# Extract layout
|
||||
layout=$(echo "$json" | jq -r '.layout // ""')
|
||||
if [ "${#focused_tags[@]}" -eq 0 ]; then
|
||||
mapfile -t focused_tags < <(
|
||||
printf '%s\n' "$tags_json" |
|
||||
jq -r '.tags.Unknown // [] | .[] | tostring'
|
||||
)
|
||||
fi
|
||||
|
||||
# Extract focused window title
|
||||
windows=$(echo "$win_json" | jq -r '.title // ""')
|
||||
|
||||
# Extract focused tags as array
|
||||
mapfile -t focused_tags < <(echo "$json" | jq -r '.tags.BOE // [] | .[]')
|
||||
|
||||
# Update workspace classes
|
||||
for i in $(seq 1 9); do
|
||||
class="ws-empty"
|
||||
for tag in "${focused_tags[@]}"; do
|
||||
if [[ "$tag" == "$i" ]]; then
|
||||
class="ws-current"
|
||||
echo "$tag - current"
|
||||
break
|
||||
fi
|
||||
done
|
||||
eww update ws$i="$class"
|
||||
eww update "ws$i=$class"
|
||||
done
|
||||
|
||||
# Update layout
|
||||
eww update layouts="$layout"
|
||||
|
||||
# Output focused window for widget
|
||||
eww update "layouts=$layout"
|
||||
echo "$layouts"
|
||||
eww update "windows=$title"
|
||||
echo "$windows"
|
||||
|
||||
echo "$title"
|
||||
|
||||
@@ -76,17 +76,20 @@ in
|
||||
plugin = {
|
||||
prepend_previewers = [
|
||||
{
|
||||
group = "preview";
|
||||
run = "exifaudio";
|
||||
mime = "audio/*";
|
||||
}
|
||||
];
|
||||
prepend_fetchers = [
|
||||
{
|
||||
group = "fetcher";
|
||||
id = "git";
|
||||
url = "*";
|
||||
run = "git";
|
||||
}
|
||||
{
|
||||
group = "fetcher";
|
||||
id = "git";
|
||||
url = "*/";
|
||||
run = "git";
|
||||
|
||||
@@ -12,7 +12,10 @@
|
||||
enable = true;
|
||||
defaultEditor = true;
|
||||
|
||||
nixpkgs.useGlobalPackages = false;
|
||||
nixpkgs = {
|
||||
useGlobalPackages = false;
|
||||
config.allowUnfree = true;
|
||||
};
|
||||
|
||||
clipboard.providers.wl-copy.enable = true;
|
||||
keymaps = [
|
||||
|
||||
@@ -54,13 +54,6 @@
|
||||
tls.enable = true;
|
||||
};
|
||||
realName = "Elias Schröter";
|
||||
signature = {
|
||||
text = ''
|
||||
Mit freundlichen Grüßen,
|
||||
Elias Schröter.
|
||||
'';
|
||||
showSignature = "append";
|
||||
};
|
||||
passwordCommand = "mail-password";
|
||||
smtp = {
|
||||
host = "postout.lrz.de";
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.vscode = {
|
||||
programs.vscodium = {
|
||||
enable = true;
|
||||
package = pkgs.vscodium;
|
||||
profiles.default = {
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
home.packages = with pkgs; [ zoom-us ];
|
||||
}
|
||||
|
||||
@@ -52,7 +52,7 @@ in
|
||||
enableNushellIntegration = true;
|
||||
defaultCacheTtl = 60;
|
||||
maxCacheTtl = 120;
|
||||
enableSshSupport = true;
|
||||
# enableSshSupport = true;
|
||||
sshKeys = [ "8E42E6C65D5F9894CFFF294851AB0CEB5F0B1FAA" ];
|
||||
pinentry.package = pkgs.pinentry-gnome3;
|
||||
# under extraConfig
|
||||
|
||||
Reference in New Issue
Block a user