As long as the relativized element in your subject is a form of do, you can have a plain infinitival clause (one headed by the base form of the verb and not introduced by subordinator to) following a a form of be.
[The thing I didn't want to do ____] [was] [start early].
Relative clause: I didn't want to do ___
This is very similar to a fused relative, which may sound better to your ears. All, the least are also very common.
What I didn't want to do was start early.
All I could do was throw my hands up.
The least I could do was donate some money.
In the example given from Diary of a Wimpy Kid, the realtive clause would be
[the first thing I did when I got outside] was [sneak off to the basketball court]
I did ___ when I got outside
There has to be a relative clause with the complement of do as the relativized element for this to work.
*The first thing was sneak off to the basketball court.
The first thing was to sneak off to the basketball court.
Constructions of this sort are used across the spectrum:
The first thing she did was take the balsamic vinegar and separate
it out from the rest. (FIC: North American Review; Fall2018, Vol.
303, Issue 4; Shrubs; GILBERT-COLLINS, SUSAN M.)
It replaced the Burlington station on the Montreal cable system. The
first thing it did was get a post office box just over the border
and start saying a few words in French during the on-air fund-raising
campaigns. (NEWS: Christian Science Monitor; When Canadians Talk, PBS
Stations Listen; 1990)
the one thing that he wanted to do was introduce and take through
the House a Bill that would bring about a reduction in road traffic
(HANSARD Corpus - British Parliament;
road_traffic_reduction_national_targets_bill_hansard_24_april_1998_ ;
Mr_Patrick_Nicholls)
More examples are easy to produce by searching for a form of 'be' followed by the base form of a common verb, like get, be, give etc.