moved into https://github.com/dmlond/split_raw