Replace bash specific command with common POSIX command