The power company protection would be built into the sync circuit. if the DC side is open then there would be zero volts on the AC side.
And once it is on (assuming it syncs rather than catches fire), if the line power fails the inverter will keep it hot.
Even with moderately complex detection gear, a motor running on the line side (even a small one) will keep the inverter happy - especially one that was originally designed to run standalone. Detecting line failure is not necessarily simple, and not for a homebrewed project.
Also: In addition to (and largely because of) the hazard to linemen, it's ILLEGAL to backfeed the power lines with a device whose design hasn't been inspected by labs such as UL and approved for such service.
Then there's the liability issues. Does your insurance cover killing electrical workers?
I'm looking to do this on the cheap. I know there are commercial products available, but that takes all the fun out of it.
Linemen's jobs are already hazardous enough, without frying them because you wanted to save a few bucks on your hobby. Every one of them (who has been working for more than a few years) once knew somebody who was then "burned".
If you can't afford to buy one of the commercial ones, you obviously can't afford to build several of your prototypes to be tortured and set on fire, then hire Underwriter's Laboratory to test them to destruction and give you design feedback or approval.
If you were really rich and just in it for the fun, that would be the way to go. (But the really rich usually find ways, when having fun, either to not spend a lot of money on it or to make it pay off. That's why they're still rich.)
I'm sorry to rain on your parade. But you should NOT attempt to backfeed the power grid with a homebrew inverter.
If you want to homebrew, doing the rest of the system (within electrical code requirements) is just fine. But you'll need to buy any inverter you use to backfeed the grid.