File: sync_remote_repo_on_local_sync_upstream.mdwn

package info (click to toggle)
git-annex 7.20190129-3
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 56,292 kB
  • sloc: haskell: 59,105; sh: 1,255; makefile: 225; perl: 136; ansic: 44
file content (21 lines) | stat: -rw-r--r-- 629 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
I am looking for a short cut for my workflow where I sync a (somewhat) central repo and a few client repos.

So, I sync upstream 

    laptop > git annex sync --content

and ssh to the central repo and run another sync

    server > git annex sync

to bring it up to date so that I can sync/pull it again from my desktop.

Is there an easy way to script/do both steps in one for different protocols? E.g., update a ssh repo and a USB-drive repo when syncing on the local one?

At the moment, I would try to check for all known remotes

    > git remote -v

and depending on the protocol ssh/cd into each for triggering a sync.