The Gurkhas had sought an injunction forcing the government to take action
Changes to rules governing the right of Gurkhas to settle in Britain will be announced within the next month, the High Court has been told.
Edward Fitzgerald QC, representing the former soldiers, said the home secretary and lawyers for the Gurkhas had agreed "on almost everything".
The Gurkhas have returned to the High Court to try to make the government act on a ruling made last September.
The court said instructions given to immigration officials were unlawful.
Mr Fitzgerald told Mr Justice Blake sitting at the High Court that Home Secretary Jacqui Smith had agreed to announce the new policy within the next month, but that she wished to tell Parliament first.
She would make a statement by 24 April and reconsider the five leading Gurkha test cases under the new policy before 7 May, he said.
Hundreds of other outstanding cases would be considered by 11 June, he added.
'Over the horizon'
The Home Office had originally said it would review all cases by the end of 2008 but asked for an extra three months to publish a new policy for more than 1,300 Gurkhas.
The High Court has heard how many former servicemen died waiting for the case to be resolved.
The most recent case was Rifleman Prem Bahadur Pun, who died on 15 March.
Mr Justice Blake told the court any appeals would "have to be over the horizon, rather than in the far distance".
After the hearing, solicitor David Enright told those Gurkhas outside court: "The government has delayed month upon sorry month, allowing your fathers to die while their sons served in Afghanistan and Iraq.
"The government has had to be shamed, kicking and screaming, back to court again and again to achieve something which any British man or woman would have given freely."
'Stain on UK'
Prominent supporter actress Joanna Lumley - whose father served with the Gurkhas - said the High Court ruling last hear had given the UK a "chance to right a great wrong".
"The way that successive governments have treated Gurkhas who retired before 1997 is truly offensive and a stain on our national character.
"These are men who have served in the British army, sometimes for 20 years and more."
Liberal Democrat leader Nick Clegg said anyone prepared to die for Britain should be allowed to live there.
"Ministers have dragged their heels and denied justice to these Gurkhas for too long, and are only now agreeing a new policy because the courts have forced them," he said.
"The deliberate delay in making this decision is a gross insult to the honour of these veterans."
A Home Office spokesman said its policy had always been clear that where there was a "compelling case" Gurkha soldiers and their families should be considered for settlement.
"Since 2004, over 6000 former Gurkhas and family members have been granted settlement in the UK under immigration rules," he continued.
"We are determined to get the guidance right to ensure that it is fair to all Gurkhas. This has involved consultation across government."
Gurkhas have been part of the British Army for almost 200 years and are hand picked from a fiercely-contested recruitment contest in Nepal to win the right to join.
They have seen combat all over the world, with 200,000 fighting in the two world wars.