BusyBox Bug and Patch Tracking
BusyBox
  

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0000648 [BusyBox] New Features minor always 01-18-06 13:51 02-20-06 12:08
Reporter sw View Status public  
Assigned To BusyBox
Priority normal Resolution fixed  
Status closed   Product Version 1.01
Summary 0000648: Patch for busybox shell (tab completion)
Description Hello,

this patch improves tab completion for the shell by making it more
compatible
with bash's behaviour. Without patch, tab completion for . and .. does not
work as expected. The original code was introduced with SVN revision 2905.

The patch also reduces the busybox size by a few bytes :-)

Regards
Stefan
Additional Information
Attached Files

- Relationships

- Notes
(0000948)
vodz
01-19-06 01:05

> Without patch, tab completion for . and .. does not
work as expected.

Hmm. For "." my cmdedit works as bash 2.05b.0(1)-release
For ".." you may be right.
 
(0000949)
vodz
01-19-06 01:11

Also.
If current directory have file like "..file", my cmdedit works like bash.
For make bash-like tab completion require add code in found you the place:
if found "../" without other "..any_matches" add '/', else do not add '/'.
I think, best if do not change to cmdedit. Bash have bloat features for busybox.
 
(0000956)
sw
01-19-06 11:33

At least bash 2.05b.0(1) and bash 3.00.16(1) differ.

Testenvironment is this hierarchy of files and directories:
tabdemo/
tabdemo/dir1
tabdemo/.dir2
tabdemo/file1
tabdemo/..file3
tabdemo/..dir3
tabdemo/.file2

-------------------------

Feature 1:

Here is the output from the new bash:
user@linux:/tabdemo$ ls <tab>
dir1/ .dir2/ ..dir3/ file1 .file2 ..file3

Note that showing entries with leading dot is a bash option.

user@linux:/tabdemo$ ls .<tab>
./ ../ .dir2/ ..dir3/ .file2 ..file3

Bash marks directories with a trailing slash.

The patched busybox has this output:

root@sinus154:/tabdemo# ls <tab>
dir1/ file1
root@sinus154:/tabdemo# ls .
../ ..dir3/ ..file3 ./ .dir2/ .file2

So the behaviour of the patches busybox is now nearly identical:
the sort order of entries should ignore the trailing slash, so
./ should be the first entry.

-------------------------

Feature 2:

In subdirectory dir1, ls ..<tab> expands to ls ../ (what I expect):
user@linux:/tabdemo/dir1$ ls ../
dir1/ .dir2/ ..dir3/ file1 .file2 ..file3

So does the patched busybox shell.

-------------------------

The unpatched busybox shell does not have feature 1 (trailing / for directories). It also fails at feature 2 (expand ..<tab> into ../).
 
(0000994)
vodz
01-25-06 03:55

Ok. See 13587 revision. Sorting rewtoted - more added code.
 

- Issue History
Date Modified Username Field Change
01-18-06 13:51 sw New Issue
01-18-06 13:51 sw Status new => assigned
01-18-06 13:51 sw Assigned To  => BusyBox
01-19-06 01:05 vodz Note Added: 0000948
01-19-06 01:11 vodz Note Added: 0000949
01-19-06 11:33 sw Note Added: 0000956
01-25-06 03:55 vodz Note Added: 0000994
01-25-06 04:55 vodz Status assigned => resolved
01-25-06 04:55 vodz Resolution open => fixed
01-25-06 04:55 vodz Additional Information Updated
02-20-06 12:08 landley Status resolved => closed
05-24-07 05:34 yogui Issue Monitored: yogui
05-24-07 05:36 yogui Issue End Monitor: yogui


Copyright © 2000 - 2006 Mantis Group
Powered by Mantis Bugtracker