Trouble deleting .svn folders in Vista - windows-vista

I do a search on .svn using Explorer in my project directory and they come up fine. But when I try to highlight all the .svn folders in my search results it appears that they are deleted by the dialog but they're stil there. I can't get rid of them!

Why do you want to delete the .svn folders in a working copy?
If you want a "clean" copy of any given tree version, you can easily use SVN Export (available from the Tortoise SVN menu).

Try doing it from the cmd line
I think...
del /F /S *.svn.

You can drag the versioned folder to the destination folder using the right mouse button and when your mouse pointer is over the desired drop location let the button go and select the "SVN export all items here" option from the context menu that pops up. This should copy over both the versioned and unversioned files without the .svn directory. I hope its not some additional application that I installed that gives me this option but maybe you should try it.

Related

Accidentally created a file in Git Bash with touch that can't be deleted, modified, read, or moved (Windows 10). How do I get rid of it?

So I submitted a line on Git Bash "touch README.txt -m '...asdf ... qwer...' " attempting to create a readme file with text inside (I'm obviously new to this haha). The result was an empty README.txt file and a random file titled '...asdf ... qwer...' with filetype "file" that I can't get rid of. When I try to delete or alter it, a window pops up that says "Could not find this item. ... This is no longer located in [location]. Verify the location and try again." The Git GUI doesn't seem to recognize it either and I can't delete the parent directory. Command line deletion (del /r /q "...") was unsuccessful. Tried rebooting as well to see if it disappeared. It is not a hidden file.
What exactly happened here and how do I get rid of it? Thanks!
I had a similar issue trying to delete a file that "no longer existed" on my Windows 10 PC. What worked for me was adding the problem file(s) to an archive and ensuring the option, "Delete files after compression" (or equivalent option) in the archive software was ticked. Once the archive process completed, the problem file disappeared from the folder. I then deleted the archive file and everything was good to go.
To add the file to an archive make sure you have something like 7-Zip or WinRAR installed. Here's an example using 7-Zip:
Right-click the problem file and select "7-Zip" from the context menu followed by the "Add to archive" option.
In the "Add to Archive" dialogue, tick the "Delete files after compression" option.
Select the OK button.
The problem file will disappear and an archive file will appear in your folder in its place (hopefully!).
Delete the archive file.
Hope this works for you too.

cmd line prompt for navigating to only folder in current folder. Windows

Suppose I have a folder called Documents, with only one folder inside, called Projects, as illustrated incredibly below...
Documents
Projects
If I'm in Documents, is there a cmd line prompt which will take me into the only available folder, in this case Projects?
So instead of using
cd Projects
I'm looking for
cd 'only available folder'
Is there a cmd for this?
In response to an answer which was deleted: I'm not looking for a list of folder contents. I'm looking to navigate directly into the only available folder.
I suppose one option is:
cd 'Tab button'
There's not really a simple command for this. Like you suggested, the best solution, and what I would do, is cdspaceTab. Strictly speaking, there is a command that satisfies your requirements, but it's not exactly easy under the fingers.
for /d %I in (*) do cd "%I"
which would loop through all directories in the current directory (ostensibly, only one), then cd to it.

How can I commit a duplicate copy with new folder name into SVN using SCToolbarButton on MAC?

I was trying to copy a folder in SVN with little modification of the files and the folder name itself. I tried to add the new folder, but the a message box which says "the folder is under sub-version control" comes. Which in turn doesn't allow me to commit into SVN.
I tried to change the file modification date of all files in the new folder, but didn't work. Can you please help me?
Thanks
I found the solution and I would like to share it here.
Previously there was a file with an extension of .svn in every folder I wanted to commit and that is why the SVN says "It is already under version control". now I remove them successively for each folder and sub-folder using ls -ls just to see whether the file with .svn is there, and rm -.svn

Unable to rename a group folder in Xcode

I added a new group from selection today in Xcode containing several files. For some reason, this has consisted for a while, I am unable to name or rename the group folder.
Has this happened to anyone else before, if so have you come across a fix?
What have you tried to do in order to rename it?
The contextual menu (right click) does not provide a rename option. Therefore I either
Select the group
Hit return which selects it for editing
OR
Select the group
After a short delay (long enough to not count as a double click) click it again
Sometimes it happens.
Workaround:
Quit Xcode.
Launch Xcode.
Tada
For anyone that has my issue: Check your files in Finder. I had a folder that was already using that name. Delete that folder and it will allow you to change name.
You cannot rename the folder probably because that folder already exists in that directory.
To solve it:
Select the folder you want to rename, press the right button, press show in finder.
Delete the folder(s) that already have the name you want.
Go to Xcode and try again.
Good luck :)
Some times its not related to xcode, its finder problem, because directory still exists and finder doesn't show that, you can see directory exists by entering ls in terminal.
How to solve this?
Open terminal and navigate to parent directory of desired directory : cd ~/../parent or just right click parent directory and choose New Terminal at Folder
Remove desired directory : rm -rf MyGroup
Now you can try to create your group with MyGroup name.

