diff --git a/ChangeLog b/ChangeLog index 0db1fc2..25559f9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -7,6 +7,7 @@ SVN installation). Experimental. Please report any error. + Removed /mnt, /media and /cdrom from the default EXCLUDE (thanks Tomoaki Nishiyama). + + Allow lowercase'd variables in porgrc (like 'include'). Version 0.8 (13 April 2015) diff --git a/lib/porg/baseopt.cc b/lib/porg/baseopt.cc index 733419e..43bcb6e 100644 --- a/lib/porg/baseopt.cc +++ b/lib/porg/baseopt.cc @@ -30,7 +30,7 @@ BaseOpt::BaseOpt() if (!porgrc) return; - Rexp re("^([A-Z_]+)=(.*)$"); + Rexp re("^([a-z_]+)=(.*)$", REG_ICASE); for (string buf, opt, val; getline(porgrc, buf); ) { @@ -39,13 +39,13 @@ BaseOpt::BaseOpt() opt = re.match(1); val = re.match(2); - if (opt == "LOGDIR") + if (opt == "logdir") s_logdir = sh_expand(val); - else if (opt == "INCLUDE") + else if (opt == "include") s_include = val; - else if (opt == "EXCLUDE") + else if (opt == "exclude") s_exclude = val; - else if (opt == "REMOVE_SKIP") + else if (opt == "remove_skip") s_remove_skip = val; } }