New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added ability to move and rename files #36
Changes from 10 commits
18c4931
8e98249
7e222b9
bdc5afd
4409ad7
fe3c597
a11d8c7
a1dc212
be8aa02
3c699d7
4a8cbc0
27ce2df
db9d11c
0f4b1d5
3a85c76
540a825
8cbc57b
c41072c
a592721
83b730b
93d44c5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,18 +41,19 @@ public : | |
Drive( Syncer *syncer, const Val& options ) ; | ||
|
||
void DetectChanges() ; | ||
bool Move(); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. And here I think Drive::Move() should take file arguments instead of taking them from Config object... |
||
void Update() ; | ||
void DryRun() ; | ||
void SaveState() ; | ||
|
||
struct Error : virtual Exception {} ; | ||
|
||
private : | ||
void SyncFolders( ) ; | ||
void FromRemote( const Entry& entry ) ; | ||
void FromChange( const Entry& entry ) ; | ||
void UpdateChangeStamp( ) ; | ||
|
||
private : | ||
Syncer *m_syncer ; | ||
fs::path m_root ; | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -117,7 +117,7 @@ bool Entry::IsRemoved() const | |
|
||
std::string Entry::Name() const | ||
{ | ||
return !m_filename.empty() ? m_filename : m_title ; | ||
return !m_title.empty() ? m_title : m_filename; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's a pointless change since recently because m_filename is also copied from title field of json... see #32 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, I did this before you changed it and I just didn't bother to update it after you changed it since it should get the correct result anyway |
||
} | ||
|
||
} // end of namespace gr |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you please use a consistent indenting style? :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, been trying out a new editor and I'm still figuring out how it handles indents. I'll fix this.