mirror of
https://github.com/octoleo/syncthing.git
synced 2024-12-23 03:18:59 +00:00
0e67c036bb
This makes the GC runner a service that will stop fairly quickly when told to. As a bonus, STTRACE=app will print the service tree on the way out, including any errors they've flagged.
20 lines
460 B
Go
20 lines
460 B
Go
// Copyright (C) 2014 The Syncthing Authors.
|
|
//
|
|
// This Source Code Form is subject to the terms of the Mozilla Public
|
|
// License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
|
// You can obtain one at https://mozilla.org/MPL/2.0/.
|
|
|
|
package syncthing
|
|
|
|
import (
|
|
"github.com/syncthing/syncthing/lib/logger"
|
|
)
|
|
|
|
var (
|
|
l = logger.DefaultLogger.NewFacility("app", "Main run facility")
|
|
)
|
|
|
|
func shouldDebug() bool {
|
|
return l.ShouldDebug("app")
|
|
}
|