"branch/tag" through Tortoise SVN dialog is forbidden - tortoisesvn

I am facing a problem with TortoiseSVN (my client version is 1.6.16 and the SVNversion is 1.4.6.28521).
The projectA project has the classical architecture, with three folder: trunk, branches and tags.
I have rights to Read and Write from a projectA folders (tags,branches and trunk).
While working in the trunk, there is no issue, everything works fine. The only problem is that when a release time comes (or branching time comes), and I want to create a tag (a branch), I want to use the TortoiseSVN dialog "branch/tag". Then I choose the origin from the trunk or the revision o nthe trunk i need, and choose the "To URL" like "http://..../projectA/tags/v2.0".
After clicking "OK", it will let me know that the access to "http://...../projectA/" is forbidden.
The only solution right now, is to checkout the "projectA/tags" folder to a local folder. Then in this "projectA/tags" folder I will create one new folder with the name of the tag I want to create, and I am able to commit it without any problem.
I don't want to manually create the folder of the tag/branch like this, andwould rather like to use the "branch/tag" feature of TortoiseSVN.
Anyone has an idea about this issue ?

There is a recommendation in Subversion (at least on Windows with TortoiseSVN) to use the same major version as the server. You are allowed to ignore that recommendation, and most of the time, it does not hurt, but here you may have a case where it makes a difference. You should at least check if
the server could be upgraded to 1.6.x XOR
the client (your installation) could be downgraded to 1.4.x
However, your client will ( in the second case ) no longer work with your checkout directories. Branching has changed a lot from version 1.4.x to 1.6.x, so you will face a hard time if you have to use a 1.6.x client with a 1.4.x server.

Related

Where svn store project code?

I spent all day installing the svn server on my virtual debian 7. So now I have working svn server on svn:// and http:// protocols. With the http:// I haven't got any problems, but with the svn:// first I couldn't create a project folder in my repo through Tortoise browser, there was some error: "User cancelled", after this I did it in the console with some command like this one
svn mkdir -m "project folder" svn://svn.host/repo/project
then a message for root password appeared, next svn user name and pass, and the project folder showed up to the Tortoise browser. I did 3 folders trough Tortoise browser: trunk, branches and tags, and I added my local project to the trunk directory. So now everything seems to work fine just when access my repo through console, ftp or http I can see the trunk branches and tags directories. I tried to find them in the linux tree with no success, it is very strange because the project is there in the Tortoise Browser, but not in the repo. Thanks of any good people which can help me to understand whats going on, and sorry for the level of my English still learning.
The subversion repository is basically a database; you won't see the literal names of files and directories if you inspect it directly. This follows from the purpose of subversion: to store the history of every file and folder, including its state at every past revision, and metadata such as log messages, and actions which change the directory structure, such as renames and deletes.
Laying out the repository the same way as the code being stored would be a very inefficient solution for this aim.

Perforce integrate files when target has been moved/renamed

How to integrate a branch back to trunk when files in the trunk have been moved or renamed while files in the branch have been changed?
The question Integrating moved files in perforce explains similar issue in reverse order, i.e. integrating trunk into branch where files have been moved. However, the answer does not help.
I am unable to use p4 integrate -3 in my scenario, and perforce always asks to specify -D or -Dt flag, which if specified, always creates new files instead of merging them into the existing moved files. Note that I am using latest Perforce client 2014.1.
If at all possible I'd recommend upgrading your server; I'm inferring from the fact that you're unable to use "p4 integrate -3" that you're on a fairly old release. With the latest server release the "integrate -3" functionality is enabled by default, without having to use an extra flag or anything, per this blog post:
http://www.perforce.com/blog/130806/quality-life-improvements-renamed-files
Having this functionality is a pretty big deal since it makes the scenario you describe "just work" -- all you have to do is integrate and resolve as normal.
Without that functionality, you have to do some work -- either modify a branchspec to line the current versions of the files up and use that to integrate the content, or manually recreate the same rename operations in the branch so that the files line up normally.
Note that this functionality requires a new server in addition to a new client, so a 2014.1 client on its own (with an old server) won't do the trick -- a server upgrade is necessary. If you're on an old release you'll need to do a restore from checkpoint as part of the upgrade, per the instructions in the administrator's guide:
http://www.perforce.com/perforce/doc.current/manuals/p4sag/chapter.install.html#d0e1167
but I would recommend you don't let that deter you; you'll be getting a lot of improvements. :)

Setup read-only vendor SVN repository as mirror/external within my own repository

