how to properly use $1 in an alias with two arguments
You cannot use aliases this way, however, you can define a function do to the same thing.
function gd() {
gvimdiff $1 dir/$1
}
Aliases don't work that way. You should be able to use history substitution (e.g. (no, !!:1
),bash
doesn't allow that) or define a function instead.