added code to replace shell script