The Wales striker became a father for the first time on Monday - and he celebrated in style with the only goal of the game against Posh on Saturday.
Earnshaw was on hand to fire home his 10th goal in as many games at the City Ground as Forest added to rock-bottom Peterborough's misery.
The visitors' preparations for the game were hardly ideal with the players having to make their own way to Nottingham after their team coach was delayed in traffic on its way to Peterborough.
Several Posh players arrived less than an hour before kick-off and things got worse for them when Earnshaw converted Paul Anderson's cross after just 13 minutes.
He admitted: "It has been an amazing week for me and to score the winner so soon after my son Silva's arrival is just perfect."
Third-placed Forest remain eight points behind West Brom in the race for automatic promotion and Earnshaw added: "It's important that we continue to try to apply pressure to West Brom.
"We know that eight points is a lot to make up with just eight games left but who you never know what could happen.
"The biggest thing for us was to get a win and then look to beat Crystal Palace on Tuesday."
Forest's assistant manager David Kelly, who faced the press instead of Billy Davies, added: "We've been brilliant at the City Ground all season but we knew it would be difficult against a team who are playing for their pride.
"We produced a brilliant move for the goal and I think we deserved it, even though the game was a lot more open than we would have liked."
Earnshaw was denied a second goal by Peterborough goalkeeper Joe Lewis' superb 17th minute save, while midfielder Chris Cohen struck an upright late in the game as Forest looked to wrap up the points.
Peterborough had opportunities to level. Tommy Rowe was denied by Lee Camp in the first half after being sent clear by Sergio Torres, while the Forest goalkeeper made a stunning save after the break from Gabriel Zakuani's header.
Posh boss Jim Gannon said: "I was just very pleased with the way the lads went about their job and in the second half I thought we looked the better football team.
"Since I came to the club I have asked the players to be competitive and I've just tried to get the best out of them and show what they are made of. It's been all about credibility and pride."
They will be hoping for a less troubled journey when they travel to Scunthorpe on Tuesday.
Gannon added: "It was just one of those things. We were supposed to come by coach but it was coming from Colchester and had been caught up in traffic because of accident.
"We made a decision for the players to travel in their cars and it wasn't a problem. Everyone got here and although it added to the interesting chapter of incidents we have had of late, it did not cause us any difficulties."
Source: Team Talk