Skip to main content
Welcome guest. | Register | Login | Post

Problem with aliasing

1 reply [Last post]
a thing's picture
Offline
Joined: 2005-12-20

I'm using kdialog a lot in a Bash script, and I always use the option --title="$title". So I made an alias, alias kdialog="kdialog --title=\"$title\"". The line alias|grep kdialog in the script outputs alias kdialog='kdialog --title="Audio Konvert 0.3.0"', but the title of a dialog created with kdialog --yesno "test" has a title of "Question - KDialog."

I'm trying to keep this all in one script.

a thing's picture
Offline
Joined: 2005-12-20

Using the below function instead of an alias does it:

kdialog ()
{
	`whereis 'kdialog'|cut -d' ' -f2` --title="$title" "$@"
}

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.