Make the parser a 2 pass system
- first run parser with --download - then run the exif script - finally run parser without any flags
This commit is contained in:
parent
0727f60927
commit
73533fd0ae
|
@ -137,6 +137,7 @@ int main(int argc, char **argv)
|
|||
if (subjv.IsArray()) {
|
||||
for (auto i = 0; i<subjv.GetArray().Size(); i++) {
|
||||
subjects += subjv[i].GetString();
|
||||
subjects += " ";
|
||||
}
|
||||
std::replace( description.begin(), description.end(), ',', ':');
|
||||
std::replace( description.begin(), description.end(), '\n', ' ');
|
||||
|
@ -175,6 +176,7 @@ int main(int argc, char **argv)
|
|||
}
|
||||
}
|
||||
|
||||
if (!download_mode) {
|
||||
if (is_cc_license) {
|
||||
char exif_file[128];
|
||||
snprintf(exif_file, sizeof exif_file, "%s-%s.jpeg.exif.json", article_id.c_str(), mediaid.c_str());
|
||||
|
@ -254,6 +256,7 @@ int main(int argc, char **argv)
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
out_file1.close();
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue