unix - Script fails when using a variable for paths -


the following script fails. if run manually giving absolute paths instead of dir works.

#!/bin/ksh export dir="/clocal/www/logs/ca" find  $dir -name "*gz" -mtime +2 -exec ls -lrt {} \; #working line : find . -name "*gz" -mtime +2 -exec ls -lrt {} \; 

the operating system being run under aix.


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -