mirror of
https://github.com/idapython/src
synced 2026-06-08 14:47:00 +00:00
IDAPython 1.4.1:
- added AUTHORS.txt and changed the banner - IDAPython_ExecFile() will print script execution errors to the log window too - added 'ph' into idaapi. It is a replacement for idaapi.cvar.ph - added runscript to init.py for backward compatibility - added cli_t support
This commit is contained in:
+17
-6
@@ -39,16 +39,27 @@ class IDAPythonStdOut:
|
||||
def isatty(self):
|
||||
return False
|
||||
|
||||
# -----------------------------------------------------------------------
|
||||
def runscript(script):
|
||||
"""
|
||||
Executes a script.
|
||||
This function is present for backward compatiblity. Please use idaapi.IDAPython_ExecScript() instead
|
||||
|
||||
@param script: script path
|
||||
|
||||
@return: Error string or None on success
|
||||
"""
|
||||
|
||||
import idaapi
|
||||
return idaapi.IDAPython_ExecScript(script, globals())
|
||||
|
||||
# -----------------------------------------------------------------------
|
||||
def print_banner():
|
||||
banner = [
|
||||
"Python interpreter version %d.%d.%d %s (serial %d)" % sys.version_info,
|
||||
"Copyright (c) 1990-2010 Python Software Foundation - http://www.python.org/",
|
||||
"",
|
||||
"IDAPython" + (" 64-bit" if __EA64__ else "") + " version %d.%d.%d %s (serial %d)" % IDAPYTHON_VERSION,
|
||||
"Copyright (c) 2004-2010 Gergely Erdelyi - http://code.google.com/p/idapython/"
|
||||
"Python %d.%d.%d %s (serial %d) (c) 1990-2010 Python Software Foundation" % sys.version_info,
|
||||
"IDAPython" + (" 64-bit" if __EA64__ else "") + " v%d.%d.%d %s (serial %d) (c) The IDAPython Team <idapython@googlegroups.com>" % IDAPYTHON_VERSION
|
||||
]
|
||||
sepline = '-' * max([len(s) for s in banner])
|
||||
sepline = '-' * (max([len(s) for s in banner])+1)
|
||||
|
||||
print sepline
|
||||
print "\n".join(banner)
|
||||
|
||||
Reference in New Issue
Block a user