mirror of
https://github.com/rclone/rclone.git
synced 2025-08-15 16:22:47 +02:00
build: add build tag noselfupdate
Allow downstream packaging to build rclone without selfupdate command: $ go build -tags noselfupdate Fixes #5187
This commit is contained in:
@ -553,7 +553,7 @@ func Main() {
|
||||
setupRootCommand(Root)
|
||||
AddBackendFlags()
|
||||
if err := Root.Execute(); err != nil {
|
||||
if strings.HasPrefix(err.Error(), "unknown command") {
|
||||
if strings.HasPrefix(err.Error(), "unknown command") && selfupdateEnabled {
|
||||
Root.PrintErrf("You could use '%s selfupdate' to get latest features.\n\n", Root.CommandPath())
|
||||
}
|
||||
log.Fatalf("Fatal error: %v", err)
|
||||
|
Reference in New Issue
Block a user