# HG changeset patch # User jwe # Date 1114700494 0 # Node ID aaa6df7aa13a6106c1a781a35c1b4e4b05d991e6 # Parent f9aff9291d944725a6acddfa266f5d78a5e148fb [project @ 2005-04-28 15:01:33 by jwe] diff --git a/scripts/startup/Makefile.in b/scripts/startup/Makefile.in --- a/scripts/startup/Makefile.in +++ b/scripts/startup/Makefile.in @@ -20,7 +20,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ -SOURCES = octaverc # *.m +SOURCES = main-rcfile local-rcfile inputrc # *.m DISTFILES = Makefile.in $(SOURCES) @@ -34,14 +34,19 @@ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(fcnfiledir)/$(script_sub_dir) if test -f $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/octaverc; then true; \ else \ - $(INSTALL_DATA) $(srcdir)/octaverc \ + $(INSTALL_DATA) $(srcdir)/main-rcfile \ $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/octaverc; \ fi + if test -f $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/inputrc; then true; \ + else \ + $(INSTALL_DATA) $(srcdir)/inputrc \ + $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/inputrc; \ + fi $(top_srcdir)/mkinstalldirs $(DESTDIR)$(localfcnfiledir)/$(script_sub_dir) if test -f $(DESTDIR)$(localfcnfiledir)/$(script_sub_dir)/octaverc; \ then true; \ else \ - $(INSTALL_DATA) $(srcdir)/octaverc \ + $(INSTALL_DATA) $(srcdir)/local-rcfile \ $(DESTDIR)$(localfcnfiledir)/$(script_sub_dir)/octaverc; \ fi # for f in $(FCN_FILES_NO_DIR); do \ diff --git a/scripts/startup/inputrc b/scripts/startup/inputrc new file mode 100644 --- /dev/null +++ b/scripts/startup/inputrc @@ -0,0 +1,21 @@ +## This file configures the behavior of line-input editing for all +## Octave users when Octave is configured to use GNU Readline library +## for input-line editing. + +## history-search-backward: +## +## Search backward through the history for the string of characters +## between the start of the current line and the point. This is a +## non-incremental search. Bound to "\e[A", the ANSI escape +## sequence for the UP arrow. + +"\e[A": history-search-backward + +## history-search-forward: +## +## Search forward through the history for the string of characters +## between the start of the current line and the point. This is a +## non-incremental search. Bound to "\e[B", the ANSI escape +## sequence for the DOWN arrow. + +"\e[B": history-search-forward diff --git a/scripts/startup/local-rcfile b/scripts/startup/local-rcfile new file mode 100644 --- /dev/null +++ b/scripts/startup/local-rcfile @@ -0,0 +1,4 @@ +## System-wide startup file for Octave. +## +## This file should contain any commands that should be executed each +## time Octave starts for every user at this site. diff --git a/scripts/startup/main-rcfile b/scripts/startup/main-rcfile new file mode 100644 --- /dev/null +++ b/scripts/startup/main-rcfile @@ -0,0 +1,11 @@ +## System-wide startup file for Octave. +## +## This file should contain any commands that should be executed each +## time Octave starts for every user at this site. + +## Configure readline using the file inputrc in the Octave startup +## directory. + +read_readline_init_file (sprintf ("%s%s%s", + octave_config_info ("startupfiledir"), + filesep, "inputrc")); diff --git a/scripts/startup/octaverc b/scripts/startup/octaverc deleted file mode 100644 --- a/scripts/startup/octaverc +++ /dev/null @@ -1,4 +0,0 @@ -## System-wide startup file for Octave. -## -## This file should contain any commands that should be executed each -## time Octave starts for every user at this site.