how can i write the line that contains such character and also the previous line
Use -B1 .
Por exemplo:
$ seq 10 >file
$ grep -B1 5 file
4
5
Se você quiser incluir o nome do arquivo, adicione -H :
$ grep -HB1 5 file
file-4
file:5
Combinado com find
Supondo que você tenha o GNU find ou um moderno BSD find , seu comando completo pode ser simplificado para:
find ./ -iname '*txt' -exec grep -HB1 "ququ" {} + >holis.txt