I developed one shell script where it will sync the files using perforce,
#!/bin/bash
TERM=linux
export TERM
clear
echo ""
$PATH
echo ""
cd /u/userk/p4/p4_client/TES_DATE
echo ""
echo "Sync p4 "
p4 sync
echo "Executing for second time "
p4 -u userk -p p4net:161 -c userk:p4_client sync
this script executes well when i execute from my directory, i want this script to run every 15 min, and sync the latest files using perforce(p4) so i am using cronjob to achive this, my crontab files goes like this
I tried with space and also without space, p4 is a command so i tried giving with space , still same i am getting, the script runs fine when i execute from my home directory, but when i execute from cronjob, it shows p4 command not found or No such file or directory