actually I don’t have the modification on the GitHub since im using the SVN.
about the code im using the CMD project I don’t want to use the GUI interface, so I need to send messages to a server about the updates that the client has, the changes are at the cmd.cpp so I added this function
void Cmd::itemCompletedSlot(const SyncFileItemPtr & item)
{
QString fileName = item->destination();
quint64 pSize = item->_previousSize;
quint64 size = item->_size;
std::string fileNameStr = fileName.toUtf8().constData();
auto original = item->_originalFile;
std::string originalStr = original.toUtf8().constData();
auto file = item->_file;
std::string fileStr = file.toUtf8().constData();
///below code is for sending a message through TCP of what was the event that was made to the file, delete, rename or added
csync_instructions_e instruction = item->_instruction;
std::string instructionMessage;
switch (instruction)
{
case CSYNC_INSTRUCTION_REMOVE:
{
instructionMessage = "Deleted";
break;
}
case CSYNC_INSTRUCTION_RENAME:
{
instructionMessage = "Renamed";
break;
}
case CSYNC_INSTRUCTION_NEW:
{
instructionMessage = "Added";
break;
}
}
you can see that I have three events, remove, rename and add, simply I need a way so I can make the events four…remove, rename, add(upload) and add(download), the only thing i saw that can solve this issue this part of code is this line, but i don’t know how to return the value of REMOTE_REPLICA to the nextcloudcmd project