# Path: pkg/win32/Python27/Lib/site-packages/clint/utils.py
# def expand_path(path):
#     """Expands directories and globs in given path."""
# 
#     paths = []
#     path = os.path.expanduser(path)
#     path = os.path.expandvars(path)
# 
#     if os.path.isdir(path):
# 
#         for (dir, dirs, files) in os.walk(path):
#             for file in files:
#                 paths.append(os.path.join(dir, file))
#     else:
#         paths.extend(glob(path))
# 
#     return paths
# 
# def is_collection(obj):
#     """Tests if an object is a collection. Strings don't count."""
# 
#     if isinstance(obj, basestring):
#         return False
# 
#     return hasattr(obj, '__getitem__')


import os
from sys import argv
    from collections import OrderedDict
    from .packages.ordereddict import OrderedDict
from .utils import expand_path, is_collection
    def first(self, x):
        """Returns first found index of given value (or list of values)"""

        def _find( x):
            try:
                return self.all.index(str(x))
            except ValueError:
                return None

        if is_collection(x):
            for item in x:
                found = _find(item)
                if found is not None:
                    return found
            return None
        else:
            return _find(x)


    def first_with(self, x):
        """Returns first found index containing value (or list of values)"""

        def _find(x):
            try:
                for arg in self.all:
                    if x in arg:
                        return self.all.index(arg)
            except ValueError:
                return None


# Path: pkg/win32/Python27/Lib/site-packages/clint/utils.py
# def expand_path(path):
#     """Expands directories and globs in given path."""
# 
#     paths = []
#     path = os.path.expanduser(path)
#     path = os.path.expandvars(path)
# 
#     if os.path.isdir(path):
# 
#         for (dir, dirs, files) in os.walk(path):
#             for file in files:
#                 paths.append(os.path.join(dir, file))
#     else:
#         paths.extend(glob(path))
# 
#     return paths
# 
# def is_collection(obj):
#     """Tests if an object is a collection. Strings don't count."""
# 
#     if isinstance(obj, basestring):
#         return False
# 
#     return hasattr(obj, '__getitem__')


# Path: pkg/win32/Python27/Lib/site-packages/clint/arguments.py
import os
from sys import argv
    from collections import OrderedDict
    from .packages.ordereddict import OrderedDict
from .utils import expand_path, is_collection

    def first(self, x):
        """Returns first found index of given value (or list of values)"""

        def _find( x):
            try:
                return self.all.index(str(x))
            except ValueError:
                return None

        if is_collection(x):
            for item in x:
                found = _find(item)
                if found is not None:
                    return found
            return None
        else:
            return _find(x)


    def first_with(self, x):
        """Returns first found index containing value (or list of values)"""

        def _find(x):
            try:
                for arg in self.all:
                    if x in arg:
                        return self.all.index(arg)
            except ValueError:
                return None


        if is_collection(x):