Added 'Misc./script_help_for_xolatile.sh'
This commit is contained in:
parent
4fc323c790
commit
916594e20b
12
Misc./script_help_for_xolatile.sh
Executable file
12
Misc./script_help_for_xolatile.sh
Executable file
@ -0,0 +1,12 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# NOTE: technically a find command is better,
|
||||||
|
# but this is much cleaner if you dont have thousands of files
|
||||||
|
# and or spaces in their names
|
||||||
|
shopt -s globstar
|
||||||
|
for i in **/*; do
|
||||||
|
DIM=$(identify $i | cut -d ' ' -f 3)
|
||||||
|
H=$(echo $DIM | cut -d x -f 1)
|
||||||
|
W=$(echo $DIM | cut -d x -f 2)
|
||||||
|
AREA=$(expr $H '*' $W)
|
||||||
|
echo "$i: $DIM $AREA"
|
||||||
|
done
|
Loading…
x
Reference in New Issue
Block a user