Add the current_patch column to settings table
Add patch command

Fixes #566