Modify the 'create view' command of drogon_ctl (#208)

This commit is contained in:
An Tao 2019-08-07 12:55:14 +08:00 committed by GitHub
parent b55d53458c
commit bf9313a164
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -423,7 +423,7 @@ void create_view::newViewSourceFile(std::ofstream &file,
buffer = line;
if (buffer.length() > 0)
{
std::regex re("\\{%[ \\t]*([^ \\t%]*)[^%]*%\\}");
std::regex re("\\{%[ \\t]*(((?!%\\}).)*[^ \\t])[ \\t]*%\\}");
buffer = std::regex_replace(buffer, re, "<%c++$$$$<<$1;%>");
}
parseLine(file, buffer, streamName, viewDataName, cxx_flag);