Add check for existing brew and npm before running update command