[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Reminder: $EDITOR with spaces?

From: Marcus Comstedt <marcus_at_mc.pp.se>
Date: 2002-04-28 23:58:54 CEST

Alan Shutko <ats@acm.org> writes:

> Ok, I'm revising my old proposal. Forget $EDITOR. Don't use it at
> all. It's worthless because people insist on doing stupid stuff like
>
> > EDITOR='LD_LIBRARY_PATH=/some/lib /some/program'

If somebody does that, then it's because they're on a system where
they know that this works (and probably that just '/some/program'
doesn't), so exactly how is it stupid? Environment variables are
system local. There are no portability problems with somebody setting
their $EDITOR like that. And all that's needed to make it work is to
use system(). Which, as zw pointed out, is a function that by
definition exists in every C implementation.

> Choosing between system() and svn_io_run_cmd() is basically a choice
> between allowing stupid $EDITOR tricks and making sure $EDITOR will
> actually work on all files. Me, I'd take correct behaviour on every
> file over worrying about edge cases whipped up by twisted minds.

As long as it actually works on every file _subversion start $EDITOR
on_, it should be ok, no? As zw also pointed out, svn doesn't _have_
to use strange characters in the filenames of the log message files.
Don't try to solve a larger class of problems than we're actually
faced with.

  // Marcus

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Apr 29 00:03:51 2002

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.