svn - Delete "Deleted" files from local repository -



svn - Delete "Deleted" files from local repository -

how delete files have been deleted repo have not been deleted locally yet?

essentially, i'm writing build script in powershell needs up-to-date changes repo , checkout, there might files deleted repo haven't yet been deleted local checkout. mean, 1 solution delete , clean checkout, that's rather expensive , take long time. svn status , "d" , delete them locally, that's rather tedious. i'd overwrite conflicts , --force checkout files need merged.

is there simple command revert or checkout switch i'm missing?

**edit: there 2 different cases need handle:

part a) in 1 section, need leave modified in working re-create lone , checkout changes aren't conflicts or merged. need never abort, meaning want throw away has problem , maintain working/local copy.

i thinking of using: svn update --accept mine-full --force (note: on root directory , not individual files)

part b) in other section, want overwrite changes , delete files deleted in repo.

i thinking of using: svn update --accept theirs-full --force (note: on root directory , not individual files)

would work? or --force (or --accept) not want using?

my main concern using update abort entire process if there's problem, won't it? --force svn update? doesn't delete unversioned items.

revert isn't need either, it? doesn't delete of unversioned items.

also, doesn't checkout same thing update if there local files? much simpler utilize checkout in case nil exists yet. problem cannot specify --accept parameter svn checkout. suppose test if folder exists , checkout or update accordingly.

for part a, used:

svn update --accept mine-full --force

for part b, did:

step 1:

svn revert $localpath

step 2:

svn update $localpath

step 3 (using powershell + svn status, can done rm -rf grep/sed in *nix):

svn status $localpath --no-ignore | select-string '^[?i]' | foreach-object { [regex]::match($_.line, '^[^\s]*\s+(.*)$').groups[1].value } | remove-item -recurse -force -erroraction silentlycontinue

svn tortoisesvn repository

Comments

Popular posts from this blog

How do I check if an insert was successful with MySQLdb in Python? -

delphi - blogger via idHTTP : error 400 bad request -

postgresql - ERROR: operator is not unique: unknown + unknown -