##// END OF EJS Templates
hist -t default, omit last empty line in input_hist_raw on multiline statements, old changelog entries
vivainio -
Show More
@@ -24,13 +24,15 b" def magic_history(self, parameter_s = ''):"
24 24
25 25 This feature is only available if numbered prompts are in use.
26 26
27 -t: print the 'translated' history, as IPython understands it. IPython
28 filters your input and converts it all into valid Python source before
29 executing it (things like magics or aliases are turned into function
30 calls, for example). With this option, you'll see the native history
31 instead of the user-entered version: '%cd /' will be seen as
27 -t: (default) print the 'translated' history, as IPython understands it.
28 IPython filters your input and converts it all into valid Python source
29 before executing it (things like magics or aliases are turned into
30 function calls, for example). With this option, you'll see the native
31 history instead of the user-entered version: '%cd /' will be seen as
32 32 '_ip.magic("%cd /")' instead of '%cd /'.
33 33
34 -r: print the 'raw' history, i.e. the actual commands you typed.
35
34 36 -g: treat the arg as a pattern to grep for in (full) history.
35 37 This includes the "shadow history" (almost all commands ever written).
36 38 Use '%hist -g' to show full shadow history (may be very long).
@@ -44,13 +46,16 b" def magic_history(self, parameter_s = ''):"
44 46 if not shell.outputcache.do_full_cache:
45 47 print 'This feature is only available if numbered prompts are in use.'
46 48 return
47 opts,args = self.parse_options(parameter_s,'gnts',mode='list')
49 opts,args = self.parse_options(parameter_s,'gntsr',mode='list')
48 50
49 if not opts.has_key('t'):
51 if opts.has_key('t'):
52 input_hist = shell.input_hist
53 elif opts.has_key('r'):
50 54 input_hist = shell.input_hist_raw
51 55 else:
52 56 input_hist = shell.input_hist
53 57
58
54 59 default_length = 40
55 60 pattern = None
56 61 if opts.has_key('g'):
@@ -6,7 +6,7 b' Requires Python 2.3 or newer.'
6 6
7 7 This file contains all the classes and helper functions specific to IPython.
8 8
9 $Id: iplib.py 2646 2007-08-20 16:28:48Z vivainio $
9 $Id: iplib.py 2652 2007-08-22 17:25:24Z vivainio $
10 10 """
11 11
12 12 #*****************************************************************************
@@ -2046,7 +2046,7 b' want to merge them back into the new files.""" % locals()'
2046 2046 # only entries starting at first column go to shadow history
2047 2047 if line.lstrip() == line:
2048 2048 self.shadowhist.add(line.strip())
2049 else:
2049 elif not continue_prompt:
2050 2050 self.input_hist_raw.append('\n')
2051 2051 try:
2052 2052 lineout = self.prefilter(line,continue_prompt)
@@ -1,3 +1,27 b''
1 2007-08-22 Ville Vainio <vivainio@gmail.com>
2
3 * iplib.py: no extra empty (last) line in raw hist w/ multiline
4 statements
5
6 2007-08-21 Ville Vainio <vivainio@gmail.com>
7
8 * ipmaker.py: finding ipythonrc-PROF now skips ipy_profile_PROF.
9 (for backwards compatibility)
10
11 * history.py: switch back to %hist -t from %hist -r as default.
12 At least until raw history is fixed for good.
13
14 2007-08-20 Ville Vainio <vivainio@gmail.com>
15
16 * ipapi.py, iplib.py: DebugTools accessible via _ip.dbg, to catch &
17 locate alias redeclarations etc. Also, avoid handling
18 _ip.IP.alias_table directly, prefer using _ip.defalias.
19
20
21 2007-08-15 Ville Vainio <vivainio@gmail.com>
22
23 * prefilter.py: ! is now always served first
24
1 25 2007-08-15 Fernando Perez <Fernando.Perez@colorado.edu>
2 26
3 27 * IPython/iplib.py (safe_execfile): fix the SystemExit
General Comments 0
You need to be logged in to leave comments. Login now