autoload/splicelib/settings.py @ 0013f7e01b6e

Rename to Splice, and change default prefix.
author Steve Losh <steve@stevelosh.com>
date Fri, 20 Apr 2012 15:16:48 +0100
parents autoload/threesomelib/settings.py@cefc901de8a2
children (none)
import vim


def setting(name, default=None):
    full_name = 'g:splice_' + name

    if not int(vim.eval('exists("%s")' % full_name)):
        return default
    else:
        return vim.eval(full_name)

def boolsetting(name):
    if int(setting(name, 0)):
        return True
    else:
        False