Operators and Keywords

Function List:

C++ API File Reference

#include <cstdlib>
#include <cstring>
#include <string>
#include <fstream>
#include "cmd-hist.h"
#include "file-ops.h"
#include "lo-mappers.h"
#include "oct-env.h"
#include "oct-time.h"
#include "str-vec.h"
#include <defaults.h>
#include "defun.h"
#include "error.h"
#include "gripes.h"
#include "input.h"
#include "oct-hist.h"
#include "oct-obj.h"
#include "pager.h"
#include "parse.h"
#include "sighandlers.h"
#include "sysdep.h"
#include "toplev.h"
#include "unwind-prot.h"
#include "utils.h"
#include "variables.h"

Include dependency graph for


void initialize_history (bool read_history_file)
void octave_history_write_timestamp (void)
 DEFUN (edit_history, args,,"-*- texinfo -*-\n\ @deffn {Command} edit_history [@var{first}] [@var{last}]\n\ If invoked with no arguments, @code{edit_history} allows you to edit the\n\ history list using the editor named by the variable @w{@code{EDITOR}}. The\n\ commands to be edited are first copied to a temporary file. When you\n\ exit the editor, Octave executes the commands that remain in the file.\n\ It is often more convenient to use @code{edit_history} to define functions \n\ rather than attempting to enter them directly on the command line.\n\ By default, the block of commands is executed as soon as you exit the\n\ editor. To avoid executing any commands, simply delete all the lines\n\ from the buffer before exiting the editor.\n\ \n\ The @code{edit_history} command takes two optional arguments specifying\n\ the history numbers of first and last commands to edit. For example,\n\ the command\n\ \n\ @example\n\ edit_history 13\n\ @end example\n\ \n\ @noindent\n\ extracts all the commands from the 13th through the last in the history\n\ list. The command\n\ \n\ @example\n\ edit_history 13 169\n\ @end example\n\ \n\ @noindent\n\ only extracts commands 13 through 169. Specifying a larger number for\n\ the first command than the last command reverses the list of commands\n\ before placing them in the buffer to be edited. If both arguments are\n\ omitted, the previous command in the history list is used.\n\ @seealso{run_history}\n\ @end deffn")
 DEFUN (history, args,,"-*- texinfo -*-\n\ @deffn {Command} history options\n\ If invoked with no arguments, @code{history} displays a list of commands\n\ that you have executed. Valid options are:\n\ \n\ @table @code\n\ @item -w @var{file}\n\ Write the current history to the file @var{file}. If the name is\n\ omitted, use the default history file (normally @file{~/.octave_hist}).\n\ \n\ @item -r @var{file}\n\ Read the file @var{file}, replacing the current history list with its\n\ contents. If the name is omitted, use the default history file\n\ (normally @file{~/.octave_hist}).\n\ \n\ @item @var{n}\n\ Display only the most recent @var{n} lines of history.\n\ \n\ @item -q\n\ Don't number the displayed lines of history. This is useful for cutting\n\ and pasting commands using the X Window System.\n\ @end table\n\ \n\ For example, to display the five most recent commands that you have\n\ typed without displaying line numbers, use the command\n\ @kbd{history -q 5}.\n\ @end deffn")
 DEFUN (run_history, args,,"-*- texinfo -*-\n\ @deffn {Command} run_history [@var{first}] [@var{last}]\n\ Similar to @code{edit_history}, except that the editor is not invoked,\n\ and the commands are simply executed as they appear in the history list.\n\ @seealso{edit_history}\n\ @end deffn")
 DEFUN (history_size, args, nargout,"-*- texinfo -*-\n\ @deftypefn {Built-in Function} {@var{val} =} history_size ()\n\ @deftypefnx {Built-in Function} {@var{old_val} =} history_size (@var{new_val})\n\ Query or set the internal variable that specifies how many entries\n\ to store in the history file. The default value is @code{1024},\n\ but may be overridden by the environment variable @w{@code{OCTAVE_HISTSIZE}}.\n\ @seealso{history_file, history_timestamp_format_string, saving_history}\n\ @end deftypefn")
 DEFUN (history_file, args, nargout,"-*- texinfo -*-\n\ @deftypefn {Built-in Function} {@var{val} =} history_file ()\n\ @deftypefnx {Built-in Function} {@var{old_val} =} history_file (@var{new_val})\n\ Query or set the internal variable that specifies the name of the\n\ file used to store command history. The default value is\n\ @file{~/.octave_hist}, but may be overridden by the environment\n\ variable @w{@code{OCTAVE_HISTFILE}}.\n\ @seealso{history_size, saving_history, history_timestamp_format_string}\n\ @end deftypefn")
 DEFUN (history_timestamp_format_string, args, nargout,"-*- texinfo -*-\n\ @deftypefn {Built-in Function} {@var{val} =} history_timestamp_format_string ()\n\ @deftypefnx {Built-in Function} {@var{old_val} =} history_timestamp_format_string (@var{new_val})\n\ Query or set the internal variable that specifies the format string\n\ for the comment line that is written to the history file when Octave\n\ exits. The format string is passed to @code{strftime}. The default\n\ value is\n\ \n\ @example\n\ \"# Octave VERSION, %a %b %d %H:%M:%S %Y %Z <USER@@HOST>\"\n\ @end example\n\ @seealso{strftime, history_file, history_size, saving_history}\n\ @end deftypefn")
 DEFUN (saving_history, args, nargout,"-*- texinfo -*-\n\ @deftypefn {Built-in Function} {@var{val} =} saving_history ()\n\ @deftypefnx {Built-in Function} {@var{old_val} =} saving_history (@var{new_val})\n\ Query or set the internal variable that controls whether commands entered\n\ on the command line are saved in the history file.\n\ @seealso{history_file, history_size, history_timestamp_format_string}\n\ @end deftypefn")


bool input_from_tmp_history_file = false
bool Vsaving_history = true

Function Documentation

DEFUN ( saving_history  ,
args  ,

DEFUN ( history_timestamp_format_string  ,
args  ,

DEFUN ( history_file  ,
args  ,

DEFUN ( history_size  ,
args  ,

DEFUN ( run_history  ,

DEFUN ( history  ,

DEFUN ( edit_history  ,

void initialize_history ( bool  read_history_file  ) 

void octave_history_write_timestamp ( void   ) 

Variable Documentation