Jakob Borg
f6953624dd
lib/model: Test should pass go vet inspections
...
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/2977
2016-04-15 11:41:18 +00:00
AudriusButkevicius
1a5f524ae4
lib/model, lib/protocol: Implement temporary indexes ( fixes #950 )
...
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/2252
2016-04-15 10:59:41 +00:00
Michael Ploujnikov
7533a61203
unifySubs: add two trivial test cases
2016-04-10 02:41:28 +00:00
Michael Ploujnikov
467d338fe4
lib/model: Scanning unknown items is OK as long as the parent is known ( fixes #2915 )
2016-04-09 11:25:06 +00:00
Audrius Butkevicius
4389bb037d
lib/model: Add option for overwriting names on connect ( fixes #2912 )
2016-04-09 07:43:47 +00:00
Audrius Butkevicius
2eb8a9ef56
all: Dead code cleanup
2016-04-09 01:10:31 +00:00
Audrius Butkevicius
5a98af622d
lib/ignore: Implement deletable ignores using (?d) prefix ( fixes #1362 )
2016-04-07 09:34:07 +00:00
Jakob Borg
cc1d122352
lib/model: Correctly detect deleted but previously ignored files as deleted
2016-04-04 11:53:55 +01:00
Jakob Borg
f5f0e46016
lib: Use bytes.Equal instead of bytes.Compare where possible
2016-03-31 15:12:46 +00:00
Michael Ploujnikov
66f480519b
lib/model: Refactor out scanning method from rwfolder.Serve loop
2016-03-30 06:53:47 +00:00
Audrius Butkevicius
b4f9a55e6e
protocol: Add "Hello" message at connection start, also for unauthed peers
2016-03-25 20:29:07 +00:00
Jakob Borg
aba2cc4db2
lib/model: Properly handle deleting multiple files when doing scans with subs ( fixes #2851 )
2016-03-18 12:16:33 +00:00
Jakob Borg
2df001fe5c
lib/model: Correct handling of multiple subs when scanning ( fixes #2851 )
...
Previously the code failed in that it would return top-level plus a sub,
i.e. ["", "foo"], and it would consider "usr/lib" a prefix of
"usr/libexec" which it is not.
2016-03-18 08:28:44 +00:00
Jakob Borg
c439c543d0
tests: messagediff argument order should be expected, actual
...
So that the diff describes the changes that happened in actual as
compared to expected. The opposite is confusing.
2016-03-17 08:03:29 +01:00
Jakob Borg
17517bcc3d
Don't show restart prompt when changing folder label ( fixes #2840 )
2016-03-16 12:18:21 +01:00
Lars K.W. Gohlke
16c3d39fd2
Add folder label in addition to ID ( fixes #966 )
...
An auto generated ID is suggested on folder creation to reduce conflicts with
folders created on other devices.
2016-03-11 09:48:46 +00:00
Audrius Butkevicius
a8ffde6f21
Add deps
2016-03-06 20:32:10 +00:00
Michael Ploujnikov
49601a63c8
Model.internalScanFolder: Don't ignore special .stfolder and .stignore files.
...
Fixes #2151 .
Since Walk.walkAndHashFiles ignores .stfolder and .stignore, they will
never be found by fs.Get(protocol.LocalDeviceID, sub) in
Model.internalScanFolder. As a result, when asked to scan those subs
we end up scanning the whole folder.
2016-01-22 23:27:47 -05:00
Michael Ploujnikov
6c33188af3
Model.internalScanFolderSubs: Scan only requested subs.
...
This reverts the change introduced in 9b9fe0d
Reduce scanning effort.
That commit caused us to automatically ignore the basename of the
specified subs and instead scan closest known root folder. For
example, in a folder that looks like:
Sync/
├── 00
│ ├── one
│ ├── three
│ └── two
├── 01
│ ├── one
│ ├── three
│ └── two
├── 02
│ ├── one
│ ├── three
│ └── two
└── one
calling '/rest/db/scan?folder=default&sub=01' called filepath.Walk on
the whole Sync/ folder instead of just the desired subfolder. This
contradicts the scan behavior promised by the documentation.
This is related to #2151 .
2016-01-22 23:27:38 -05:00
Jakob Borg
11d4986517
Humanize serialization of version vectors (again)
2016-01-20 11:14:08 -08:00
Jakob Borg
6c1faa4bdb
Don't require restart for usage reporting changes ( fixes #2704 )
2016-01-18 10:06:31 -08:00
Jakob Borg
2919b76947
The "OK" log level is silly and should not exist
2016-01-16 23:04:41 +01:00
Jakob Borg
acaf134dfe
Don't crash on folder remove while pulling ( fixes #2705 )
2016-01-16 21:42:32 +01:00
Audrius Butkevicius
c4c6df179b
Handle race within the job queue ( fixes #1263 )
2016-01-16 17:20:21 +00:00
Jakob Borg
8b3d75b339
Undo the hash algorithm additions; retain flag checks
2016-01-12 14:35:00 +01:00
Jakob Borg
acdddc0b79
Don't leak sendIndexes on disconnect ( fixes #2589 )
...
Adds a Closed() method on protocol.Connection and clears up
wireformatConnection a little too.
2016-01-11 17:57:25 +01:00
Jakob Borg
096b2d73cd
Don't conflict copy conflict copies ( fixes #2605 )
2016-01-03 21:16:31 +01:00
Jakob Borg
0db80710aa
Detect nonstandard hash algo and stop folder (ref #2314 )
2016-01-01 20:14:31 +01:00
Audrius Butkevicius
80b9a3e00b
Don't warn about failed ignores if folder unhealthy ( fixes #2630 )
2016-01-01 12:59:13 +00:00
Anderson Mesquita
6d94a3be05
Refactor rwfolder tests
...
This creates a few utility functions to avoid repetition and removes
some redundant checks.
2015-12-22 23:43:07 -05:00
Anderson Mesquita
3f94e70488
WIP: Consider tempfile when checking for free space ( fixes #2598 )
...
Checks the existing blocks that can be reused when downloading a file so
that it only requires the space corresponding to the missing blocks.
This will prevent syncthing from claiming the folder doesn't have enough
space when resuming download of large files after they have been
partially downloaded.
2015-12-21 13:36:08 -05:00
Jakob Borg
03935b2d64
Don't verify free space for files when folder MinDiskFreePct==0 ( fixes #2600 )
2015-12-19 13:59:08 +01:00
Lode Hoste
cc0b9e5088
Additional output on insufficient error (ref #2580 )
2015-12-15 08:45:33 +01:00
Nate Morrison
86e8e5199e
Filenames added to audit log in the LocalIndexUpdated event ( fixes #2549 )
2015-12-04 08:42:00 +01:00
buinsky
05a31c2686
Fix deleting folders on WinXP ( fixes #2522 )
2015-11-30 19:09:36 +03:00
Audrius Butkevicius
4474d200b0
Fix symlinks ( fixes #2524 )
2015-11-28 20:23:08 +00:00
Jakob Borg
d46f267663
Handle sparse files ( fixes #245 )
2015-11-21 17:58:09 +01:00
Jakob Borg
9cf653d673
Rename Model.clusterConfig to Model.generateClusterConfig
2015-11-17 12:10:08 +01:00
Jakob Borg
9fbdb6b305
Cancel a running scan
2015-11-13 15:30:21 +01:00
Jakob Borg
73285cadb6
Remove folder without restart ( fixes #2262 )
2015-11-13 13:32:52 +01:00
AudriusButkevicius
f7edd36931
Use virtualMtime when deciding if a file is up to date
2015-11-12 03:40:06 +00:00
Mike Boone
342036408e
Fix typos.
2015-11-11 21:20:34 -05:00
Zillode
593632045d
Correct commentary for ConnectionStats
...
Related to https://github.com/syncthing/syncthing-android/issues/473 and 944d9c84a0
ConnectionStats returns connection information for all devices, even when disconnected.
2015-11-09 23:58:06 +01:00
Jakob Borg
59565fd1d1
Woops
2015-11-07 11:25:00 +01:00
Jakob Borg
55592137a2
Use constructor functions for FolderConfiguration and DeviceConfiguration
2015-11-07 09:50:04 +01:00
Jakob Borg
686f91777c
Don't force rescan dirs and symlinks
...
We can't look for changed modtime on these as we don't track the modtime
to start with.
2015-11-04 19:53:07 +00:00
Jakob Borg
2a4fc28318
We should pass around db.Instance instead of leveldb.DB
...
We're going to need the db.Instance to keep some state, and for that to
work we need the same one passed around everywhere. Hence this moves the
leveldb-specific file opening stuff into the db package and exports the
dbInstance type.
2015-10-31 12:35:30 +01:00
Jakob Borg
e1a8ea7dec
Rescan changed files before pulling on top of them ( fixes #2416 )
2015-10-29 09:12:37 +01:00
Audrius Butkevicius
5b03c2d949
Remove dead code
2015-10-25 20:46:09 +00:00
Audrius Butkevicius
f629a998a0
Change errNoDevice message to something more human
2015-10-25 13:27:26 +00:00