Currently I am working on opencart site and I would like to integrate opencarts source into my own SVN (https://github.com/opencart/opencart).
The goal is to be able to make my own customizations to core OpenCart files and then, when a new version of open cart is released, integrate there changes into my local version.
I was thinking of source structure as follows:
/trunk/opencart - my custom version of open cart
/vendor/opencart - the current opencart trunk.
The intended workflow would be to pull the latest open cart from their servers, then perform a local merge into my trunk. Currently, I have been struggling to set this up correctly as I am very new to SVN and TortoiseSVN.
My current setup, is Windows7 running TortoiseSVN 1.8.0, Build 24401 - 64 Bit. On my local server I have Ubuntu 13.04 64bit with svn, version 1.7.5 (r1336830).
I managed to setup repository that I can check into and out of, and created an external reference in vendor folder using externals. But I’m struggling to generate the main trunk from this external data. When I try to branch from vendor/opencart to trunk/opencart, it attempts to generated that branch on https://github.com/opencart/opencart rather than my local server. (This rightly fails as the repository is read only).
If I try to perform a merge in SVN on the empty trunk/opencart folder with vendor/opencart I also get problems as there is lack of ancestry in the trunk folder. I've read multiple sources - some say to use my approach, some say I should be using svnsync.
What is the best/simplest approach? Ideally, I would like SVN to pull the latest source, rather than dumping the source into a separate folder.
Re-read about svn:externals in Subversion
Get Subversion URL for this Git repository (SVN can't directly communicate with Git) - it's "Subversion checkout URL" in sidebar, open it in Repo-browser and select needed subtree for you - it can be some branch or trunk, remember full URL to needed subtree (it can be, f.e., https://github.com/opencart/opencart/trunk/upload)
Define, where in your repository you want to mount external repo (let it be /vendor/opencart URL)
Checkout parent of mount-point (or parent of parent for our case, if parent still doesn't exist) into new unrelated to work, Working Copy
Create in WC root new folder (usual, ordinary, standard) vendor
For folder vendor add new svn-propery svn:externals in TSVN's wizard
Commit changes
Check results
PS: you can see (checkout, inspect) at this URL https://subversion.assembla.com/svn/subversion-troubleshoot-b/trunk as sample of simplest use-case for externals (subdirectory lib in trunk is svn:external to another repository subtree)
PPS: At staring point you trunk can be empty, you merge /vendor/opencart in order to get initial vanilla state of code in trunk for your own changes on top of it

Remove folder synchronized with tortoise svn

I have synchronized a folder with folder in tortoise svn. Now I want to synchronize this folder with another folder in tortoise svn. How to do this. Please guide me
The mechanism in Subversion are a little bit different. You speak here from a checkout, if you work on a local copy. There are two cases here:
You want to work on a different part of the repository:
Checkout that part at a new location locally (so you are able to work in parallel on both).
Switch your current location to the new part of the repository. This will replace all files locally, and you are no longer able to work on both parts in parallel.
The first scenario is normally used. There are some cases where it may be not appropriate:
You have not enough place locally. You should change that first, because you are not able to work anyway.
You are working on a branch, and want to merge some of the changes on the branch on the trunk or another branch. Then a svn switch is the normal way to do that.
Alternatively, you may do a sparse checkout of the common parent of the two folders, and populate only the parts you are interested in.

What happens when SVN isn't used?

I am wondering what happens in SVN when a file is updated directly instead of using SVN? The main reason I am asking is that there was a problem updating the SVN on my machine (windows) when the server (linux) had 2 names that were the same, but different case. I resolved this on the server, but didn't do it through SVN since it won't update correct, but I still get the issue. Do I need to run some kind of command to update it?
Thanks.
EDIT:
I deleted the comflicting file in the working direcotry and wanted to know if doing things directory in the working directory get tracked at all or what needs to be done to resync.
When SVN gets blocked because the repository is more "up to date" than the local checkout, one brain dead foolproof solution is:
Move (or remove) the files that are causing the conflict at the command line (don't use SVN tools to do this, and don't use the GUI if you have tortoise installed).
svn update the repository, which will restore the current copy of the files from the subversion server.
Decide what to do with your cached copies of the old files. Either manually merge them back into the repository, discard them, or remake the changes in the new svn managed files (depending on your needs).
Note that if you move the files into a directory using tortoise, make sure that you move it into a directory that's not associated with ANY SVN project. It's not fun trying to undo the helpful changes tortoise does in thinking your wanting a SVN move to accompany the file system move.
There is no need to run any special commands. If you updated the sources, the next time you will run svn update subversion will seamlessly merge the changes and you will get an uptodate working copy.
If you changed some files, they will appear modified or conflicted depending on the changes made by you and other users.

Resources