Fortissimo, IIRC all works costed and the wush list forwarded to Infra where they were categorized A-D. A was sub-divided along the lines of H&S and operationally essential. The higher command would then divide the cake much as you describe.
Category D was 'never in a month of Sundays after a blue moon'
However if the pot was large enough you might 'lose' a Category A works (change of requirement) and move that door that the new Stn Cdr didn't like
. Then there was that annual end of year surplus; spend it or lose it. The footpath across the MQ sports pitch at Lyneham for the 5th Nov bonfire springs to mind.