
I always check for changes in rpm files. Unfortunately, the command to do so needs some typing:
rpm -q --changelog PACKAGENAME|most
(Btw., most is a replacement for less). The best idea would be to have a bash/zsh/whatever alias with an argument. This is unfortunately difficult or even impossible, but it is quite easy to define a simple function:
rpmch () { rpm -q --changelog "$1"|most;}
Copy that string to your .zshrc or .bashrc and you can easily query the changelog of rpm packages with the command
rpmch PACKAGENAME
This of course works for other commands as well.

March 10, 2008 at 17:50
Looks like the definition is truncated. It works for me if I add “; }” (without the quotes).
March 10, 2008 at 20:47
Yes, sorry, the
}was missing. I don’t have to add a;though…March 10, 2008 at 21:12
Another very useful function working in that way:
mkcd() { mkdir -p “$1″ && cd “$1″; }
March 10, 2008 at 21:25
Another handy one is this alias for rpm -qa (which is faster to process and quicker to type).
March 10, 2008 at 21:25
Dang, the URL for the above comment should have been: http://dev-loki.blogspot.com/2007/04/rpm-qa.html
March 14, 2008 at 2:11
Assuming you are using, and putting up with, `most` for the color ability, I suggest adding
if [[ -x ` which less` ]] export LESSCHARSET="utf-8" then export PAGER="less" if [ $terminfo[colors] -ge 8 ] then export LESS_TERMCAP_mb=$'\E[01;31m' export LESS_TERMCAP_md=$'\E[01;31m' export LESS_TERMCAP_me=$'\E[0m' export LESS_TERMCAP_se=$'\E[0m' export LESS_TERMCAP_so=$'\E[01;44;33m' export LESS_TERMCAP_ue=$'\E[0m' export LESS_TERMCAP_us=$'\E[01;32m' fi else export PAGER="more" fito your RC files
March 14, 2008 at 12:32
RichH, actually I’m using most because it shows me on which line I am. And it always reminds me how to find the help
Anyway, what would happen when i use the commands above?
March 21, 2008 at 0:55
rpmch () { rpm -q --changelog "$1"| most }Instead you can use:
alias rpmch='rpm -q --changelog $1|most'June 9, 2008 at 6:01
that won’t work