Skip to content

Commit

Permalink
Ensure graphics are added to TOML
Browse files Browse the repository at this point in the history
  • Loading branch information
artemis-beta committed Jan 19, 2022
1 parent 9a986c4 commit 39775eb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion include/ros_packager.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ class Packager {
QList<QString> doc_files_;
QList<QString> ttb_files_;
QList<QString> img_files_;
QList<QString> graphics_files_;
QList<QString> graphic_files_;
QString toml_file_ = "";
public:
/*! **************************************************************************
Expand Down
7 changes: 7 additions & 0 deletions src/ros_packager.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,13 @@ QString ROSPkg::Packager::buildTOML() {
}
}
stream_ << "]" << Qt::endl;
stream_ << "graphic_files = [";
if(!img_files_.empty()) {
for(const QString& graphic_file : graphic_files_) {
stream_ << "\"" << QFileInfo(graphic_file).fileName() << "\",";
}
}
stream_ << "]" << Qt::endl;
if(year_ > 0) stream_ << "year = \"" << year_ << "\"" << Qt::endl;
if(!factual_.isEmpty()) stream_ << "factual = \"" << factual_ << "\"" << Qt::endl;
stream_ << "author = \"" << author_ << "\"" << Qt::endl;
Expand Down

0 comments on commit 39775eb

Please sign in to comment.