mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
Bug
- Running 'task sync init' was not clearing the existing backlog.data file.
This commit is contained in:
parent
af38b3bb7b
commit
7c356a943c
1 changed files with 4 additions and 0 deletions
|
@ -98,6 +98,10 @@ int CmdSync::execute (std::string& output)
|
||||||
int upload_count = 0;
|
int upload_count = 0;
|
||||||
if (first_time_init)
|
if (first_time_init)
|
||||||
{
|
{
|
||||||
|
// Delete backlog.data. Because if we're uploading everything, the list of
|
||||||
|
// deltas is meaningless.
|
||||||
|
context.tdb2.backlog._file.truncate ();
|
||||||
|
|
||||||
std::vector <Task> pending = context.tdb2.pending.get_tasks ();
|
std::vector <Task> pending = context.tdb2.pending.get_tasks ();
|
||||||
std::vector <Task>::iterator i;
|
std::vector <Task>::iterator i;
|
||||||
for (i = pending.begin (); i != pending.end (); ++i)
|
for (i = pending.begin (); i != pending.end (); ++i)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue