tags scanning progress
This commit is contained in:
parent
0ad3fbac61
commit
bed67cc8f6
17
atom
17
atom
@ -586,6 +586,7 @@ getFiles() {
|
||||
)
|
||||
echo 'COMMIT;' >&3
|
||||
echo -e "\r$count files found, ${new:=0} new or changed."
|
||||
unset count
|
||||
}
|
||||
|
||||
updateMimes() {
|
||||
@ -760,6 +761,19 @@ updateMimes
|
||||
removeObsoleteFiles
|
||||
|
||||
# get files
|
||||
echo '
|
||||
SELECT COUNT(*)
|
||||
FROM source_files,
|
||||
destinations,
|
||||
destination_files,
|
||||
mime_type_actions
|
||||
WHERE destination_files.last_change < source_files.last_change
|
||||
AND destinations.id = destination_files.destination_id
|
||||
AND mime_type_actions.destination_id = destinations.id
|
||||
AND mime_type_actions.id = source_files.mime_type
|
||||
AND source_files.id = destination_files.source_file_id
|
||||
AND mime_type_actions.action = 1;' >&3
|
||||
read -u4 filecount
|
||||
echo '
|
||||
SELECT
|
||||
destinations.name,
|
||||
@ -781,16 +795,19 @@ while read -u4 line
|
||||
do
|
||||
if [[ $line = AtOM:NoMoreFiles ]]
|
||||
then
|
||||
echo -e "\r$count files to create or update."
|
||||
break
|
||||
else
|
||||
destination=${line%%|*}
|
||||
rest=${line#*|}
|
||||
mimetype=${rest%%|*}
|
||||
filename=${rest#*|}
|
||||
echo -en "\rTags: $((++count*100/filecount))%"
|
||||
getTags
|
||||
#createTask
|
||||
fi
|
||||
done
|
||||
unset count
|
||||
closeDatabase
|
||||
|
||||
# vim:set ts=8 sw=8:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user