Arrow keys to move, Space to focus. You automatically shoot. The fight doesn't end if you get all the health down though, so try to get that HP number as low as possible!
Credit to ZUN (Also known by Team Shanghai Alice.) Update: Added a line of dialogue for getting hit 20 or more times before the boss dies. If you get the boss hp down to zero without getting hit a single time, you will be rewarded with an extra piece of dialogue at the end, and I will list your name here in the hall of lunatics below provided you send me a clip of you beating it without getting hit. oh yeah you also get an extra bit of dialogue for nohitting until -250 hp so thats cool Hall of lunatics Me (cause I had to verify it was possible)