updated usage of bash variables