Bob
I should point out there is a big difference between the EDITOR environment
variable (explained by Rich below) and the 'alias' command.
You might want to check this resources:
http://www.gnu.org/software/bash/manual/
The O'Reilly Bash book is pretty good too!
Cheers
François
On Jun 13, 2012, at 8:25 PM, bobPCL wrote:
> thanks. That does work for crontab. Unfortunately it does work if you say
> "edit file.name", you can say bbedit but not edit.
>
> I guess it only works in some contexts. On my old unix systems I used to have
> emacs come up instead of vi, I just can't remember how I used to do it.
>
> On Wednesday, June 13, 2012 8:08:38 PM UTC-4, François Schiettecatte wrote:
> Bob
>
> Works for me:
>
> macpro: ~ > which bbedit
> /usr/bin/bbedit
>
> in .bash_profile :
>
> #export EDITOR='vi'
> export EDITOR='/usr/bin/bbedit'
>
>
> macpro: ~ > source .bash_profile
> macpro: ~ > echo $EDITOR
> /usr/bin/bbedit
> macpro: ~ > crontab -e (opens crontab
> in bbedit)
> crontab: no changes made to crontab
> macpro: ~ >
>
>
> François
>
>
> On Jun 13, 2012, at 8:04 PM, bobPCL wrote:
>
> > Thanks for the response, sorry I wasn't clear. What I'm trying to do is use
> > a command line window (e.g. terminal) and type the word "edit" and get
> > bbedit to open. I have another script I want to run that using the default
> > environment editor, which is currently not bbedit.
> >
> > So do you (or anyone) know how to make bbedit the "preferred" editor?
> >
> >
> > On Wednesday, June 13, 2012 7:05:51 PM UTC-4, Rich Siegel wrote:
> >
> >
> > >"-bash: edit: command not found".
> >
> > "edit" is not a bash command. You can invoke BBEdit using
> > "bbedit"; but the EDITOR variable is used by other programs to
> > invoke your preferred editor, and has no bearing on what you can
> > (or can't) do at the command line.
> >
> > R.
> > --
> > Rich Siegel Bare Bones Software, Inc.
> > <[email protected]> <http://www.barebones.com/>
> >
> > Someday I'll look back on all this and laugh... until they
> > sedate me.
> >
> >
> > --
> > You received this message because you are subscribed to the
> > "BBEdit Talk" discussion group on Google Groups.
> > To post to this group, send email to [email protected]
> > To unsubscribe from this group, send email to
> > [email protected]
> > For more options, visit this group at
> > <http://groups.google.com/group/bbedit?hl=en>
> > If you have a feature request or would like to report a problem,
> > please email "[email protected]" rather than posting to the group.
> > Follow @bbedit on Twitter: <http://www.twitter.com/bbedit>
>
>
> --
> You received this message because you are subscribed to the
> "BBEdit Talk" discussion group on Google Groups.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> <http://groups.google.com/group/bbedit?hl=en>
> If you have a feature request or would like to report a problem,
> please email "[email protected]" rather than posting to the group.
> Follow @bbedit on Twitter: <http://www.twitter.com/bbedit>
--
You received this message because you are subscribed to the
"BBEdit Talk" discussion group on Google Groups.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
<http://groups.google.com/group/bbedit?hl=en>
If you have a feature request or would like to report a problem,
please email "[email protected]" rather than posting to the group.
Follow @bbedit on Twitter: <http://www.twitter.com/bbedit>