D&C 88:22 "For he who is not able to abide the law of a celestial kingdom cannot abide a celestial glory."
Was there ever a more daunting scripture? Knowing that "the natural man is an enemy to God", how can any of us stand a chance? Fortunately, we have a fighting chance thanks to the Gospel of Jesus Christ. We all remember the problematic beginning of Mosiah 3:19 (natural man being an enemy to God) but sometimes we forget the solution that is also provided. "Unless he yields to the enticings of the Holy Spirit." President Lorenzo Snow expounded on this point:
"It would be simply foolish indeed to expect the Latter-day Saints in these days to comply with the celestial law, with the law that proceeds from God, and with his designs to elevate the people into his presence, except they were sustained by a supernatural [heavenly] power. The gospel promises the gift of the Holy Ghost."
What a relief! We cannot abide a celestial glory without abiding a celestial law, but we can't abide a celestial law without heavenly power. How grateful we must be for the gift of the Holy Ghost. Eternal life is the greatest of the gifts of God, but we would not be able to abide eternal life if it wasn't for the gift of the Holy Ghost.
That being said, we still must live righteously to avoid offending the Spirit. So in that sense, it is a cyclic progressive process, spiraling upward. We receive the Gift of the Holy Ghost so that we can live better, and we live the commandments so that we can keep the Spirit, and we need the Spirit to be able to abide the celestial law. I love how Boyd K Packer puts it, "No wonder that the Word of Wisdom was revealed to us, for how could the drunkard or the addict feel such a voice?" (speaking of the Holy Ghost).
This really helps me see the purpose of the commandments and their connection with the Holy Ghost. Remember, no commandments are temporal, they are all spiritual. But how can that be so? Doesn't the Word of Wisdom have to do with substances? Tithing with money? The Sabbath Day with activities? Law of Chastity with moral boundaries? They are all spiritual because they are all intended to help us enjoy the promptings of the Spirit which are necessary for us to receive the revelation required for our salvation. (Joseph Smith- "Salvation cannot come without revelation.") As President Snow said, "there is a certain blessing connected only with obedience to the gospel, that is the gift of the Holy Ghost. We need assistance. Then we will always be able to do right." In other words, the commandments are given so we can have the Spirit to help us abide a celestial glory. Sadly, sometimes we think the commandments are restrictive and we go through life not enjoying the company of the Holy Ghost. This is "simply foolish indeed."