POV-Ray : Newsgroups : povray.off-topic : Who was looking for message-passing OS examples? : Re: OS what-ifs Server Time
7 Sep 2024 09:24:03 EDT (-0400)
  Re: OS what-ifs  
From: Warp
Date: 18 Aug 2008 18:57:35
Message: <48a9fe5e@news.povray.org>
Nicolas Alvarez <nic### [at] gmailcom> wrote:
> Recent versions of bash come preconfigured for smart autocomplete. Random
> example: 
> apt-get remove <tab> completes package names you already have installed.

  I like the smart autocomplete in zsh. For example, if I write this in zsh:

mplayer -su<tab>

it will autocomplete it to "mplayer -sub", but since that's not the only
possible valid completion, if I press tab again, it will list all the
possibities:

mplayer -sub<tab>
-sub                 -- use specified subtitle file
-sub-bg-alpha        -subcp               -subfont-osd-scale
-sub-bg-color        -subdelay            -subfont-outline
-sub-no-text-pp      -subfont-autoscale   -subfont-text-scale
-subalign            -subfont-blur        -subfps
-subcc               -subfont-encoding    -subpos

  The autocompletion of file names is also application-dependent. For
example, if I have three files in the current directory, let's say
test.txt, test.cc and test.pdf, if I write this:

acroread t<tab>

it will directly autocomplate to "test.pdf" because that's the only one
of those files which is valid for acroread.

  Also if I have a bunch of files whose names start with a 't', and all
of them have the access rights "-rw-r--r--" except one, which has the
rights "-rw-------", and then I write this:

chmod og+r t<tab>

it will directly autocomplete to the only file for which that command
makes sense (ie. the file which didn't have the +r rights already).

-- 
                                                          - Warp


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.