mirror of
https://github.com/octoleo/syncthing.git
synced 2024-11-17 18:45:13 +00:00
typos and spelling correction
This commit is contained in:
parent
a5e11c7489
commit
32a76901a9
@ -15,7 +15,7 @@ This is the `syncthing` project which pursues the following goals:
|
||||
|
||||
2. Provide the reference implementation to demonstrate the usability of
|
||||
said protocol. This is the `syncthing` utility. We hope that
|
||||
alternative, compatible implementations of the protocol will arrise.
|
||||
alternative, compatible implementations of the protocol will arise.
|
||||
|
||||
The two are evolving together; the protocol is not to be considered
|
||||
stable until syncthing 1.0 is released, at which point it is locked down
|
||||
|
@ -22,7 +22,7 @@ import (
|
||||
)
|
||||
|
||||
// The connection service listens on TLS and dials configured unconnected
|
||||
// devices. Successfull connections are handed to the model.
|
||||
// devices. Successful connections are handed to the model.
|
||||
type connectionSvc struct {
|
||||
*suture.Supervisor
|
||||
cfg *config.Wrapper
|
||||
@ -116,7 +116,7 @@ next:
|
||||
remoteID := protocol.NewDeviceID(remoteCert.Raw)
|
||||
|
||||
// The device ID should not be that of ourselves. It can happen
|
||||
// though, especially in the presense of NAT hairpinning, multiple
|
||||
// though, especially in the presence of NAT hairpinning, multiple
|
||||
// clients between the same NAT gateway, and global discovery.
|
||||
if remoteID == myID {
|
||||
l.Infof("Connected to myself (%s) - should not happen", remoteID)
|
||||
@ -128,7 +128,7 @@ next:
|
||||
// could use some better handling. If the old connection is dead but
|
||||
// hasn't timed out yet we may want to drop *that* connection and keep
|
||||
// this one. But in case we are two devices connecting to each other
|
||||
// in parallell we don't want to do that or we end up with no
|
||||
// in parallel we don't want to do that or we end up with no
|
||||
// connections still established...
|
||||
if s.model.ConnectedTo(remoteID) {
|
||||
l.Infof("Connected to already connected device (%s)", remoteID)
|
||||
|
@ -124,7 +124,7 @@ func monitorMain() {
|
||||
|
||||
case err = <-exit:
|
||||
if err == nil {
|
||||
// Successfull exit indicates an intentional shutdown
|
||||
// Successful exit indicates an intentional shutdown
|
||||
return
|
||||
} else if exiterr, ok := err.(*exec.ExitError); ok {
|
||||
if status, ok := exiterr.Sys().(syscall.WaitStatus); ok {
|
||||
|
@ -132,7 +132,7 @@ func (c *folderSummarySvc) calculateSummaries() {
|
||||
// foldersToHandle returns the list of folders needing a summary update, and
|
||||
// clears the list.
|
||||
func (c *folderSummarySvc) foldersToHandle() []string {
|
||||
// We only recalculate sumamries if someone is listening to events
|
||||
// We only recalculate summaries if someone is listening to events
|
||||
// (a request to /rest/events has been made within the last
|
||||
// pingEventInterval).
|
||||
|
||||
|
@ -47,7 +47,7 @@ syncthing.config(function ($httpProvider, $translateProvider, LocaleServiceProvi
|
||||
|
||||
});
|
||||
|
||||
// @TODO: extract global level functions into seperate service(s)
|
||||
// @TODO: extract global level functions into separate service(s)
|
||||
|
||||
function deviceCompare(a, b) {
|
||||
if (typeof a.name !== 'undefined' && typeof b.name !== 'undefined') {
|
||||
|
@ -12,7 +12,7 @@ angular.module('syncthing.core')
|
||||
// progress the browser on some platforms returns a 200 (since the
|
||||
// headers has been flushed with the return code 200), with no data.
|
||||
// This basically means that the connection has been reset, and the call
|
||||
// was not actually sucessful.
|
||||
// was not actually successful.
|
||||
if (!data) {
|
||||
errorFn(data);
|
||||
return;
|
||||
|
@ -220,7 +220,7 @@ angular.module('syncthing.core')
|
||||
var copiedFromElsewhere = 100 * s.copiedFromElsewhere / s.total;
|
||||
var pulled = 100 * s.pulled / s.total;
|
||||
var pulling = 100 * s.pulling / s.total;
|
||||
// We try to round up pulling to atleast a percent so that it would be atleast a bit visible.
|
||||
// We try to round up pulling to at least a percent so that it would be at least a bit visible.
|
||||
if (pulling < 1 && pulled + copiedFromElsewhere + copiedFromOrigin + reused <= 99) {
|
||||
pulling = 1;
|
||||
}
|
||||
|
@ -27,7 +27,7 @@ angular.module('syncthing.core')
|
||||
$scope.localesNames = availableLocaleNames;
|
||||
$scope.visible = $scope.localesNames && $scope.localesNames['en'];
|
||||
|
||||
// using $watch cause LocaleService.currentLocale will be change after recive async query accpeted-languages
|
||||
// using $watch cause LocaleService.currentLocale will be change after receive async query accepted-languages
|
||||
// in LocaleService.readBrowserLocales
|
||||
var remove_watch = $scope.$watch(LocaleService.getCurrentLocale, function (newValue) {
|
||||
if (newValue) {
|
||||
|
@ -42,7 +42,7 @@ angular.module('syncthing.core')
|
||||
* @returns promise which on success resolves with a locales array
|
||||
*/
|
||||
function readBrowserLocales() {
|
||||
// @TODO: check if there is nice way to utilize window.navigator.languages or similiar api.
|
||||
// @TODO: check if there is nice way to utilize window.navigator.languages or similar api.
|
||||
|
||||
return $http.get(urlbase + "/svc/lang");
|
||||
}
|
||||
|
@ -95,7 +95,7 @@ func TestGlobalDiscovery(t *testing.T) {
|
||||
|
||||
addrs := d.Lookup(device)
|
||||
if len(addrs) != 2 {
|
||||
t.Fatal("Wrong numer of addresses", addrs)
|
||||
t.Fatal("Wrong number of addresses", addrs)
|
||||
}
|
||||
|
||||
for _, addr := range []string{"test.com:1234", "best.com:2345"} {
|
||||
@ -119,10 +119,10 @@ func TestGlobalDiscovery(t *testing.T) {
|
||||
|
||||
addrs = d.Lookup(device)
|
||||
if len(addrs) != 2 {
|
||||
t.Fatal("Wrong numer of addresses", addrs)
|
||||
t.Fatal("Wrong number of addresses", addrs)
|
||||
}
|
||||
|
||||
// Answer should be cached, so number of lookups should have not incresed
|
||||
// Answer should be cached, so number of lookups should have not increased
|
||||
for _, c := range []*DummyClient{c1, c2, c3} {
|
||||
if len(c.lookups) != 1 || c.lookups[0] != device {
|
||||
t.Fatal("Wrong lookups")
|
||||
|
@ -1626,7 +1626,7 @@ func (m *Model) String() string {
|
||||
func symlinkInvalid(isLink bool) bool {
|
||||
if !symlinks.Supported && isLink {
|
||||
SymlinkWarning.Do(func() {
|
||||
l.Warnln("Symlinks are disabled, unsupported or require Administrator priviledges. This might cause your folder to appear out of sync.")
|
||||
l.Warnln("Symlinks are disabled, unsupported or require Administrator privileges. This might cause your folder to appear out of sync.")
|
||||
})
|
||||
return true
|
||||
}
|
||||
|
@ -113,7 +113,7 @@ func (t *ProgressEmitter) Register(s *sharedPullerState) {
|
||||
t.registry[filepath.Join(s.folder, s.file.Name)] = s
|
||||
}
|
||||
|
||||
// Deregister a puller which will stop boardcasting pullers state.
|
||||
// Deregister a puller which will stop broadcasting pullers state.
|
||||
func (t *ProgressEmitter) Deregister(s *sharedPullerState) {
|
||||
t.mut.Lock()
|
||||
defer t.mut.Unlock()
|
||||
|
@ -806,7 +806,7 @@ func (p *rwFolder) handleFile(file protocol.FileInfo, copyChan chan<- copyBlocks
|
||||
reused = len(file.Blocks) - len(blocks)
|
||||
if reused == 0 {
|
||||
// Otherwise, discard the file ourselves in order for the
|
||||
// sharedpuller not to panic when it fails to exlusively create a
|
||||
// sharedpuller not to panic when it fails to exclusively create a
|
||||
// file which already exists
|
||||
os.Remove(tempName)
|
||||
}
|
||||
@ -876,7 +876,7 @@ func (p *rwFolder) shortcutFile(file protocol.FileInfo) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// shortcutSymlink changes the symlinks type if necessery.
|
||||
// shortcutSymlink changes the symlinks type if necessary.
|
||||
func (p *rwFolder) shortcutSymlink(file protocol.FileInfo) (err error) {
|
||||
err = symlinks.ChangeType(filepath.Join(p.dir, file.Name), file.Flags)
|
||||
if err == nil {
|
||||
@ -977,7 +977,7 @@ func (p *rwFolder) pullerRoutine(in <-chan pullBlockState, out chan<- *sharedPul
|
||||
continue
|
||||
}
|
||||
|
||||
// Get an fd to the temporary file. Tehcnically we don't need it until
|
||||
// Get an fd to the temporary file. Technically we don't need it until
|
||||
// after fetching the block, but if we run into an error here there is
|
||||
// no point in issuing the request to the network.
|
||||
fd, err := state.tempFile()
|
||||
|
@ -410,7 +410,7 @@ func TestDeregisterOnFailInCopy(t *testing.T) {
|
||||
|
||||
p.handleFile(file, copyChan, finisherChan)
|
||||
|
||||
// Receive a block at puller, to indicate that atleast a single copier
|
||||
// Receive a block at puller, to indicate that at least a single copier
|
||||
// loop has been performed.
|
||||
toPull := <-pullChan
|
||||
// Wait until copier is trying to pass something down to the puller again
|
||||
|
@ -46,7 +46,7 @@ type Walker struct {
|
||||
BlockSize int
|
||||
// If Matcher is not nil, it is used to identify files to ignore which were specified by the user.
|
||||
Matcher *ignore.Matcher
|
||||
// If TempNamer is not nil, it is used to ignore tempory files when walking.
|
||||
// If TempNamer is not nil, it is used to ignore temporary files when walking.
|
||||
TempNamer TempNamer
|
||||
// Number of hours to keep temporary files for
|
||||
TempLifetime time.Duration
|
||||
@ -387,7 +387,7 @@ func SymlinkTypeEqual(disk, index uint32) bool {
|
||||
// know and someone else knows, just accept it. The fact that you don't
|
||||
// know means you are on Unix, and on Unix you don't really care what the
|
||||
// target type is. The moment you do know, and if something doesn't match,
|
||||
// that will propogate throught the cluster.
|
||||
// that will propagate through the cluster.
|
||||
if disk&protocol.FlagSymlinkMissingTarget != 0 && index&protocol.FlagSymlinkMissingTarget == 0 {
|
||||
return true
|
||||
}
|
||||
|
@ -46,7 +46,7 @@ var correctIgnores = map[string][]string{
|
||||
|
||||
func init() {
|
||||
// This test runs the risk of entering infinite recursion if it fails.
|
||||
// Limit the stack size to 10 megs to creash early in that case instead of
|
||||
// Limit the stack size to 10 megs to crash early in that case instead of
|
||||
// potentially taking down the box...
|
||||
rdebug.SetMaxStack(10 * 1 << 20)
|
||||
}
|
||||
|
@ -46,7 +46,7 @@ func init() {
|
||||
}
|
||||
}()
|
||||
|
||||
// Needs administrator priviledges.
|
||||
// Needs administrator privileges.
|
||||
// Let's check that everything works.
|
||||
// This could be done more officially:
|
||||
// http://stackoverflow.com/questions/2094663/determine-if-windows-process-has-privilege-to-create-symbolic-link
|
||||
|
@ -3809,6 +3809,6 @@
|
||||
],
|
||||
"tarball_url": "https://api.github.com/repos/syncthing/syncthing/tarball/v0.10.26",
|
||||
"zipball_url": "https://api.github.com/repos/syncthing/syncthing/zipball/v0.10.26",
|
||||
"body": "* Silence discovery warnings when v6 not available (#1418, @AudriusButkevicius)\r\n* Make sure we start scanning at an indexed location (#1399, @AudriusButkevicius)\r\n* Add missing translation strings (#1430, @AudriusButkevicius)\r\n* Allow not to limit bandwidth in LAN (#1336, @AudriusButkevicius)\r\n* Remove red if we managed to report to atleast one discovery server (#1427, @AudriusButkevicius)\r\n* Compress only metadata by default (#1374, @calmh)\r\n* Don't yell about discovery listening and resolving (#1418, @calmh)\r\n* Fall back to %AppData% if %LocalAppData% is blank (#1446, @calmh)\r\n"
|
||||
"body": "* Silence discovery warnings when v6 not available (#1418, @AudriusButkevicius)\r\n* Make sure we start scanning at an indexed location (#1399, @AudriusButkevicius)\r\n* Add missing translation strings (#1430, @AudriusButkevicius)\r\n* Allow not to limit bandwidth in LAN (#1336, @AudriusButkevicius)\r\n* Remove red if we managed to report to at least one discovery server (#1427, @AudriusButkevicius)\r\n* Compress only metadata by default (#1374, @calmh)\r\n* Don't yell about discovery listening and resolving (#1418, @calmh)\r\n* Fall back to %AppData% if %LocalAppData% is blank (#1446, @calmh)\r\n"
|
||||
}
|
||||
]
|
||||
|
@ -25,7 +25,7 @@ var tagExp = regexp.MustCompile(`.*~([^~.]+)(?:\.[^.]+)?$`)
|
||||
// Returns the tag from a filename, whether at the end or middle.
|
||||
func filenameTag(path string) string {
|
||||
match := tagExp.FindStringSubmatch(path)
|
||||
// match is []string{"whole match", "submatch"} when successfull
|
||||
// match is []string{"whole match", "submatch"} when successful
|
||||
|
||||
if len(match) != 2 {
|
||||
return ""
|
||||
|
@ -467,7 +467,7 @@ func isTimeout(err error) bool {
|
||||
return false
|
||||
}
|
||||
return strings.Contains(err.Error(), "use of closed network connection") ||
|
||||
strings.Contains(err.Error(), "request cancelled while waiting")
|
||||
strings.Contains(err.Error(), "request canceled while waiting")
|
||||
}
|
||||
|
||||
func getTestName() string {
|
||||
|
Loading…
Reference in New Issue
Block a user