I am currently having problems with awk usage of shell variables. Here's my problem,
when I run the following:

> 
> awk -F: '$1=="marco" {print $7}' /etc/passwd
> 
> 
> 

everything works fine and dandy. However, I want to be able to pass my $user shell variable instead of "marco", so I try the following (after reading about -v flag):

> 
> awk -F: -v awkvar=$user '$1=="$awkvar" {print $7}' /etc/passwd
> 
> 
> 

and it doesn't seem to work. Can anyone help me?

Thanks!