Variables don't work inside quotes
Move pluginfile to early declaration
Fix switch logic
D.R.Y.
Don't pause after starting GIMP
Try to implement external debugger