Bump version to 1.0.19

This commit is contained in:
2026-07-09 15:00:40 -04:00
parent 73cad44769
commit 7a70355b6d
3 changed files with 3 additions and 32 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
BINARY=syncserver
VERSION?=1.0.18
VERSION?=1.0.19
GO?=go
LDFLAGS=-s -w -X main.version=$(VERSION) -X main.commit=$(shell git rev-parse --short HEAD 2>/dev/null || echo unknown)
BUILD_FLAGS=CGO_ENABLED=0
+1 -1
View File
@@ -20,7 +20,7 @@ import (
"github.com/syncserver/internal/syncengine"
)
var version = "1.0.18"
var version = "1.0.19"
func main() {
cfgPath := flag.String("config", "", "Path to config.yaml")
+1 -30
View File
@@ -157,29 +157,6 @@ func (r *RsyncRunner) buildArgs(pair *SyncPairConfig) []string {
return args
}
func (r *RsyncRunner) buildRemoteArgs(pair *SyncPairConfig) []string {
var args []string
flags := strings.Fields(pair.RsyncFlags)
args = append(args, flags...)
for _, pattern := range pair.ExcludePatterns {
args = append(args, "--exclude="+pattern)
}
if pair.Direction == "mirror" {
args = append(args, "--delete")
}
if pair.Direction == "pull" {
args = append(args, pair.Dest, pair.Source)
} else {
args = append(args, pair.Source, pair.Dest)
}
return args
}
type RemoteMachine struct {
Host string
Port int
@@ -205,19 +182,13 @@ func (r *RsyncRunner) RunRemote(ctx context.Context, pair *SyncPairConfig, remot
}
sshArgs := []string{
"ssh",
"-i", remote.PrivKey,
"-o", "StrictHostKeyChecking=accept-new",
"-o", "UserKnownHostsFile=" + strings.TrimRight(r.sshDir, "/") + "/known_hosts",
"-p", fmt.Sprintf("%d", remote.Port),
fmt.Sprintf("%s@%s", remote.SSHUser, remote.Host),
}
if remote.DestPrivKey != "" {
sshArgs = append(sshArgs, "bash", "-c", remoteCmd)
} else {
sshArgs = append(sshArgs, "rsync")
sshArgs = append(sshArgs, args...)
}
sshArgs = append(sshArgs, remoteCmd)
cmd := exec.CommandContext(ctx, "ssh", sshArgs...)