To address the original question, it's arguably the other way around.
I don't know how Network Rail works out electricity costs to its customers, but Network Rail, as a customer, will have a bill for traction electricity cost that includes Climate Change Levy, and various schemes such as the Feed in Tariff with Contract for Difference that have been developed to decarbonise electricity generation. All rail operators are therefore be indirectly funding these costs.
Much of this capacity has come - either directly or indirectly - through govt-supported investments
This isn't quite right - Government hasn't funded much but has claimed a lot of credit for organising the market to support investment.
Renewables, nuclear (RO, FiT, CfD) and maintaining backup (Capacity Market), are funded by retail electricity suppliers who pass them onto customers' electricity bills (you, me and Network Rail to name 3). As an aside, this makes electricity comparatively expensive compared to gas. This didn't matter when electricity was relatively dirty and gas was clean, but now electricity is clean and fossil gas is dirty, so the approach we have is now actually against the intent of the policy. However shifting these costs to fossil fuels would cause other bills to rise so is not a nettle any politicians are currently willing to grasp.
Exempting railway traction electricity from Climate Change Levy (unless it's already exempt?) would be a small but presumably helpful nudge towards using electric traction, which is surely the best possible thing to achieve from the perspective of climate change (as well as air quality and reducing traffic).
Electric trucks are only ever going to cover local deliveries of stuff which would never have been carried on rail anyway.
So Electric trucks will still be impractical for anything but trunking, which isn't carried on rail anyway
The first credible electric car for mainstream use was the Nissan Leaf, which was launched in 2010, and back then a lot of people said electric cars would only ever be useful for short trips around town.
The electric HGV industry is around the same stage of development, the first decent products have arrived, or are about to.
So the companies that are both selling and starting to use them are identifying and starting to deploy based on what they
can do, i.e. local deliveries and trunking.
Range improvements, cost reductions and a bit of regulatory change can all be expected to follow over the next 10 years or so
This means electric HGVs will start to have lower total cost of ownership.
Assuming the infrastructure appears (hoping we don't fall behind with HGV charging as we have with cars), and diesel will gradually get squeezed out.
This is happening with electric cars now.