Compare commits
3 commits
1d85769bc7
...
61e5074af3
Author | SHA1 | Date | |
---|---|---|---|
61e5074af3 | |||
227161c1a6 | |||
011ec1b725 |
4 changed files with 99 additions and 0 deletions
54
.config/i3status/config
Normal file
54
.config/i3status/config
Normal file
|
@ -0,0 +1,54 @@
|
||||||
|
# i3status configuration file.
|
||||||
|
# see "man i3status" for documentation.
|
||||||
|
|
||||||
|
# It is important that this file is edited as UTF-8.
|
||||||
|
# The following line should contain a sharp s:
|
||||||
|
# ß
|
||||||
|
# If the above line is not correctly displayed, fix your editor first!
|
||||||
|
|
||||||
|
general {
|
||||||
|
colors = false
|
||||||
|
interval = 5
|
||||||
|
output_format = "i3bar"
|
||||||
|
}
|
||||||
|
|
||||||
|
#order += "ipv6"
|
||||||
|
order += "wireless _first_"
|
||||||
|
order += "ethernet _first_"
|
||||||
|
order += "battery all"
|
||||||
|
#order += "disk /"
|
||||||
|
#order += "load"
|
||||||
|
#order += "memory"
|
||||||
|
order += "tztime local"
|
||||||
|
|
||||||
|
wireless _first_ {
|
||||||
|
format_up = "WiFi"
|
||||||
|
format_down = "sin WiFi"
|
||||||
|
}
|
||||||
|
|
||||||
|
ethernet _first_ {
|
||||||
|
format_up = "Eth %ip"
|
||||||
|
format_down = ""
|
||||||
|
}
|
||||||
|
|
||||||
|
battery all {
|
||||||
|
format = "%status %percentage"
|
||||||
|
}
|
||||||
|
|
||||||
|
disk "/" {
|
||||||
|
format = "%avail"
|
||||||
|
}
|
||||||
|
|
||||||
|
load {
|
||||||
|
format = "%1min"
|
||||||
|
}
|
||||||
|
|
||||||
|
memory {
|
||||||
|
format = "%used | %available"
|
||||||
|
threshold_degraded = "1G"
|
||||||
|
format_degraded = "MEMORY < %available"
|
||||||
|
}
|
||||||
|
|
||||||
|
tztime local {
|
||||||
|
format = "%A %m/%d %H:%M"
|
||||||
|
}
|
5
.config/mpv/mpv.conf
Normal file
5
.config/mpv/mpv.conf
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
sub-font=Inter
|
||||||
|
sub-blur=10
|
||||||
|
slang=eng,spa
|
||||||
|
save-position-on-quit=yes
|
||||||
|
hwdec=vaapi
|
34
.config/mpv/scripts/playlist.lua
Normal file
34
.config/mpv/scripts/playlist.lua
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
mp.add_key_binding("y", "fzf", function ()
|
||||||
|
local pl = mp.get_property_native("playlist")
|
||||||
|
if not pl then return end
|
||||||
|
|
||||||
|
local input_path = os.tmpname()
|
||||||
|
local input_file = io.open(input_path, "w")
|
||||||
|
for i, v in pairs(pl) do
|
||||||
|
local desc = v.filename
|
||||||
|
if v.title then desc = v.title end
|
||||||
|
input_file:write(i-1 .. ": " .. desc .. "\n")
|
||||||
|
end
|
||||||
|
input_file:close()
|
||||||
|
|
||||||
|
local output_path = os.tmpname()
|
||||||
|
os.execute("footclient bash -i -c 'cat "..input_path.." | fzf --no-sort > "..output_path.."'")
|
||||||
|
|
||||||
|
local output_file = io.open(output_path, "r")
|
||||||
|
local line = output_file:read("*l")
|
||||||
|
output_file:close()
|
||||||
|
os.remove(output_path)
|
||||||
|
|
||||||
|
if line then
|
||||||
|
local index = string.match(line, "%d+")
|
||||||
|
mp.commandv("playlist-play-index", index)
|
||||||
|
end
|
||||||
|
|
||||||
|
os.remove(input_path)
|
||||||
|
end)
|
||||||
|
|
||||||
|
mp.observe_property("media-title", "native", function (name, value)
|
||||||
|
if value then
|
||||||
|
print("Playing: " .. value)
|
||||||
|
end
|
||||||
|
end)
|
|
@ -1,8 +1,14 @@
|
||||||
source ~/.profile
|
source ~/.profile
|
||||||
if ! "$REMOTE" && test "$(tty)" = /dev/tty1; then
|
if ! "$REMOTE" && test "$(tty)" = /dev/tty1; then
|
||||||
|
doas mkdir -p /run/user
|
||||||
|
doas chmod 777 /run/user
|
||||||
|
XDG_RUNTIME_DIR="/run/user/$(id -u)"
|
||||||
|
mkdir -p "$XDG_RUNTIME_DIR"
|
||||||
|
chmod 700 "$XDG_RUNTIME_DIR"
|
||||||
mkdir -p "$HOME/.local/share/sway"
|
mkdir -p "$HOME/.local/share/sway"
|
||||||
log="$HOME/.local/share/sway/$(date +%Y-%m-%d@%H:%M:%S).log"
|
log="$HOME/.local/share/sway/$(date +%Y-%m-%d@%H:%M:%S).log"
|
||||||
exec env \
|
exec env \
|
||||||
|
XDG_RUNTIME_DIR="$XDG_RUNTIME_DIR" \
|
||||||
XDG_CURRENT_DESKTOP=sway \
|
XDG_CURRENT_DESKTOP=sway \
|
||||||
XDG_SESSION_DESKTOP=sway \
|
XDG_SESSION_DESKTOP=sway \
|
||||||
dbus-run-session sway >"$log" 2>&1
|
dbus-run-session sway >"$log" 2>&1
|
||||||
|
|
Loading…
Reference in a new issue