![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to create a custom GUI | hirosima | High Level Programming | 2 | 01-13-2006 05:03 AM |
| Auto Complete | cordobapablo | UNIX for Dummies Questions & Answers | 4 | 10-18-2005 02:53 PM |
| Auto complete | Tom_Zamani | UNIX Desktop for Dummies Questions & Answers | 4 | 07-28-2005 06:30 AM |
| Custom ftp settings | blp001 | UNIX for Dummies Questions & Answers | 1 | 05-24-2002 09:37 PM |
| Auto Complete under AIX | truma1 | UNIX for Advanced & Expert Users | 7 | 10-11-2001 12:08 AM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
Hello:
I am using csh, and am a complete noob when it comes to shell scripting. I want the following: 1) Ignore case when doing auto-complete. 2) If there are multiple matches (example: I have files abc.txt abc.txt.1, abc.txt.2 and type abc<tab>), count the number of matches. If the number of matches is less than a set amount, say 5, then cycle through them upon tab. Meaning when I press abc<tab> it first completes abc.txt, then when I press <tab> again, it completes it to abc.txt.1, then abc.txt.2, and then my original uncompleted word, abc. If the number of matches is more than 5 and less than 20, it should show me all possibilities upon pressing tab. If the number of matches is more than 20, it should ask me whether I want a full listing. Upon pressing y or n, it should do the appropriate action (i.e. show me all possible matches, or not show any match). 3) When the number of matches is less than 5, shift-tab should cycle backwards in the list of matched filenames/dir-names. I want to write a script in .cshrc to do the above, but don't know how/where to start. Can anyone help me write this? Regards, [Bump] Last edited by madiyaan; 05-23-2008 at 03:06 PM.. Reason: Added shift-tab |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|