diff options
| author | kaotisk <kaotisk@arching-kaos.org> | 2025-10-05 22:24:48 +0300 |
|---|---|---|
| committer | kaotisk <kaotisk@arching-kaos.org> | 2025-10-05 22:24:48 +0300 |
| commit | aec105078d8a1b64ca75bc3b7cb20c1d2dbbd59d (patch) | |
| tree | 5ef396f8b27e36890877424b89e657351ae2a95f /lib/_ak_fs | |
| parent | 2a3c61fbf515ce1ee5cb98b0c84c11b4af58ec8a (diff) | |
| download | arching-kaos-tools-aec105078d8a1b64ca75bc3b7cb20c1d2dbbd59d.tar.gz arching-kaos-tools-aec105078d8a1b64ca75bc3b7cb20c1d2dbbd59d.tar.bz2 arching-kaos-tools-aec105078d8a1b64ca75bc3b7cb20c1d2dbbd59d.zip | |
[ak-fs] --llist flag: Long-like list feature. Prints mod date instead of root hash
Diffstat (limited to 'lib/_ak_fs')
| -rwxr-xr-x | lib/_ak_fs | 17 |
1 files changed, 17 insertions, 0 deletions
@@ -354,6 +354,23 @@ function _ak_fs_list(){ fi } +function _ak_fs_long_list(){ + if [ -d "${AK_MAPSDIR}" ] + then + find $AK_MAPSDIR -type f | while read fina + do + stats="$(stat --format=%y ${fina}|tr -d '\n'|tr ' ' '_')" + date_stats="$(echo ${stats}|cut -d '_' -f 1)" + time_stats="$(echo ${stats}|cut -d '_' -f 2|cut -d '.' -f 1)" + cat $fina | tr '\n' ' ' | awk '{ print "'$(basename ${fina})' " "'$date_stats'" " " "'$time_stats'" " "$2 }' + done + else + _ak_log_debug "Making ${AK_MAPSDIR} directory" + mkdir -p ${AK_MAPSDIR} + _ak_log_debug "Empty directory" + fi +} + function _ak_fs_from_map_get_original_hash(){ if [ ! -z "$1" ] && [ -n "$1" ] then |
