After your marriage, you can file for a green card based on marriage to a permanent resident. Buy your ticket home as you will be waiting there until your priority date becomes current. Check the visa bulletin monthly for latest dates. If your then permanent resident spouse chooses to go to your home country to wait with you, be sure that he/she applies for and receives a reentry permit before joining you.

If your spouse becomes a citizen while you are waiting for your turn in a very long line, the petition can be ugraded to the spouse of a citizen. Be sure your spouse follows all of the rules for residency for citizenship application.