コード例 #1
0
ファイル: __init__.py プロジェクト: resamsel/dbmanagr
def init():
    module = module_installed(*DRIVERS.keys())
    if not module:
        return

    __drivers__.append(module)
    init_sqlite(
        DRIVERS[module],
        getenv(
            'DBEXPLORER_CFG',
            expanduser('~/.dbexplorer/dbexplorer.cfg')),
        getenv(
            'SQLITEPASS_CFG',
            expanduser('~/.sqlitepass')),
        getenv(
            'NAVICAT_CFG',
            expanduser('~/Library/Application Support/PremiumSoft CyberTech'
                       '/preference.plist')),
        getenv(
            'NAVICAT_CFG',
            expanduser('~/Library/Containers/com.prect.'
                       'NavicatEssentialsForSQLite/Data/Library/'
                       'Application Support/PremiumSoft CyberTech/'
                       'preference.plist'))
    )

    Options.parser['sqlite'] = SQLiteOptionsParser()
コード例 #2
0
def init():
    module = module_installed(*DRIVERS.keys())
    if not module:
        return

    __drivers__.append(module)
    init_postgresql(
        DRIVERS[module],
        getenv('DBEXPLORER_CFG', expanduser('~/.dbexplorer/dbexplorer.cfg')),
        getenv('PGPASS_CFG', expanduser('~/.pgpass')))

    Options.parser['postgresql'] = PostgreSQLOptionsParser()
コード例 #3
0
ファイル: __init__.py プロジェクト: resamsel/dbmanagr
def init():
    module = module_installed(*DRIVERS.keys())
    if not module:
        return

    __drivers__.append(module)
    init_mysql(
        DRIVERS[module],
        getenv(
            'DBEXPLORER_CFG',
            expanduser('~/.dbexplorer/dbexplorer.cfg')),
        getenv(
            'PGPASS_CFG',
            expanduser('~/.mypass'))
    )

    Options.parser['mysql'] = MySQLOptionsParser()
コード例 #4
0
ファイル: __init__.py プロジェクト: gschaden/dbmanagr
def init():
    module = module_installed(*DRIVERS.keys())
    if not module:
        return

    __drivers__.append(module)
    init_sqlite(
        DRIVERS[module],
        getenv('DBEXPLORER_CFG', expanduser('~/.dbexplorer/dbexplorer.cfg')),
        getenv('SQLITEPASS_CFG', expanduser('~/.sqlitepass')),
        getenv(
            'NAVICAT_CFG',
            expanduser('~/Library/Application Support/PremiumSoft CyberTech'
                       '/preference.plist')),
        getenv(
            'NAVICAT_CFG',
            expanduser('~/Library/Containers/com.prect.'
                       'NavicatEssentialsForSQLite/Data/Library/'
                       'Application Support/PremiumSoft CyberTech/'
                       'preference.plist')))

    Options.parser['sqlite'] = SQLiteOptionsParser()
コード例 #5
0
    def test_module_installed(self):
        """Tests the utils.module_installed function"""

        self.assertEqual(
            None,
            utils.module_installed('foobar'))