In the specific types of expressions you are citing (namely, "All you have to do is ..." and "What we did in this lecture was ..."), the verb in the predicate can include "to" or can omit "to" and still be considered perfectly natural.
All of these are fine:
All you have to do is sit and wait.
All you have to do is to sit and wait.
What we did in this lecture was create a new style for our activity.
What we did in this lecture was to create a new style for our activity.
Sentences that take this form are a type of expressions known as pseudo-cleft sentences. As Günter Rohdenburg writes in "Clarifying Structural Relationships in Cases of Increased Complexity in English" (Making Meaningful Choices in English: Dimensions, Perspectives, Methodology, and Evidence; Rainer Schulze, editor; Gunter Narr Verlag, 1998; page 194) :
English boasts a wealth of contructions involving various function words which are omissible in certain contexts....
Apart from certain verbal complements, the optional use of the infinitive marker is characteristic of pseudo-cleft constructions as in ...
All you can do is (to) wait for the results.
What she did was (to) wait for the results.
Rohdenburg goes on to cite evidence indicating that ommitting the "to" in these constructions is becoming more common than in past centuries, especially in more informal usage and in American usage compared to, for example, British usage--all of which conforms with my own impressions. Americans more commonly omit the "to" than include it nowadays, especially in more informal usage, I think.
Please note that using a form of the verb with an -ing suffix in the predicate (for example, All you have to do is sitting and waiting, or What we did in this lecture was creating a new style for our activity) is ungrammatical and would never occur in English--unless the "do" verb before the copula (the copula being the to-be verb in the middle of the sentence) is already in an -ing form:
All you are doing is sitting and waiting.
What I am doing in this lecture is creating a new style for our activity.
Note also that if the verb in the predicate is itself a form of "to be," then inclusion of "to" is mandatory:
All (that) we wanted was to be free. (correct)
All (that) we wanted was be free. (ungrammatical)
What we want is to be free. (correct)
What we want is be free. (ungrammatical)