Browse code

array noch mal

dewomser authored on30/12/2019 21:33:43
Showing1 changed files

... ...
@@ -54,7 +54,8 @@ then
54 54
 else
55 55
  ## This line puts FF bookmarks from sqlite3 to an array ##
56 56
 
57
- dbarray=( $(sqlite3 -list $sqltdata 'select url from moz_places where id in (select fk from moz_bookmarks where parent in ( select "id" from moz_bookmarks where title == "'$favdir'"))'; ))
57
+# dbarray=( $(sqlite3 -list $sqltdata 'select url from moz_places where id in (select fk from moz_bookmarks where parent in ( select "id" from moz_bookmarks where title == "'$favdir'"))'; ))
58
+readarray -t dbarray < "$(sqlite3 -list $sqltdata 'select url from moz_places where id in (select fk from moz_bookmarks where parent in ( select "id" from moz_bookmarks where title == "'$favdir'"))'; )"
58 59
 fi
59 60
 cd  $dl_folder || exit
60 61
 
... ...
@@ -72,16 +73,16 @@ done
72 73
 ## optional after all Downloads ##
73 74
 
74 75
 ## Feedback if this script is started from crontab
75
-export HOME=/home/karl
76
-export DISPLAY=:0.0
76
+#export HOME=/home/karl
77
+#export DISPLAY=:0.0
77 78
 ## Open folder in dolphin KDE
78 79
 #dolphin $dl_folder
79 80
 ## Notifier KDE
80 81
 #f=$(find $dl_folder -mtime 0,2 -type f -regex '.*\.\(mkv\|mp4\|wmv\|flv\|webm\|mov\)') && notify-send "Neue Videos": "$f" --icon=video-x-generic
81 82
 
82 83
  ## Notifier KDE in nice
83
-f=$(find $dl_folder -mtime 0 -type f -regex '.*\.\(mkv\|mp4\|wmv\|flv\|webm\|mov\)')
84
-folder1=$(echo $dl_folder|sed "s/\//\\\\\//g")
85
-f1=$(echo $f|sed "s/$folder1/\n /g")
86
-notify-send "Neue Videos": "$f1" --icon=video-x-generic
84
+#f=$(find $dl_folder -mtime 0 -type f -regex '.*\.\(mkv\|mp4\|wmv\|flv\|webm\|mov\)')
85
+#folder1=$(echo $dl_folder|sed "s/\//\\\\\//g")
86
+#f1=$(echo $f|sed "s/$folder1/\n /g")
87
+#notify-send "Neue Videos": "$f1" --icon=video-x-generic
87 88