In 1971 Idi Amin launched a military coup that overthrew the President of Uganda, Milton Obote, precipitating a deterioration of relations with the neighbouring state of Tanzania. Amin installed himself as President and ruled the country under a repressive dictatorship. In October 1978 Amin launched an invasion of Tanzania. Tanzania halted the assault, mobilised anti-Amin opposition groups, and launched a counter-offensive. The President of Tanzania, Julius Nyerere, told foreign diplomats that he did not intend to depose Amin, but only "teach him a lesson". The claim was not believed; Nyerere despised Amin, and he made statements to some of his colleagues about overthrowing him. The Tanzanian Government also felt that the northern border would not be secure unless the threat presented by Amin was eliminated. After initial advances into Ugandan territory, Major General David Msuguri was appointed commander of the Tanzania People's Defence Force (TPDF)'s 20th Division and ordered to push further into the country.