I am making a simple IRC bot in bash and I want prevent its log from growing to infinity. For example it could be shortened always when reaching set number of lines. How can I do that easily? For example by cutting the file with removing first line(s)?
If possible, I would like to avoid sed/awk this time :)