add pipe and exec func