fixed gatekeeper scripts in bash. Load function working in bash with path caching.