Loading slc/trunk/Makefile.am +2 −2 Changes for slc/trunk/Makefile.am: 2 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -6,8 +6,8 @@ slc_SOURCES= src/slc.hh \ src/options.hh \ src/screen.hh \ src/screen.cc \ src/history.hh \ src/history.cc src/error.hh \ src/error.cc CLEANFILES= *~ '\#*' .*.swp .*~ Loading slc/trunk/TODO +1 −2 Changes for slc/trunk/TODO: 1 added line, 2 removed lines. Original line number Diff line number Diff line Gestion du redimensionnements Gestion de plus de touche sauvegarde de l'history dans un fichier Tout le reste... slc/trunk/src/history.cc −31 File deleted. Show changes slc/trunk/src/history.hh −26 File deleted. Show changes slc/trunk/src/options.cc +15 −6 Changes for slc/trunk/src/options.cc: 15 added lines, 6 removed lines. Original line number Diff line number Diff line Loading @@ -2,9 +2,12 @@ #include "options.hh" #include <getopt.h> #include <stdlib.h> Options::Options() { port = 18136; history_size = 100; history_file = (string) getenv("HOME") + "/.slc_history"; } void Options::usage(const char *name, ostream &out) const { Loading Loading @@ -56,10 +59,16 @@ Options &Options::load(int argc, char *argv[]) { return *this; } ostream &operator<< (ostream &s, const Options &o) { return s << "server: " << o.server << std::endl << "port: " << o.port << std::endl << "host login: " << o.login << std::endl << "host pass: " << o.pass << std::endl; } Options &Options::loadenv() { const char *senv; // Get history path if ((senv = getenv("SLC_HISTORY_FILE")) != 0 && *senv != 0) history_file = senv; // Get history size if ((senv = getenv("SLC_HISTORY_SIZE")) != 0 && *senv != 0) history_size = atoi(senv); return *this; } Loading
slc/trunk/Makefile.am +2 −2 Changes for slc/trunk/Makefile.am: 2 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -6,8 +6,8 @@ slc_SOURCES= src/slc.hh \ src/options.hh \ src/screen.hh \ src/screen.cc \ src/history.hh \ src/history.cc src/error.hh \ src/error.cc CLEANFILES= *~ '\#*' .*.swp .*~ Loading
slc/trunk/TODO +1 −2 Changes for slc/trunk/TODO: 1 added line, 2 removed lines. Original line number Diff line number Diff line Gestion du redimensionnements Gestion de plus de touche sauvegarde de l'history dans un fichier Tout le reste...
slc/trunk/src/options.cc +15 −6 Changes for slc/trunk/src/options.cc: 15 added lines, 6 removed lines. Original line number Diff line number Diff line Loading @@ -2,9 +2,12 @@ #include "options.hh" #include <getopt.h> #include <stdlib.h> Options::Options() { port = 18136; history_size = 100; history_file = (string) getenv("HOME") + "/.slc_history"; } void Options::usage(const char *name, ostream &out) const { Loading Loading @@ -56,10 +59,16 @@ Options &Options::load(int argc, char *argv[]) { return *this; } ostream &operator<< (ostream &s, const Options &o) { return s << "server: " << o.server << std::endl << "port: " << o.port << std::endl << "host login: " << o.login << std::endl << "host pass: " << o.pass << std::endl; } Options &Options::loadenv() { const char *senv; // Get history path if ((senv = getenv("SLC_HISTORY_FILE")) != 0 && *senv != 0) history_file = senv; // Get history size if ((senv = getenv("SLC_HISTORY_SIZE")) != 0 && *senv != 0) history_size = atoi(senv); return *this; }