Problem deleting .svn directories on Windows XP

I don't seem to have this problem on my home laptop with Windows XP, but then I don't do much work there.
On my work laptop, with Windows XP, I have a problem deleting directories when it has directories that contain .svn directories. When it does eventually work, I have the same issue emptying the Recycle bin. The pop-up window says "Cannot remove folder text-base: The directory is not empty" or prop-base or other folder under .svn
This continued to happen after I changed config of TortoiseSVN to stop the TSVN cache process from running and after a reboot of the system.
Multiple tries will eventually get it done. But it is a huge annoyance because there are other issues I'm trying to fix, so I'm hoping it is related.
'Connected Backup PC' also runs on the laptop and the real problem is that cygwin commands don't always work. So I keep thinking the dot files and dot directories have something to do with both problems and/or the backup or other process scanning the directories is doing it. But I've run out of ideas of what to try or how to identify the problem further.
You don't need to reboot; just open Task Manager and kill TSVNCache.exe.
This is safe, too. It's designed so you can kill it and it will automatically restart when needed.
(As a result of the auto-restart, note that browsing some SVN folders in Explorer, File-Open dialogs, etc. may cause TSVNCache.exe to restart. Keep an eye on Task Manager.)
Tortoise SVN is great but I have found that TSVNCache.exe can hold on to locks and get in the way at times. (Sometimes justified, sometimes not.) As a result, for some automated scripts I run I include commands to kill TSVNCache.exe as part of the scripts so it doesn't get in the way. That's only worth doing if it's an operation you perform often, though.
You can try a few things:
Since you are getting this error frequently, you can use handle.exe from sysinternals to check which process currently have open handles for the .svn\* directory. If handle utility tells you about any process, try stopping that process and then delete the directories.
Error while deleting from recycle bin: In simple terms, when a file is sent to recycle bin after deleting, it is not actually deleted, rather, a few manipulations are done in directory hierarchy (file system level) to avoid showing the file while browsing content of a folder. So If you happen to resolve the problem mentioned in comment#1, you will not get this error probably.
Cygwin command not working: Running a cygwin command on windows requires (in particular) cygwin1.dll, which is known to be shipped with other programs (eg: CopSsh, some version of svn clients etc...) as well. If there is any mismatch in the version of cygwin1.dll, cygwin commands won't work. Try searching for cygwin1.dll on your computer and try to resolve version conflicts (if any).
did you ever do mkpasswd and mkgroup for cygwin? If you're using cygwin from the command line you are pretty much guaranteed to have file system permissions issues. and you have to read a little to fix it.
http://cygwin.com/cygwin-ug-net/ntsec.html
Try this answer from me. Although it's given for TortioseGit instead of TortoiseSVN, the handling is the same:
disable the status cache (i.e. prevent the TSVNCache.exe from accessing the .svn folders continuously)
delete what you have to delete
enable the status cache to get updated overlays again
I have just experienced this problem (or similar)
I am using tortoise 1.6.7
To fix it I went to 'Tortoise Settings' from the tortoise context menu.
from there select "Icon Overlays" in the tree widget.
In the icon overlays page, I entered the path that was giving me angst into the "exclude paths:"and tortoise no longer holds that directory handle.
This is a directory that is often deleted by a process other than explorer.
Since what it appears that you are trying to do is export the repository from SVN, why not use the export functionality with TortoiseSVN. This removes all .svn directories from the generated 'working copy'.Cmdline: http://svnbook.red-bean.com/en/1.0/re10.html
If you want to delete all sub folders named .svn in windows
then create batch file with this content:
for /f "tokens=* delims=" %%i in ('dir /s /b /a:d *.svn') do (
rd /s /q "%%i"
)
save it in a file del_All_Dot_SVN_Folders.cmd . Run it. Your done.
Thanks to http://www.axelscript.com/2008/03/11/delete-all-svn-files-in-windows/
Remember the above code has .svn whereas the code in the link has only *svn so its better
to have the .svn to not accidentally have undesired effect.

Resources