Dedupe completions, remove bashisms.