Other than Taiwan/China, what other countries had revolutions where the ruling party/rulers escaped to a remote area or region and held onto power as a country/government while the rest of the country fell under revolution? I'm more concerned with governments post 18th Century. I'd rather focus on countries that had governments which continued and actually continued within the original borders at some point, so if the government fled to another location and continued there without control within the original borders I would not include them in my list. So Tibet would be excluded since the ruling government is not within the original borders of the country.
A number of Roman and Byzantine Emperors did this over the course of a thousand years. The Palaiologos Dynasty comes to mind.
The Taliban seem to be an example of that phenomenon.
EDIT: I see now that the question is limited to revolution. The Taliban fled because of a war.