Portugal maintained neutrality at the start of the Seven Years War. However, the action of the British fleet in its territorial waters provoked the hostility of France and Spain and in 1762 Spanish troops invaded the country.
The Spanish and French considered the Portuguese Army completely unprepared. They would perhaps not have been completely wrong if the marshal of the British Army, general of the Electorate of Braunschweig-Lüneburg and count and governor of the small German state of Schauburg-Lippe-Bückeburg William had not been invited to Portugal.
William had distinguished himself on the West German front during the early stages of the Seven Years' War and was particularly distinguished at the Battle of Minden. He was considered a master of defensive tactics. On the eve of the first Spanish invasion of the country, the Portuguese infantry consisted of 20 regiments (SP). On April 20, 1762, three more SPs were formed and then three more from the division of the SPs of Porto, Chávez and Braganza.
So in total there were 26 SPs with a theoretical line-up strength of approximately 40,000 men. In June of the same year, another regiment of the two battalions was formed with Swiss mercenaries, raising the theoretical strength of the infantry to 41,620 men.
In reality the strength of the infantry regiments was considerably less. In order to supplement their strength, there was a massive enlistment of men completely untrained with all that this entailed for their fighting value. By August 1762, von Lippe had managed to make ready for battle only 18 battalions and four cavalry regiments with a total strength of 5,582 men.
Under these circumstances, von Lippe adopted the British organizational model by creating single-battalion regiments. Before the reorganization each SP had two battalions each with 14 companies each with a strength of 55 men. The theoretical strength of each SP reached 1,540 men. He also had a small staff. The Swiss SP had a strength of 1,600 men.
In fact the 18 battalions that von Lippe managed to muster in August 1762 had a strength of only 250 men each. Each company of musketeers was commanded by a captain. It also had a lieutenant, an ensign (the equivalent of a second lieutenant), two sergeants, four corporals, two drummers and 44 privates. The battalion's grenadier company had exactly the same composition, but also had a flautist.
The men wore blue uniforms, black tricot hats, a musket, a bayonet and a short, single-edged sword. They wore high black boots and black shoes. The cartridge case was carried on a white leather harness hanging from the left shoulder. Sword and bayonet were carried by a white leather belt suspended from the waist. Each regiment carried characteristic colors on the cuffs and collars of the shirts.
The infantry were trained to fight based on the Franco-Spanish style of battle. Thanks to von Lippe this changed and infantrymen were trained in the Prussian-British system. The Spanish, initially alone and then together with the French, made three invasions of Portugal between April and December 1762.
In the first invasion a Spanish army of 22,000 men under the Marquis de Sarria invaded northeastern Portugal. At first the Spaniards advanced without a problem, taking the fortress of Miranda after a siege and without fighting many cities marching towards Oporto.
However, the Spanish soon found themselves confronted by the inhabitants and the small forces that managed to be sent. Unable to counter the Spanish forces head on, the Portuguese cut their lines of communication and decimated them. At least 8,000 Spaniards were killed and those who survived fled in disorder.
Meanwhile, a British expeditionary force of 7,000 men arrived in Portugal. With these and 8,000 selected Portuguese soldiers, von Lippe faced 30,000 Spaniards under the Comte d'Aranda and 12,000 French under the Prince de Beauvaux who, with united forces, made a new invasion of central Portugal.
Again the Bourbon armies started the campaign brilliantly, but were soon pinned down before von Lippe's defensive line at the Tagus River. When the Spanish and French attacked von Lippe retreated to stronger positions using scorched earth tactics and sending guerrillas to cut off his opponents' lines of communication. At the same time a rumor spread that a body of 20,000 British had landed in the country and was marching against the Bourbons.
The Spanish and French turned towards the new, supposed threat, and von Lippe took the opportunity, leaving his defensive positions, to attack them in reverse and crush them. Bourbon losses were appalling. Only the captives exceeded 12,000 thousand.
A third, smaller-scale invasion met the same fate. Von Lippe remained in Portugal almost until his death in 1777, reorganizing the Portuguese Army from the ground up.