mirror of
https://github.com/mawww/kakoune.git
synced 2024-12-28 06:08:05 +03:00
Join highlighter parameters with a '_' to autogenerate their name
This commit is contained in:
parent
1b1119e85c
commit
15bb23865a
@ -771,7 +771,7 @@ const CommandDesc add_highlighter_cmd = {
|
|||||||
throw runtime_error("no parent in path");
|
throw runtime_error("no parent in path");
|
||||||
|
|
||||||
auto auto_name = [](ConstArrayView<String> params) {
|
auto auto_name = [](ConstArrayView<String> params) {
|
||||||
return join(params | transform([](StringView s) { return replace(s, "/", "<slash>"); }), "<slash>");
|
return join(params | transform([](StringView s) { return replace(s, "/", "<slash>"); }), "_");
|
||||||
};
|
};
|
||||||
|
|
||||||
String name{slash.base(), path.end()};
|
String name{slash.base(), path.end()};
|
||||||
|
Loading…
Reference in New Issue
Block a user