[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: URL to source file

Vincent Lefevre wrote:

> With zsh, you can avoid the pipe with zsh expansions:
>   local ver=${${(M)${(f)"$(aptitude show $pack)"}:#Version:*}#* }
> or with apt-cache (which is faster than aptitude):
>   local ver=${${(M)${(f)"$(apt-cache show --no-all-versions
> $pack)"}:#Version:*}#* }

Cool :) Thank you!


I have a rule not to use code I don't understand, so can you
please explain that syntax or provide a URL where it is
explained? (Or, just a list with names and/or examples should
be sufficient, actually.)

The M, f, quotes, colons, and hashes?

underground experts united

Reply to: