FACT++  1.0
void Readline::StaticPopHistory ( const std::string &  fname = "")
static

Writes the current history to the file with the given name and replaces the history by the file defined by fName.

Parameters
fnameName of the history file to write (it will be truncated to 1000 lines)

Definition at line 1322 of file Readline.cc.

References fName, and This.

Referenced by Instance().

1323 {
1324  fs::path his = fs::path(This->fName).parent_path();
1325  his /= fname;
1326 
1327  write_history(his.string().c_str());
1328  history_truncate_file(his.string().c_str(), 1000);
1329 
1330  stifle_history(0);
1331  unstifle_history();
1332  read_history(This->fName.c_str());
1333 }
static Readline * This
Definition: Readline.h:19
std::string fName
Definition: Readline.h:22

+ Here is the caller graph for this function: