]> jfr.im git - irc/kvirc/kvirc-themes.git/blob - get-package-info.kvs
import all themes from ftp://ftp.kvirc.de/pub/kvirc/themes/
[irc/kvirc/kvirc-themes.git] / get-package-info.kvs
1 # dump informations about a single kva package to the system console
2 # Execute with:
3 #
4 # kvirc -e "parse get-package-info.kvs /full/path/to/*.kv[a|t]"
5
6 %inf = $package.info($1)
7
8 debug -s ""
9
10 if(%inf{error} != "")
11 {
12 debug -s "Could not read package $1"
13 debug -s %inf{error}
14 return;
15 }
16
17 debug -s "File: "%inf{info}{path}
18 debug -s "Size: "%inf{info}{size}
19
20 debug -s "Metadata:"
21
22 %mt = %inf{metadata}
23 %keys = $sort($keys(%mt))
24
25 foreach(%k,%keys)
26 debug -s "* "%k": "%mt{%k}
27
28 debug -s "Files:"
29
30 foreach(%k,%inf{files})
31 debug -s "* "%k
32
33 debug -s ""
34