Exemple #1
0
# Jiaye Yu and Mark Holder, University of Kansas

if __name__ == "__main__":
    import os
    import sys
    from sate.mainsate import sate_main
    from sate import MESSENGER
    _SATE_DEBUG = os.environ.get('SATE_DEBUG')
    _DEVELOPER = _SATE_DEBUG and _SATE_DEBUG != '0'

    if not _DEVELOPER:
        _SATE_DEVELOPER = os.environ.get('SATE_DEVELOPER')
        _DEVELOPER = _SATE_DEVELOPER and _SATE_DEVELOPER != '0'
    try:
        rc, temp_dir, temp_fs = sate_main()
        if not rc:
            raise ValueError("Unknown SATe execution error")
        if (temp_dir is not None) and (os.path.exists(temp_dir)):
            MESSENGER.send_info(
                "Note that temporary files from the run have not been deleted, they can be found in:\n   '%s'\n"
                % temp_dir)
            if sys.platform.lower().startswith('darwin') and ("'"
                                                              not in temp_dir):
                MESSENGER.send_info('''
If you cannot see this directory in the Finder application, you may want to use
the 'open' command executed from a Terminal.  You can do this by launching the
/Applications/Utilities/Terminal program and then typing

open '%s'
 def _exe(self, args):
     return sate_main(args)
Exemple #3
0
# Jiaye Yu and Mark Holder, University of Kansas

if __name__ == "__main__":
    import os
    import sys
    from sate.mainsate import sate_main
    from sate import MESSENGER
    _SATE_DEBUG = os.environ.get('SATE_DEBUG')
    _DEVELOPER = _SATE_DEBUG and _SATE_DEBUG != '0'

    if not _DEVELOPER:
        _SATE_DEVELOPER = os.environ.get('SATE_DEVELOPER')
        _DEVELOPER = _SATE_DEVELOPER and _SATE_DEVELOPER != '0'
    try:
        rc, temp_dir, temp_fs = sate_main()
        if not rc:
            raise ValueError("Unknown SATe execution error")
        if (temp_dir is not None) and (os.path.exists(temp_dir)):
            MESSENGER.send_info("Note that temporary files from the run have not been deleted, they can be found in:\n   '%s'\n" % temp_dir)
            if sys.platform.lower().startswith('darwin') and ("'" not in temp_dir):
                MESSENGER.send_info('''
If you cannot see this directory in the Finder application, you may want to use
the 'open' command executed from a Terminal.  You can do this by launching the
/Applications/Utilities/Terminal program and then typing

open '%s'

followed by a return at the prompt. If the argument to the open command is a
directory, then it should open a Finder window in the directory (even if that
directory is hidden by default).