added grep check of current file to prevent duplicates