Show More
@@ -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 133 |
|
|
9 | $Id: iplib.py 1334 2006-05-30 03:36:04Z fperez $ | |
|
10 | 10 | """ |
|
11 | 11 | |
|
12 | 12 | #***************************************************************************** |
@@ -549,8 +549,10 b' class InteractiveShell(object,Magic):' | |||
|
549 | 549 | # a better ls |
|
550 | 550 | 'ls ls -F', |
|
551 | 551 | # long ls |
|
552 |
'll ls -lF' |
|
|
553 | # color ls | |
|
552 | 'll ls -lF') | |
|
553 | # Extra ls aliases with color, which need special treatment on BSD | |
|
554 | # variants | |
|
555 | ls_extra = ( # color ls | |
|
554 | 556 |
|
|
555 | 557 |
|
|
556 | 558 |
|
@@ -561,6 +563,19 b' class InteractiveShell(object,Magic):' | |||
|
561 | 563 |
|
|
562 | 564 |
|
|
563 | 565 |
|
|
566 | # The BSDs don't ship GNU ls, so they don't understand the | |
|
567 | # --color switch out of the box | |
|
568 | if 'bsd' in sys.platform: | |
|
569 | ls_extra = ( # ls normal files only | |
|
570 | 'lf ls -F -o %l | grep ^-', | |
|
571 | # ls symbolic links | |
|
572 | 'lk ls -F -o %l | grep ^l', | |
|
573 | # directories or links to directories, | |
|
574 | 'ldir ls -F -o %l | grep /$', | |
|
575 | # things which are executable | |
|
576 | 'lx ls -F -o %l | grep ^-..x', | |
|
577 | ) | |
|
578 | auto_alias = auto_alias + ls_extra | |
|
564 | 579 | elif os.name in ['nt','dos']: |
|
565 | 580 | auto_alias = ('dir dir /on', 'ls dir /on', |
|
566 | 581 | 'ddir dir /ad /on', 'ldir dir /ad /on', |
@@ -568,7 +583,7 b' class InteractiveShell(object,Magic):' | |||
|
568 | 583 | 'ren ren','cls cls','copy copy') |
|
569 | 584 | else: |
|
570 | 585 | auto_alias = () |
|
571 |
self.auto_alias = |
|
|
586 | self.auto_alias = [s.split(None,1) for s in auto_alias] | |
|
572 | 587 | # Call the actual (public) initializer |
|
573 | 588 | self.init_auto_alias() |
|
574 | 589 |
@@ -1,5 +1,10 b'' | |||
|
1 | 1 | 2006-05-29 Fernando Perez <Fernando.Perez@colorado.edu> |
|
2 | 2 | |
|
3 | * IPython/iplib.py (InteractiveShell.__init__): add check for the | |
|
4 | *BSDs to omit --color from all 'ls' aliases, since *BSD ls doesn't | |
|
5 | recognize the option. After a bug report by Will Maier. This | |
|
6 | closes #64 (will do it after confirmation from W. Maier). | |
|
7 | ||
|
3 | 8 | * IPython/irunner.py: New module to run scripts as if manually |
|
4 | 9 | typed into an interactive environment, based on pexpect. After a |
|
5 | 10 | submission by Ken Schutte <kschutte-AT-csail.mit.edu> on the |
General Comments 0
You need to be logged in to leave comments.
Login now