removing *all* mirrors?
snowcrash+smart
schneecrash+smart at gmail.com
Mon Dec 11 09:11:05 PST 2006
> Smart uses the EDITOR environment variable by default,
yes, that's what i understand.
and why i've set the var in my .login.
that's what it's reporting (echo $EDITOR), per msg above.
> If you're getting vi, the process doesn't have the environment
> set correctly (maybe you're using sudo, or whatever).
>
> You can check that by investigating the /proc/<pid>/environ entry
> for the smart process.
ok. i admit it. i'm confused.
the var *is* set.
echo $EDITOR
reports it correctly, no?
fwiw, i'm ssh'd in as root to the box -- no sudo involved.
the same behavior is seen in konsole login to root at shell
yet, as you've suggested loooking,
/root# ps ax | grep smart
3901 pts/1 S+ 0:00 /usr/bin/python /usr/bin/smart mirror --edit
3910 pts/2 R+ 0:00 grep smart
/root# cat /proc/3901/environ | grep -i editor
/root#
/root# cat /proc/3901/environ | grep -i joe
/root#
/root# cat /proc/3901/environ | grep -i /vi
/root#
thanks for your help.
p.s. if would be nice to be able to pass the editor as a param to the
smart cmd, e.g.
smart mirror --edit
would use the DEFAULT editor (once i fidure out how to do that correctly!)
and, e.g.,
smart mirror --edit=/usr/bin/joe
would open/edit the file w/ 'joe'.
More information about the Smart
mailing list