diff --git a/NEWS b/NEWS index 0c55f864..8b784bb8 100644 --- a/NEWS +++ b/NEWS @@ -15,6 +15,8 @@ ncmpcpp-0.7 (????-??-??) * Current MPD host may now be shown in playlist (playlist_show_mpd_host configuration variable, disabled by default). * Random album artists can now be added to the playlist. * Case insensitive searching is now Unicode aware as long as boost was compiled with ICU support. +* Searching with regular expressions are now enabled by default. +* Support for the Perl regular expression syntax was added. ncmpcpp-0.6.3 (2015-03-02) diff --git a/doc/config b/doc/config index 56538b7d..43ba779c 100644 --- a/doc/config +++ b/doc/config @@ -432,9 +432,9 @@ # #display_remaining_time = no # -## Available values: none, basic, extended. +## Available values: none, basic, extended, perl. ## -#regular_expressions = none +#regular_expressions = basic # ## ## Note: If below is enabled, ncmpcpp will ignore leading diff --git a/doc/ncmpcpp.1 b/doc/ncmpcpp.1 index 52f0aeba..3672b172 100644 --- a/doc/ncmpcpp.1 +++ b/doc/ncmpcpp.1 @@ -287,7 +287,7 @@ If enabled, bitrate of currently playing song will be displayed in statusbar. .B display_remaining_time = yes/no If enabled, remaining time of currently playing song will be be displayed in statusbar instead of elapsed time. .TP -.B regular_expressions = basic/extended +.B regular_expressions = none/basic/extended/perl Type of currently used regular expressions. .TP .B ignore_leading_the = yes/no diff --git a/src/settings.cpp b/src/settings.cpp index 1574385a..9ef1b23e 100644 --- a/src/settings.cpp +++ b/src/settings.cpp @@ -578,10 +578,12 @@ bool Configuration::read(const std::vector &config_paths) regex_type = boost::regex::basic; else if (v == "extended") regex_type = boost::regex::extended; + else if (v == "perl") + regex_type = boost::regex::perl; else throw std::runtime_error("invalid argument: " + v); regex_type |= boost::regex::icase; - }, defaults_to(regex_type, boost::regex::literal | boost::regex::icase) + }, defaults_to(regex_type, boost::regex::basic | boost::regex::icase) )); p.add("ignore_leading_the", yes_no( ignore_leading_the, false