A Deeper Lesson from Rashi
The teaching of Rabbi Tanchumah – meaning consolation, quoted by Rashi, is not only a consolation for the Egyptian exile. Rather, it comforts us in all of our exiles, including our prolonged present exile, for each exile is called Egypt. The Midrash teaches us that exile is comparable to our wandering in the wilderness of the nations. The purpose of our wandering was to build a sanctuary in the wilderness. We were to take a barren wasteland, void of holiness, a place of "snakes, vipers, scorpions, and thirst ..." and build a sanctuary there. We are to make a Mishkan and a Sanctuary to Hashem, a dwelling place for Him in the lowest of all places. After this work, we can fulfill the commandment, "They shall make a sanctuary for me, and I will dwell among them," in the simplest sense. We will actually build the third Bais Hamikdosh, which will reveal the original Mishkan built by Moshe.
We can accomplish this and break through the darkness of exile because Yaakov brought the cedars from Israel. The significance of Yaakov bringing the trees from Egypt is that cedars (from which the Mishkan was built) allude to Tzaddikim. Notably, because of their grandeur, they allude to the leaders of the Jewish Nation. This is the connection to Yaakov. The Hebrew word for the leader of the Jews is Nasi – נשיא, which is an acronym for "Nitzuso Shel Yaakov Avienu," a spark of Yaakov, our forefather. This is as the Alter Rebbe writes in Tanya. The soul of Yaakov "included those of all Jews from all times." This is why Rashi explains that "Yaakov, our forefather, brought 'cedars' to Egypt." All of our leaders, who are sparks of Yaakov, stem from Yaakov and are above exile. However, to implant within us the ability to overcome the darkness of exile, they had to be "planted" in Egypt, i.e., during exile.
This is our consolation. Even while we are in the wilderness of the nations, we can see the "cedars which Yaakov planted," our Tzaddikim, leaders of each generation. They inspire us to overpower the darkness of exile rather than being influenced by it. Then, we can finally merit the only possible comfort for this lengthy exile: the complete and true redemption through our righteous Moshiach in the simplest sense of the word.
(Adapted from a talk given on Shabbos Parshas Terumah 5747)