diff src/oct-hist.cc @ 195:13c6086c325c

[project @ 1993-11-06 10:12:29 by jwe]
author jwe
date Sat, 06 Nov 1993 10:14:11 +0000
parents a500c60e8f23
children cd2e49fb4f6b
line wrap: on
line diff
--- a/src/oct-hist.cc
+++ b/src/oct-hist.cc
@@ -49,6 +49,7 @@
 #include "error.h"
 #include "input.h"
 #include "octave.h"
+#include "user-prefs.h"
 #include "unwind-prot.h"
 #include "octave-hist.h"
 #include "sighandlers.h"
@@ -415,8 +416,6 @@
 
 #define histline(i) (hlist[(i)]->line)
 
-#define EDIT_COMMAND "${EDITOR:-vi}"
-
 static char *
 mk_tmp_hist_file (int argc, char **argv, int insert_curr, char *warn_for)
 {
@@ -529,7 +528,7 @@
 // Call up our favorite editor on the file of commands.
 
   ostrstream buf;
-  buf << EDIT_COMMAND << " " << name << ends;
+  buf << user_pref.editor << " " << name << ends;
   char *cmd = buf.str ();
 
 // Ignore interrupts while we are off editing commands.  Should we