Skip to content

Feature Request: config.json shortname warning #995

@ben-burns

Description

@ben-burns

I accidentally added a space in my shortname, and it resulted in sox errors likely due to the spaces in the file path inside of combine_wave().

Is it possible to either warn about the space in config.json's shortname or add double quotes around each file path in combine_wave() to help mitigate errors in the event of an accidental space in the shortname?

Something like this in combine_wave() before nchars may help:

// Add double quotes around each file path in the files string
std::ostringstream quoted_files;
size_t pos = 0;
while ((pos = files.find(' ')) != std::string::npos) {
    quoted_files << "\"" << files.substr(0, pos) << "\" ";
    files.erase(0, pos + 1);
}
quoted_files << "\"" << files << "\""; // Add the last file

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions