Aribranch

intellij version with some minor fiddles