cleanup
allow to select existing bare repository
move such logic to repository manager
fix write
disable auto commit during sync