mirror of
https://codeberg.org/frosty/dotfiles.git
synced 2024-09-19 03:37:10 -04:00
(nsxiv): add other info scripts
This commit is contained in:
parent
fb32a6aa63
commit
5c4df90114
13
.config/nsxiv/exec/image-info
Executable file
13
.config/nsxiv/exec/image-info
Executable file
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh
|
||||
|
||||
exec 2>/dev/null
|
||||
|
||||
file_name="${4##*/}"
|
||||
while IFS="$(printf '\t')" read -r size _; do
|
||||
file_size="$size"
|
||||
done <<EOF
|
||||
$(du -Hh "$4")
|
||||
EOF
|
||||
geometry="$2x$3"
|
||||
|
||||
printf '%s | %s | %s' "$file_name" "$file_size" "$geometry"
|
12
.config/nsxiv/exec/thumb-info
Executable file
12
.config/nsxiv/exec/thumb-info
Executable file
|
@ -0,0 +1,12 @@
|
|||
#!/bin/sh
|
||||
|
||||
exec 2>/dev/null
|
||||
|
||||
file_name="${4##*/}"
|
||||
while IFS="$(printf '\t')" read -r size _; do
|
||||
file_size="$size"
|
||||
done <<EOF
|
||||
$(du -Hh "$4")
|
||||
EOF
|
||||
|
||||
printf '%s | %s' "$file_name" "$file_size"
|
10
.config/nsxiv/exec/win-title
Executable file
10
.config/nsxiv/exec/win-title
Executable file
|
@ -0,0 +1,10 @@
|
|||
#!/bin/sh
|
||||
|
||||
TITLE_BASE="nsxiv"
|
||||
|
||||
exec 2>/dev/null
|
||||
|
||||
filename="${1##*/}"
|
||||
file_count="$2/$3"
|
||||
|
||||
printf '%s' "$TITLE_BASE - $filename | $file_count"
|
Loading…
Reference in a new issue