Commit 4a6ba842 authored by Bart van der Velden's avatar Bart van der Velden

Changed occurrences of 'folder' to 'directory' (#53)

parent 242034da
......@@ -48,7 +48,7 @@ enable_testing()
"CMake generation for is not allowed within the source directory!"
"\n Remove the CMakeCache.txt file and try again from another folder, e.g.:"
"\n Remove the CMakeCache.txt file and try again from another directory, e.g.:"
"\n "
"\n rm CMakeCache.txt"
"\n cd .."
......@@ -102,4 +102,4 @@ add_subdirectory(src)
\ No newline at end of file
......@@ -66,7 +66,7 @@ void AddErrorMessage(string& orgMessage, const string& newMessage)
bool HandleCommandLine(
int argc,
char **argv,
vector<fs::path>& folders,
vector<fs::path>& directories ,
fs::path& logFile,
string& message)
......@@ -74,7 +74,7 @@ bool HandleCommandLine(
po::positional_options_description pod;
pod.add("folder", -1);
pod.add("directory", -1);
po::variables_map vm;
fs::path configFile(DefaultConfigFile);
......@@ -155,8 +155,8 @@ bool HandleCommandLine(
cout << "Directories are: \n";
folders = vm["directory"].as< vector<fs::path> >();
for (vector<fs::path>::iterator it = folders.begin(); it != folders.end(); ++it)
directories = vm["directory"].as< vector<fs::path> >();
for (vector<fs::path>::iterator it = directories .begin(); it != directories .end(); ++it)
//cout << "\t" << *it << "\n";
......@@ -42,15 +42,15 @@
\param argc the original argc as received through main()
\param argv the original argv as received through main()
\param folders the folders that were given as argument or read from the configuration file
\param directories the directories that were given as argument or read from the configuration
\param logFile the path to the logfile either as argument or read from the configuration file
\param message an error message when the function returns false
\return True if no errors occurred, otherwise false
bool HandleCommandLine(
int argc,
bool HandleCommandLine(int argc,
char** argv,
std::vector<boost::filesystem::path>& folders,
std::vector<boost::filesystem::path>& directories,
boost::filesystem::path& logFile,
std::string& message);
......@@ -100,7 +100,7 @@ public:
std::string m_date;
std::string m_albumArtist;
std::string m_fileName;
std::string m_folderName;
std::string m_directoryName;
size_t m_fileSize;
unsigned int m_numSamples;
......@@ -167,10 +167,10 @@ int ConnnectToDatabase()
int main(int argc, char **argv)
int retVal = 0;
vector<fs::path> folders;
vector<fs::path> directories;
fs::path logFile;
string errMsg;
if (HandleCommandLine(argc, argv, folders, logFile, errMsg))
if (HandleCommandLine(argc, argv, directories, logFile, errMsg))
......@@ -184,7 +184,7 @@ int main(int argc, char **argv)
HandleMp3 process;
vector<utils::ScanDirPtr> dirScans;
// Start a scanner for each given directory
for (auto it = folders.begin(); it != folders.end(); ++it)
for (auto it = directories.begin(); it != directories.end(); ++it)
BOOST_LOG_TRIVIAL(info) << "Scanning " << *it;
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment