France's President Emmanuel Macron has appointed a new prime minister in an effort to relaunch his government in the wake of the Covid-19 pandemic and with an eye on the next election in 2022. Jean Castex, a technocrat from the centre-right, was named as the new head of the executive just weeks after he was tapped to lead the French recovery strategy on the coronavirus lockdown. Mr Castex worked for former president Nicolas Sarkozy and was also appointed by President Macron as a ministerial delegate to the International Olympic Committee. The popular outgoing prime minister, Edouard Philippe, handed in his resignation on Friday before the government reshuffle. The Elysee presidential palace said Mr Macron had accepted the resignation of Mr Philippe and his government, which would continue to handle "day-to-day matters" until a new government is named. Mr Macron vowed to chart a new course for the remaining two years of his term after a poor performance by government allies in last week's municipal elections. France is grappling with the deepest economic depression since World War Two, a sharp downturn that will shrink the economy by about 11 per cent in 2020 and reverse hard-fought gains on unemployment. Investors will be watching to see if Finance Minister Bruno Le Maire, who has overseen reforms to liberalise the economy and spent big to keep companies like Air France and Renault afloat during the crisis, keeps his job. “The return from summer holidays will be difficult, we must get ready,” Mr Macron told regional newspapers in an interview published late on Thursday. Mr Macron hopes a cabinet reshuffle will reinvigorate his party's fortunes. Despite a bounce in Mr Macron's own personal popularity, the French government has been criticised over its handling of the Covid-19 pandemic.<br/> However, Mr Philippe has become increasingly popular and won a considerable victory in his home town of La Havre, where he ran for mayor, during local elections last month. Questions over the prime minister’s job have swirled since mid-June when Mr Macron declared he wanted to "reinvent" his presidency and voters punished the former investment banker and his party in nationwide municipal elections. The elections revealed surging support for the Green party and underlined Mr Macron's troubles with left-leaning voters. With only 21 months until the next presidential election, Mr Macron wants to reposition himself, close advisers say. It is a political gamble for Mr Macron to replace Mr Philippe, who is more popular with the public than the president, political analysts say. The outgoing prime minister has shown steadfast loyalty during waves of unrest and could emerge as a presidential rival in 2022. Keeping Mr Philippe in office could have been problematic, too. It could have suggested that Mr Macron was too weak to let go of his prime minister and that his young party lacked the depth to allow for a full-blooded cabinet overhaul.