ff1cdc02b9
Initial nushell dotfiles: config, modules (git, k8s, sys, hypr, pkg, dev), apex theme files, and a chezmoi-templated prompt that shows dir and git branch/dirty using apex-neon/aeon colors with vi mode indicators.
28 lines
738 B
Nu
28 lines
738 B
Nu
# All open windows as a table (class, title, workspace, floating, pid, pos, size)
|
|
def wins [] {
|
|
^hyprctl clients -j | from json
|
|
| each {|w| {
|
|
class: $w.class
|
|
title: $w.title
|
|
workspace: $w.workspace.name
|
|
floating: $w.floating
|
|
pid: $w.pid
|
|
pos: $"($w.at.0),($w.at.1)"
|
|
size: $"($w.size.0)x($w.size.1)"
|
|
}}
|
|
}
|
|
|
|
# Workspaces with window count, sorted by id
|
|
def wsps [] {
|
|
^hyprctl workspaces -j | from json
|
|
| select id name monitor windows hasfullscreen
|
|
| sort-by id
|
|
}
|
|
|
|
# Currently focused window as a record
|
|
def hypr-active [] {
|
|
^hyprctl activewindow -j | from json
|
|
| select class title workspace floating pid
|
|
| upsert workspace { get workspace | get name }
|
|
}
|