This script works perfectly in raspbian and in ubuntu, but not in lakka:
#!/bin/bash
IFS=';'
cd /storage/.attract/romlists
rm Favorites.txt
touch Favorites.txt
chmod 777 Favorites.txt
ls *.tag > tagfiles
while read filename
do
while read gamename
do
romlist=`echo ${filename} |cut -f1 -d '.'`
cat "${romlist}.txt"|grep "^${gamename};" >> Favorites.txt
done < "${filename}"
done < tagfiles
rm tagfiles
cat Favorites.txt |sort -u > tmp_favorites.txt
mv tmp_favorites.txt Favorites.txt
sleep 5
the reading of the data is correct, but the redirection >> does not do anything.
In putty ssh this comand runs:
cat "Atari2600.txt" |grep "Centipede (USA)" >> Favorites.txt
but the script does not.
Does anyone know why?