view tests/svn/svndump-encoding.sh @ 26103:30be3aeb5344

clone: fix updaterev to update to latest branch changeset (issue4528) Before this patch if clone --updaterev points to branch which head on src repo wasnt in dest repo, clone updated dest repo to default branch. After applying this patch, if changeset from src repo pointing at given branch is not in dest repo, it searches for changeset pointing for given branch locally in dest repo. Lookup in destination repo: 559: uprev = destrepo.lookup(update) is wrapped by try/except block to preserve current behaviour when given revset to -u is not found - it will not fail,but silently update dest repo to head of default branch.
author liscju <piotr.listkiewicz@gmail.com>
date Sun, 30 Aug 2015 11:47:43 +0200
parents 0332f8b44e54
children f3398f1f70a0
line wrap: on
line source

# -*- coding: utf-8 -*-
#!/bin/sh
#
# Use this script to generate encoding.svndump
#

mkdir temp
cd temp

mkdir project-orig
cd project-orig
mkdir trunk
mkdir branches
mkdir tags
cd ..

svnadmin create svn-repo
svnurl=file://`pwd`/svn-repo
svn import project-orig $svnurl -m "init projA"

svn co $svnurl project
cd project
echo e > trunk/é
mkdir trunk/à
echo d > trunk/à/é
svn add trunk/é trunk/à
svn ci -m hello

# Copy files and directories
svn mv trunk/é trunk/è
svn mv trunk/à trunk/ù
svn ci -m "copy files"

# Remove files
svn rm trunk/è
svn rm trunk/ù
svn ci -m 'remove files'

# Create branches with and from weird names
svn up
svn cp trunk branches/branché
echo a > branches/branché/a
svn ci -m 'branch to branché'
svn up
svn cp branches/branché branches/branchée
echo a >> branches/branché/a
svn ci -m 'branch to branchée'

# Create tag with weird name
svn up
svn cp trunk tags/branché
svn ci -m 'tag trunk'
svn cp branches/branchée tags/branchée
svn ci -m 'tag branché'
cd ..

svnadmin dump svn-repo > ../encoding.svndump