Re: Adding existing svn files to new project
Re: Adding existing svn files to new project
- Subject: Re: Adding existing svn files to new project
- From: Brian Zwahr <email@hidden>
- Date: Tue, 8 Dec 2009 13:30:49 -0600
The reason I'm doing this is I was thinking of switching away from my current setup to using Xcode instead. I wanted to give it a try at least. I wouldn't just be managing SCM through Xcode, I would be doing everything (or most) through Xcode.
I tried your steps: made an empty project (didn't add any existing files, just created the project), then added my checked out working directory (with the correct repo selected in the drop down) as a root, and removed the project directory as a root. This showed me a couple of files in the SCM part of the Groups and Files side bar. I saw the same two files in SCM Results. The weird thing is, I haven't changed these files. Is this telling me that my versions are outdated form what's on the server? I'm not used to seeing this ever. I usually only see when my local file has been modified since it was checked out.
However, this is still further than I got before, so I continued on. I still didn't have a file structure anywhere. I proceeded to use 'add existing files' to add the directory (same directory I added as a root) to the project so that I would have a file list. After some time (seemed to be 'not responding') the folder was added. Since then, Xcode has been very slow to use to try out anything else. I managed to open a file and edit it. I saved it, but it did not show up as modified. Not in SCM in the side bar and not in SCM Results.
At this point, I got really frustrated with having to wait 10 or 15 seconds for even a menu to open, so I started looking around for the cause. I found the "Go Offline/Online" options in the SCM menu. What exactly does this do? I was online and went offline thinking maybe that was the cause of the sluggishness. It was not, as Xcode is still very slow with this project open, and now I do not see the two modified files (the ones that aren't really modified) but I do see the one file I did modify in SCM Results and the side bar.
What is going on? Perhaps I don't understand how Xcode's version control works, but it seems to work with the server repository, which could explain the sluggishness and why now that I am offline I don't see the two files that showed up as modified when they weren't. I should probably note that those two files are from an svn external (Zend Framework). Subversion should work with the .svn directories for its information, not the server.
Also, I thought that there is supposed to be a column on the left side of the Groups and Files bar that showed you version control status for files, so that if a file is modified, it has an M to the left of it, etc. I thought I remember seeing screen shots of this. I do not have this column right now. I can see just a list of modified files (sort of, per above) in the SCM part of the Groups and Files bar as well as the SCM Results.
This is all just to try and see if Xcode is a reasonable replacement for my current development environment. This is one step closer (actually getting some sort of feedback from SCM), but if using SCM is going to make Xcode either be extremely slow (lots of color spiral loading mouse cursors) or be non-responsive, its a moot point. I really hate to give up, though, as this is something in which I'm quite interested.
On Dec 8, 2009, at 10:34 AM, Joar Wingfors wrote:
>
> On 7 dec 2009, at 15.23, Brian Zwahr wrote:
>
>> I have a PHP application that I've built using emacs, which is under version control in a subversion repository. I have a working directory checked out, let's say, in ~/svn/app/trunk. When I open said file in emacs (or run M-x svn-status) I get version control information, and when I make a change, the modified state is shown in emacs and I can commit the change from emacs.
>
>
> You maintain a product type that isn't supported by Xcode, and you edit and debug it outside of Xcode. I'm a bit curious as to why you want to manage SCM through Xcode?
>
>
>> I am trying to replicate this in XCode. Here's what I do. I open XCode, start a new "other" (blank) project. I have the subversion repo added to my Repository List in XCode. I check out a copy of trunk (which I shouldn't have to do, since I already have one checked out for working in emacs, but I figured I'd start fresh doing *everything* in XCode). So now I have a checked out working directory and a new, blank XCode project.
>
>
> You certainly would not have to check out the project from Xcode. There's nothing special in how Xcode checks out projects from SCM.
>
>
>> No matter what I do, I cannot get the working directory into the project in such a way that I get version control information or functionality. For instance, if I add existing files to the project and select the trunk directory, I get the trunk directory structure and files in the left bar of XCode (adding by reference, not copying), but I see no svn information (modified, added, etc). If I set up a root to the trunk directory and select the correct repo from the repository list to go with it, I still do not get version control information or abilities (diff, commit, update, etc).
>
>
> You would not have to add your directories and files to Xcode to get SCM working. I think that it would make more sense for you not to, if you're not already using Xcode to manage your project and files.
>
>
>> So, what I'm asking is do I have to add the whole project and project directory just get see the version control information of any files (even if they are already in a checked out working directory)?
>
>
> I made a simple test this morning, and it worked just like I thought & hoped it would:
>
> * Created a new project from the "empty project" template in Xcode 3.2.1
> * Added a new project root for an already checked out working copy elsewhere on disk
> * Removed the original SCM entry that pointed to the project directory
>
> As soon as I had done that, I got status for the files in that working copy showing up both in "SCM > SCM Results" and in the SCM smart group in the Groups & Files pane. This shows that you do not have to have the project file checked in for SCM support to function. Not sure why this wouldn't work for you, but it seems to suggest that there's something that you're not doing that you should, or something that you're doing that you shouldn't...
>
>
> j o a r
>
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden