iEntry 10th Anniversary Forum Rules Search
WebProWorld
Register FAQ Calendar Mark Forums Read
Web Programming Discussion Forum Working with an API? Developing a plugin? Writing a Mod or script for your favorite blog, Web 2.0 site or Forum? Welcome.

Share Thread: & Tags

Share Thread:

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 11-19-2008, 08:13 AM
WebProWorld Veteran
 
Join Date: Jul 2003
Location: Spain
Posts: 343
computergenius RepRank 1
Default Subversion Issues

I have a couple of Subversion issues that I could really do with some help with.

One issue is that a complete folder on a site is screwed up within Subversion, and I can't see how to remove it and start again. Currently, I am FTPing without Subversion.

The other is that I want to duplicate some code, and updates to that code, across various sites, and I suspect that Subversion would be ideal for this. The resulting sites would use the same code, and different database data to give different pages..
__________________
Pete Clark
Got any spare time? Anything you need? Barter in Spain at http://BarterWithBart.com
Reply With Quote
  #2 (permalink)  
Old 11-19-2008, 08:32 AM
WebProWorld Veteran
 
Join Date: Aug 2003
Location: Cornwall, UK
Posts: 961
speed RepRank 1
Default Re: Subversion Issues

If you are on Windows then the best client I've found so far is http://tortoisesvn.net/ with that you can browse the repository from the right click content menu in explorer and delete the folder directly from the repository. Once you update the working copy the folder should be removed form the working copy.

You can also operate on the working copy and check it back in, again the right context menu in explorer gives you access to tortoisesvn functions e.g. delete.
Quote:
The other is that I want to duplicate some code
If you have your common code in a repository e.g. http://subversion.example.com/svn/proj/trunk/files and you want that folder to appear in a different projects libs folder then if the target project has the structure:

trunk/src/system/libs/

You can add an svn:externals property to src which would be:

svn:externals system/libs http://subversion.example.com/svn/proj/trunk/files

Now when you checkout/update the target project it will automatically pull files from the external repository.

Paths need to change to match your environment and I really recommend creating a set of test repositories to play with.

The book I like for Subversion is Pragmatic Version Control Using Subversion (http://www.compman.co.uk/scripts/browse.asp?ref=792367) I actually thought it was 3rd Edition now, but that covers externals on page 142
Reply With Quote
  #3 (permalink)  
Old 11-19-2008, 09:22 AM
WebProWorld Veteran
 
Join Date: Jul 2003
Location: Spain
Posts: 343
computergenius RepRank 1
Default Re: Subversion Issues

Quote:
Originally Posted by speed View Post
If you are on Windows then the best client I've found so far is TortoiseSVN | The coolest Interface to (Sub)Version Control with that you can browse the repository from the right click content menu in explorer and delete the folder directly from the repository. Once you update the working copy the folder should be removed form the working copy.
I use Tortoise SVN, seems to work fine!


One of the things that I am not clear about, is the naming of the different sections. There appear to be 3 lots of code:
1) on my computer
2) "stored within SVN"
3) on the live site.

I understand 1 to be "working copy", 2 to be repository, but don't know what the "live site code" is known as within SVN.



I took a copy of the working copy folder, then used TortoiseSVN to "delete". It deleted all the files. But I don't know what to do next.

I would assume that I have to tell the repository that I have made changes, but can't see how to do that. Alternatively, should I just copy the deleted folder back from where I stored it? Then do what?

Of course I need this folder, when SVN deals with it correctly, to appear on the live site.

Last edited by computergenius; 11-19-2008 at 09:23 AM. Reason: spelling
Reply With Quote
  #4 (permalink)  
Old 11-19-2008, 09:36 AM
WebProWorld Veteran
 
Join Date: Aug 2003
Location: Cornwall, UK
Posts: 961
speed RepRank 1
Default Re: Subversion Issues

Quote:
I understand 1 to be "working copy", 2 to be repository, but don't know what the "live site code" is known as within SVN.
The live copy is normally created from an export as then you don't have all the svn folders. However in reality it's only another checkout from the repository, just as though someone on another computer took a copy to work with/use.

If you want a more automated system then read up on hook scripts.
Quote:
I took a copy of the working copy folder, then used TortoiseSVN to "delete". It deleted all the files. But I don't know what to do next.
Once you commit your changes to the repository then your working copy and repository should be in sync, do an update as well to be sure.

Once in sync copy your files back to your working copy without the svn folders and then commit again and the folder should be added back to the repository.

It all depends what errors you get if any as to exactly how you handle it.
Reply With Quote
  #5 (permalink)  
Old 11-19-2008, 09:56 AM
WebProWorld Veteran
 
Join Date: Jul 2003
Location: Spain
Posts: 343
computergenius RepRank 1
Default Re: Subversion Issues

I have added the empty folder back to the working copy. It has a red cross. I click on Tortoise Add, and am told that the .svn file is missing. I am told to execute the "clean up" command. But the clean up command does not appear for this folder.
__________________
Pete Clark
Got any spare time? Anything you need? Barter in Spain at http://BarterWithBart.com
Reply With Quote
  #6 (permalink)  
Old 11-19-2008, 10:30 AM
WebProWorld Veteran
 
Join Date: Aug 2003
Location: Cornwall, UK
Posts: 961
speed RepRank 1
Default Re: Subversion Issues

Run the clean up command against the root of the working copy.
Reply With Quote
  #7 (permalink)  
Old 11-19-2008, 10:45 AM
WebProWorld Veteran
 
Join Date: Jul 2003
Location: Spain
Posts: 343
computergenius RepRank 1
Default Re: Subversion Issues

Yes, I can do that!

Cleanup failed to process the following paths:
- C:\develop4\client7\www
'C:\develop4\client7\www\public\img' is not a working copy directory

This is the folder that I have just deleted, and replaced.

So I removed it again, and then it cleaned up successfully.




But when I add the empty folder via Windows, and try to add via Tortoise, or clean up, I just get an error messages, "Cleanup failed..." or ".svn missing"
__________________
Pete Clark
Got any spare time? Anything you need? Barter in Spain at http://BarterWithBart.com
Reply With Quote
  #8 (permalink)  
Old 11-19-2008, 10:52 AM
WebProWorld Veteran
 
Join Date: Aug 2003
Location: Cornwall, UK
Posts: 961
speed RepRank 1
Default Re: Subversion Issues

You should be able to create the folders in the working copy and add the files inside them.

Then run commit at the top level of the working copy, tick the unversioned files/folders to include.

After that all should be in subversion.

You can also add the folders direct to the repository and update to get them in the working copy.
Reply With Quote
  #9 (permalink)  
Old 11-19-2008, 11:11 AM
WebProWorld Veteran
 
Join Date: Jul 2003
Location: Spain
Posts: 343
computergenius RepRank 1
Default Re: Subversion Issues

Quote:
Originally Posted by speed View Post
You should be able to create the folders in the working copy and add the files inside them.
I have created the folder (via Windows) and added two test files (via Windows)

I cannot TortoiseSVN-Add the folder (error message, the .svn file is missing), nor can I TortoiseSVN-Add the files, as there is no option on right click to do that.



The option of payment for a direct consultation is still on the table!
__________________
Pete Clark
Got any spare time? Anything you need? Barter in Spain at http://BarterWithBart.com
Reply With Quote
  #10 (permalink)  
Old 11-19-2008, 11:19 AM
WebProWorld Veteran
 
Join Date: Aug 2003
Location: Cornwall, UK
Posts: 961
speed RepRank 1
Default Re: Subversion Issues

So when you go to the top most folder of the working copy and do commit don't you get a box appear showing all the files being committed?

At the bottom of the box you need to tick Show unversioned files if not already ticked and then in the list tick the new files to add, enter the comment and click ok.

What errors do you get?
Reply With Quote
  #11 (permalink)  
Old 11-19-2008, 11:21 AM
WebProWorld Veteran
 
Join Date: Jul 2003
Location: Spain
Posts: 343
computergenius RepRank 1
Default Re: Subversion Issues

Quote:
Originally Posted by speed View Post
So when you go to the top most folder of the working copy and do commit don't you get a box appear showing all the files being committed?
The folder with the issues is marked in red as "obstructed"
__________________
Pete Clark
Got any spare time? Anything you need? Barter in Spain at http://BarterWithBart.com
Reply With Quote
  #12 (permalink)  
Old 11-19-2008, 11:51 AM
WebProWorld Veteran
 
Join Date: Aug 2003
Location: Cornwall, UK
Posts: 961
speed RepRank 1
Default Re: Subversion Issues

I don't remember ever having that one.

If cleanup doesn't work, I'd try reverting the files but I doubt that'll work, you could try merging conflicts by hand but again I don't think you'll get very far.

So I think I'd create a 2nd working copy and see if that works. If it does then throw away the current working copy and work from the new working copy.

There's something in the project which is stopping the new files, so I'm hoping that the working copy is corrupted and the repository version is good so making a new working copy will fix it.
Reply With Quote
  #13 (permalink)  
Old 11-19-2008, 12:27 PM
WebProWorld Veteran
 
Join Date: Jul 2003
Location: Spain
Posts: 343
computergenius RepRank 1
Default Re: Subversion Issues

How do I create a 2nd working copy?
__________________
Pete Clark
Got any spare time? Anything you need? Barter in Spain at http://BarterWithBart.com
Reply With Quote
  #14 (permalink)  
Old 11-19-2008, 12:31 PM
WebProWorld Veteran
 
Join Date: Aug 2003
Location: Cornwall, UK
Posts: 961
speed RepRank 1
Default Re: Subversion Issues

Create a folder, right click and SVN checkout, select the repository etc you want to checkout and you should have a 2nd copy.
Reply With Quote
  #15 (permalink)  
Old 12-25-2008, 02:26 PM
WebProWorld Veteran
 
Join Date: Jul 2003
Location: Spain
Posts: 343
computergenius RepRank 1
Default Re: Subversion Issues

A belated thanks to all that, I now it "sort of" working, I just have one folder in the repository that is misbehaving. I think that I will have to remove the folder from the repository, but at the moment, I don't know how to do that.

Thanks for the help.
__________________
Pete Clark
Got any spare time? Anything you need? Barter in Spain at http://BarterWithBart.com
Reply With Quote
  #16 (permalink)  
Old 12-25-2008, 03:05 PM
WebProWorld Veteran
 
Join Date: Aug 2003
Location: Cornwall, UK
Posts: 961
speed RepRank 1
Default Re: Subversion Issues

In the repo browser you should be able to locate the folder and delete it.
Reply With Quote
Reply

  WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
More IE and FF issues! ackerley1 Graphics & Design Discussion Forum 5 03-31-2008 02:07 PM
No wedgies with Subversion 1.4 dutter Web Programming Discussion Forum 0 09-19-2006 01:23 PM
IE For Mac issues ADAM Web Design Graphics & Design Discussion Forum 5 01-30-2006 05:57 PM
css issues (help) frogmanandy Graphics & Design Discussion Forum 14 01-03-2006 04:59 PM
Issues with IE for Mac lioness Graphics & Design Discussion Forum 6 03-03-2005 11:18 AM


All times are GMT -4. The time now is 08:02 PM.



Search Engine Optimization by vBSEO 3.3.0