I have 3 files and I want watch the changes of these files with 'watch' command. But these 3 files have a lot of row and I just want see the last 3 rows with 'tail'. There is no problem at here. I can use this command for this:
watch 'tail -3 file1; tail-3 file2; tail -3 file3'
This command give me an output like this:
Every 2.0s: tail -3 file1; tail -3 file2; tail -3 file3
file1 row9
file1 row10
file1 row11
file2 row9
file2 row10
file2 row11
file3 row9
file3 row10
file3 row11
I want to separate these rows with any separator and see the result as like this:
Every 2.0s: tail -3 file1; tail -3 file2; tail -3 file3
file1 row9
file1 row10
file1 row11
-----
file2 row9
file2 row10
file2 row11
-----
file3 row9
file3 row10
file3 row11
The separator doesn't matter. I just want to see the results as separated.