From a982aab40a2f47f66fb90124ad4e51c48b72782b Mon Sep 17 00:00:00 2001 From: Knut Ahlers Date: Thu, 14 Dec 2017 15:38:11 +0100 Subject: [PATCH] Add missing script --- bin/path-dedup.py | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100755 bin/path-dedup.py diff --git a/bin/path-dedup.py b/bin/path-dedup.py new file mode 100755 index 0000000..7462fde --- /dev/null +++ b/bin/path-dedup.py @@ -0,0 +1,10 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +from __future__ import print_function + +import os + +out = [] +[out.append(i) for i in os.environ["PATH"].split(":") if not out.count(i)] +print(":".join(out))