Browse code

after shellcheck

dewomser authored on31/10/2018 23:30:01
Showing1 changed files

... ...
@@ -12,9 +12,10 @@
12 12
 ## Save all your Youtube playlists in favdir ##
13 13
 favdir="bestof"
14 14
 ## Firefox running ?
15
-ffon=0; ps -ef|grep firefox|grep -v grep && ffon=1
15
+# ffon=0; ps -ef|grep firefox|grep -v grep && ffon=1
16
+ffon=0; pgrep firefox && ffon=1
16 17
 ## Download folder ##
17
-dl_folder="/home/foo/Downloads/youtube-dl/"
18
+dl_folder=~/Downloads/youtube-dl
18 19
 ## Date= yesterday ##
19 20
 datum=$(date -d "1 day ago" '+%Y%m%d')
20 21
 ## Max. videos / datum to each playlist ##
... ...
@@ -31,7 +32,7 @@ sqltdata=places.sqlite
31 32
 
32 33
 cd ~/.mozilla/firefox/*default* || exit
33 34
 
34
-if (( ffon == 1 && loadfrom == database ))
35
+if [ $ffon == 1 ] && [ $loadfrom == database ]
35 36
 then
36 37
 cp $sqltdata places2.sqlite
37 38
 sqltdata=places2.sqlite