If you learn the timing, you can shoot bullets at the Shy Guys before they even appear and try to kill most or all of them. What do you mean you beat him once? Do you mean you got past the first stage and died on the second?
Some suggestions:
Watch lots of Mecha Birdo videos and try copying their strategies.
Practice shooting faster. If you can shoot fast, you shouldn't have any problems getting past the first stage before any Shy Guys appear.
When you get to the second stage, well, you're kind of screwed if you find it difficult getting past the first stage. But never give up! I've been stuck on one boss in a fangame for almost a month and have died about 2000 times on her. But I haven't given up and I'm getting really close to beating her. The point is, you'll be amazed at what you can do if you don't stop trying.