Heat oil in a large skillet over medium-high heat. Add onion and 1 tsp salt. Cook, stirring frequently, until onion is golden and very soft, 7-10 minutes. Stir in garlic and cook, stirring constantly until softened, about a minute, then stir in cumin, oregano, cayenne, and pepper and cook until fragrant, about a minute more.