Sefer Chasidim Siman 855
Can copy this into an AI, or connect the whole library to your assistant. For deeper learning, you can directly use the original seforim, sites, and apps.
אשה הרה וכבר הגיע חודש התשיעי להריונה בערב שבת עם חשיכה יטמין מים חמין כדי שאם תלד בליל שבת או בשבת הרי המים חמין מזומנין ולא יחללו שבת:
Medieval Jewish mysticism, translated by Sholom Alchanan Singer. Northbrook, Ill. Whitehall Co., 1971
If there's a pregnant woman who is in the ninth month of pregnancy it is proper to insulate hot water for her on shabbos eve before it gets dark, hence if she gives birth on shabbos night or day there will be hot water ready for her and no shabbos desecration will be necessary.