The only way to edit the same file on iPhone and (Linux) laptop that I can find is Google Drive. However, on laptop Google docs don't have code syntax colouring / highlighting. Also with Google docs iPhone you can't make a Home screen link that takes you straight to a file, so it's slightly inconvenient.
I was wondering whether there's an even better solution for this, such as a text editor (internet or notepad app) which has an iPhone app and can colour code?
EDIT1: I'm not rich so am looking for a free or one-time payment / cheap option
EDIT2: https://workingcopyapp.com/ seems to solve my problems since I could then just use my text editor