summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-10-05 13:02:02 -0500
committerJeff Carr <[email protected]>2025-10-05 13:02:02 -0500
commit7f32363769a10fb2bfdc835ec80e8cb7c167c824 (patch)
tree66dcee96c6375c723732a1f0cc050312a5045cfb
parent4d813225e061e02d5a81f2294c30228fb54e6901 (diff)
rm old codev0.25.59
-rw-r--r--doSync.go79
1 files changed, 0 insertions, 79 deletions
diff --git a/doSync.go b/doSync.go
deleted file mode 100644
index 02fa8b0..0000000
--- a/doSync.go
+++ /dev/null
@@ -1,79 +0,0 @@
-// Copyright 2017-2025 WIT.COM Inc. All rights reserved.
-// Use of this source code is governed by the GPL 3.0
-
-package main
-
-// trys to figure out if there is still something to update
-
-/*
-func doSync() error {
- if argv.Pull.Sync.Clean != nil {
- return doSyncClean()
- }
- if argv.Pull.Sync.User != nil {
- return doSyncUser()
- }
-
- return fmt.Errorf("nothing to do")
-}
-
-func doSyncClean() error {
- log.Printf("todo: fix this?")
- return nil
-}
-
-func doSyncUser() error {
- me.forge.ConfigRill(10, 20)
- if allerr := me.forge.RillRepos(syncDevelBranch); len(allerr) != 0 {
- log.Info("RillFunc() failed", allerr)
- return fmt.Errorf("Rill doSyncUser() error count = %d", len(allerr))
- } else {
- log.Info("Rill syncDevelBranch() ok count =", len(allerr))
- }
-
- argv.Force = true
- if err := doAllCheckoutUser(); err != nil {
- return err
- }
-
- return nil
-}
-
-func syncDevelBranch(repo *gitpb.Repo) error {
- branch := repo.GetDevelBranchName()
- if repo.Exists(filepath.Join(".git/refs/heads", branch)) {
- return nil
- }
- if repo.Exists(filepath.Join(".git/refs/remotes/origin", branch)) {
- cmd := []string{"git", "checkout", branch}
- err := repo.RunVerbose(cmd)
- return err
- }
- cmd := []string{"git", "branch", branch}
- repo.RunVerbose(cmd)
- cmd = []string{"git", "checkout", branch}
- err := repo.RunVerbose(cmd)
- return err
-}
-
-func syncDevelBranches() error {
- all := me.forge.Repos.SortByFullPath()
- for all.Scan() {
- repo := all.Next()
- branch := repo.GetDevelBranchName()
- if repo.Exists(filepath.Join(".git/refs/heads", branch)) {
- continue
- }
- if repo.Exists(filepath.Join(".git/refs/remotes/origin", branch)) {
- cmd := []string{"git", "checkout", branch}
- repo.RunVerbose(cmd)
- continue
- }
- cmd := []string{"git", "branch", branch}
- repo.RunVerbose(cmd)
- cmd = []string{"git", "checkout", branch}
- repo.RunVerbose(cmd)
- }
- return nil
-}
-*/