I’ve done my rear brake hose recently. Complete pain in the @r5e. Tried several methods, one of which was the one Sandwich mentioned although I was unable to fit the grommit back in. Thats only part of it though, getting it out of the swingarm is also difficult.
I used a small piece of spoke. If you remove hose at caliper end there should be very little loss of fluid. Screw in spoke, lube it and guide it through grommit and through plate in swingarm. Once through I used a pair of needle nose pliers to grasp the piece of spoke. You then have to carefully slightly bend the spoke, as you slowly feed the hose through the swingarm some more.
Len, spot on with the gear cable, feed through inner, fish it off with hooked end of spoke (spokes are great for this), feed outer back on.