nu: add rewatch command to sys.nu
This commit is contained in:
@@ -1,10 +0,0 @@
|
||||
{
|
||||
"hooksConfig": {
|
||||
"disabled": [
|
||||
"security-gate",
|
||||
"slm-memory-sync",
|
||||
"dynamic-context",
|
||||
"slm-observe"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
[Desktop Entry]
|
||||
Name=OpenCloud Desktop
|
||||
GenericName=File Synchronizer
|
||||
Exec=/usr/bin/opencloud
|
||||
Terminal=false
|
||||
Icon=opencloud
|
||||
Categories=Network
|
||||
Type=Application
|
||||
StartupNotify=false
|
||||
X-GNOME-Autostart-enabled=true
|
||||
X-GNOME-Autostart-Delay=10
|
||||
@@ -14,6 +14,17 @@ def ports [] {
|
||||
| sort-by port
|
||||
}
|
||||
|
||||
# Repeatedly clears and reruns a closure — nu-native watch replacement
|
||||
def rewatch [interval: duration, cmd: closure] {
|
||||
loop {
|
||||
clear
|
||||
let dim = $env.config.color_config.hints
|
||||
print $"(ansi --escape $dim)(date now | format date '%H:%M:%S')(ansi reset)"
|
||||
do $cmd
|
||||
sleep $interval
|
||||
}
|
||||
}
|
||||
|
||||
# Environment variables as a filterable sorted table
|
||||
def envs [query?: string] {
|
||||
$env | transpose key value
|
||||
|
||||
@@ -1,24 +0,0 @@
|
||||
{
|
||||
"name": "Apex Aeon",
|
||||
"type": "custom",
|
||||
"Background": "#f5f5f5",
|
||||
"Foreground": "#0a0a0a",
|
||||
"LightBlue": "#33bccc",
|
||||
"AccentBlue": "#007a88",
|
||||
"AccentPurple": "#7a3cff",
|
||||
"AccentCyan": "#33bccc",
|
||||
"AccentGreen": "#00b377",
|
||||
"AccentYellow": "#d18f00",
|
||||
"AccentRed": "#ff0044",
|
||||
"Comment": "#737373",
|
||||
"Gray": "#a0a0a0",
|
||||
"DiffAdded": "#00b377",
|
||||
"DiffRemoved": "#ff0044",
|
||||
"DiffModified": "#d18f00",
|
||||
"text": {
|
||||
"primary": "#0a0a0a",
|
||||
"secondary": "#737373",
|
||||
"accent": "#007a88",
|
||||
"response": "#0a0a0a"
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
{
|
||||
"name": "Apex Neon",
|
||||
"type": "custom",
|
||||
"Background": "#050505",
|
||||
"Foreground": "#ededed",
|
||||
"LightBlue": "#5af3ff",
|
||||
"AccentBlue": "#00eaff",
|
||||
"AccentPurple": "#9d00ff",
|
||||
"AccentCyan": "#5af3ff",
|
||||
"AccentGreen": "#00ff99",
|
||||
"AccentYellow": "#ffb700",
|
||||
"AccentRed": "#ff0044",
|
||||
"Comment": "#737373",
|
||||
"Gray": "#404040",
|
||||
"DiffAdded": "#00ff99",
|
||||
"DiffRemoved": "#ff0044",
|
||||
"DiffModified": "#ffb700",
|
||||
"text": {
|
||||
"primary": "#ededed",
|
||||
"secondary": "#737373",
|
||||
"accent": "#00eaff",
|
||||
"response": "#ededed"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user