# Copyright (C) 2007-2010 Samuel Abels.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2, as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
"""
The core module.
"""
# If available, use globally installed paramiko. Fall back to the one
# that is contained in the package's external/ directory.
try:
    import paramiko
except ImportError:
    import os
    import sys
    import warnings
    external_dir = os.path.join(os.path.dirname(__file__), 'external')
    sys.path.insert(0, external_dir)
    with warnings.catch_warnings():
        warnings.filterwarnings('ignore', category = DeprecationWarning)
        import paramiko

from version       import __version__
from Account       import Account
from Queue         import Queue
from QueueListener import QueueListener
from Host          import Host
from Logger        import Logger
from FileLogger    import FileLogger

import inspect 
__all__ = [name for name, obj in locals().items()
           if not (name.startswith('_') or inspect.ismodule(obj))]

# Copyright (C) 2007-2010 Samuel Abels.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2, as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
"""
The core module.
"""
# If available, use globally installed paramiko. Fall back to the one
# that is contained in the package's external/ directory.
try:
    import paramiko
except ImportError:
    import os
    import sys
    import warnings
    external_dir = os.path.join(os.path.dirname(__file__), 'external')
    sys.path.append(external_dir)
    with warnings.catch_warnings():
        warnings.filterwarnings('ignore', category = DeprecationWarning)
        import paramiko

from version       import __version__
from Account       import Account
from Queue         import Queue
from QueueListener import QueueListener
from Host          import Host
from Logger        import Logger
from FileLogger    import FileLogger

import inspect 
__all__ = [name for name, obj in locals().items()
           if not (name.startswith('_') or inspect.ismodule(obj))]

use sys.path.append instead of sys.path.insert in Exscript.__init__.