[Cvsshell-devel] CVS: cvsshell/src app.py,1.14,1.15 basic_cmds.py,1.23,1.24 cvs_cmds.py,1.16,1.17 cv
Status: Beta
Brought to you by:
stefanheimann
From: Stefan H. <ste...@us...> - 2002-09-16 06:49:35
|
Update of /cvsroot/cvsshell/cvsshell/src In directory usw-pr-cvs1:/tmp/cvs-serv2261/src Modified Files: app.py basic_cmds.py cvs_cmds.py cvs_shell.py interactive_app.py Log Message: changes of release 0.3.0 -> 0.3.1 Index: app.py =================================================================== RCS file: /cvsroot/cvsshell/cvsshell/src/app.py,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** app.py 29 Jul 2002 17:29:10 -0000 1.14 --- app.py 16 Sep 2002 06:49:32 -0000 1.15 *************** *** 218,222 **** sys.exit(status) ! def shell(self, command, fork=0, inp=''): if self.isVerbose(): self.printMsg(command) # how about ipc? --- 218,222 ---- sys.exit(status) ! def shell(self, command, fork=0): if self.isVerbose(): self.printMsg(command) # how about ipc? *************** *** 224,232 **** pipe = os.popen(command, 'r') res = pipe.read() else: ! pipe = os.popen(command, 'w') ! pipe.write(inp) # send it input res = None - exitCode = pipe.close() if exitCode is not None: raise ShellException(exitCode) --- 224,231 ---- pipe = os.popen(command, 'r') res = pipe.read() + exitCode = pipe.close() else: ! exitCode = os.system(command) res = None if exitCode is not None: raise ShellException(exitCode) Index: basic_cmds.py =================================================================== RCS file: /cvsroot/cvsshell/cvsshell/src/basic_cmds.py,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** basic_cmds.py 7 Aug 2002 21:37:12 -0000 1.23 --- basic_cmds.py 16 Sep 2002 06:49:32 -0000 1.24 *************** *** 174,177 **** --- 174,183 ---- wDir = wDir or '.' try: + if not os.path.exists(wDir): + app.printErr('directory does not exist.') + return + if not os.path.isdir(wDir): + app.printErr('path does not denote a directory.') + return if not os.path.exists(os.path.join(wDir, 'CVS')): app.printErr('directory is not under CVS control.') Index: cvs_cmds.py =================================================================== RCS file: /cvsroot/cvsshell/cvsshell/src/cvs_cmds.py,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** cvs_cmds.py 15 Aug 2002 21:42:17 -0000 1.16 --- cvs_cmds.py 16 Sep 2002 06:49:32 -0000 1.17 *************** *** 58,62 **** except CvsError: return entries = [] ! dir = None n = len(lines) i = 0 --- 58,62 ---- except CvsError: return entries = [] ! dir = '.' n = len(lines) i = 0 Index: cvs_shell.py =================================================================== RCS file: /cvsroot/cvsshell/cvsshell/src/cvs_shell.py,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** cvs_shell.py 15 Aug 2002 21:42:17 -0000 1.32 --- cvs_shell.py 16 Sep 2002 06:49:32 -0000 1.33 *************** *** 28,32 **** from plugable_app import PlugableApp ! VERSION = '0.3' NAME ='CvsShell' COPYRIGHT = 'Copyright 2002 Stefan Heimann (ma...@st...).\n' \ --- 28,32 ---- from plugable_app import PlugableApp ! VERSION = '0.3.1' NAME ='CvsShell' COPYRIGHT = 'Copyright 2002 Stefan Heimann (ma...@st...).\n' \ *************** *** 87,91 **** self.readConfigFile() self.listingFilter = utils.splitquoted(self.configMap.get('filter','')) ! self.enableColor = self.configMap.get('colors', 'off') == 'on' self.batchMode = 0 self.completeableCommands = self.getAvailableCommands() --- 87,91 ---- self.readConfigFile() self.listingFilter = utils.splitquoted(self.configMap.get('filter','')) ! self.enableColor = self.configMap.get('colors', 'off') == 'on' and not self.onWindows self.batchMode = 0 self.completeableCommands = self.getAvailableCommands() Index: interactive_app.py =================================================================== RCS file: /cvsroot/cvsshell/cvsshell/src/interactive_app.py,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** interactive_app.py 29 Jul 2002 17:29:10 -0000 1.13 --- interactive_app.py 16 Sep 2002 06:49:32 -0000 1.14 *************** *** 50,55 **** pass import atexit ! atexit.register(readline.write_history_file, self.historyFile) def run(self): while 1: --- 50,63 ---- pass import atexit ! atexit.register(self.writeHistoryFile) + def writeHistoryFile(self): + try: + import readline + readline.write_history_file(self.historyFile) + except ImportError: pass + except IOError, msg: + self.printErr(msg) + def run(self): while 1: |