File: make-svk-dump

package info (click to toggle)
cgit 1.1%2Bgit2.10.2-3%2Bdeb9u1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 31,824 kB
  • sloc: ansic: 179,983; sh: 150,940; perl: 29,466; tcl: 21,429; python: 7,116; makefile: 3,424; lisp: 1,786; php: 120; asm: 98; csh: 45
file content (57 lines) | stat: -rwxr-xr-x 1,185 bytes parent folder | download | duplicates (21)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#!/bin/sh
#
# this script sets up a Subversion repository for Makefile in the
# first ever git merge, as if it were done with svk.
#

set -e

svk depotmap foo ~/.svk/foo
svk co /foo/ foo
cd foo
mkdir trunk
mkdir branches
svk add trunk branches
svk commit -m "Setup trunk and branches"
cd trunk

git cat-file blob 6683463e:Makefile > Makefile
svk add Makefile 

svk commit -m "ancestor"
cd ..
svk cp trunk branches/left

svk commit -m "make left branch"
cd branches/left/

git cat-file blob 5873b67e:Makefile > Makefile
svk commit -m "left update 1"

cd ../../trunk
git cat-file blob 75118b13:Makefile > Makefile
svk commit -m "trunk update"

cd ../branches/left
git cat-file blob b5039db6:Makefile > Makefile
svk commit -m "left update 2"

cd ../../trunk
svk sm /foo/branches/left
# in theory we could delete the "left" branch here, but it's not
# required so don't do it, in case people start getting ideas ;)
svk commit -m "merge branch 'left' into 'trunk'"

git cat-file blob b51ad431:Makefile > Makefile

svk diff Makefile && echo "Hey!  No differences, magic"

cd ../..

svnadmin dump ~/.svk/foo > svk-merge.dump

svk co -d foo
rm -rf foo
svk depotmap -d /foo/
rm -rf ~/.svk/foo