support '-' as a path using stdin and stdout