Gee 1314 rebased

rebased version of #1314

there were some rebase problems, and I want to see TravisCI before merging,
and have a record in case there is a mistake