Ebrahim Al-Muzani (rahimahullah) mentioned the following:
On one occasion, I entered the home of Imaam Shaafi‘ee (rahimahullah) while he was engaged in writing a kitaab. Seeing the exertion of Imaam Shaafi‘ee (rahimahullah) (and knowing that he was ill at that time), I said to him, “May Allah Ta‘ala have mercy on you! The students of Imaam Maalik (rahimahullah) and the students of Imaam Abu Hanifah (rahimahullah) have authored many kitaabs, and they have exerted themselves in the path of knowledge more than you are exerting yourself (in other words, the effort that they made is sufficient, so you do not have to exert yourself)!”
When Imaam Shaafi‘ee (rahimahullah) heard this, he responded, “O Ebrahim! Can you not see the difficulty that I am in?” (Imaam Shaafi‘ee (rahimahullah) was suffering from piles at that time.) Imaam Shaafi‘ee (rahimahullah) then said, “We will continue to write kitaabs, and they will continue to write kitaabs, and that which is carried out purely for the sake of Allah Ta‘ala will gain acceptance and remain throughout time.”
(Manaaqib-ush-Shaafi‘ee li-lBayhaqi vol. 1 pg. 177)