How to use the saspy.sascfg.__file__.replace function in saspy

To help you get started, we’ve selected a few saspy examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github sassoftware / saspy / saspy / View on Github external
def main(cfgfile: str = None, SASHome: str = None, java: str = None):

    if != 'nt':
       print('This function will only run on Windows and create a saspy config file for an IOM Local connection')
    saspydir = ac.__file__.replace('', '')
    if not cfgfile:
       cfgfile = saspydir+''

    # if the file already exists, don't replace it.
    if os.path.exists(cfgfile):
        print("CFGFILE ALREADY EXISTS: " + cfgfile)

    # handles users who could have different versions
    if not SASHome:
       SASHome = "C:\\Program Files\\SASHome"

    if not java:
       java = 'java'