Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

Svn Tools - Fast and easy version control from inside your Unity editor

Discussion in 'Assets and Asset Store' started by Visual-Design-Cafe, Jun 29, 2015.

  1. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    You can choose in the preferences when you want to lock files. Depending on your workflow it can be useful to lock prefabs, scenes or other assets when you open them. If 2 users open the same file and work on it for a few hours without saving the progress in between, then the file is not marked as modified until the progress is saved.

    For example:
    9:00am: User A opens scene 1 to edit it
    9:30am: User B also opens scene 1 to edit something (User A has not saved the scene yet, so the file is not locked)
    10:00am: User B finishes editing the scene and saves it. Svn Tools automatically locks the scene because it is modified.
    10:30am: User A finishes editing the scene and tries to save it. However the scene is now already locked by User B and therefore no changes can be made to the scene. Resulting in User A having to break the lock and possibly having a conflicted scene because it was modified by User B at the same time.

    To prevent this scenario it is possible to lock assets when you open them. You can choose to do this automatically or to display a dialog asking the user if you want to lock the file before opening it. Because this is not a problem for all file types (usually not a problem when editing prefabs) you can choose the lock behavior for every file type:
     
    Novack likes this.
  2. Project-Mysh

    Project-Mysh

    Joined:
    Nov 3, 2013
    Posts:
    223
    Hi there Visual Design,

    Lock files is not working for me. File types are set to "everything" and lock files on open is set to "Always".
    In editor is showing the lock icon, but on the explorer is not. I think is something related to Tortoisesvn or some configuration on the Subversion server. Commit and update is working perfectly, only the Lock files is not working.
    Tested with 3 diferent computers with the same repository.
    You have any solution for this?

    Edit: With TortoiseSVN->RepoBrowser I can see the locked files on the server and the user who locked it, but its not locking the files on the PC itself. Dunno what is worng here.

    When I edit this supposedly locked file in Unity, save it, and then try to commit, this error shows on the console:
    svn: E200009: One or more locks could not be obtained
     
    Last edited: Jan 29, 2016
  3. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    Hi Project Mysh,

    That is a really strange problem, I don't have a direct solution so can you please check the following:

    1. Can you try to run a Cleanup command on the root of your project/repository using TortoiseSVN?

    2. Can you enable debug messages? You can do this in the preferences window (Edit/Preferences/Svn Tools) under the 'Debug' tab if you set the debug filter to 'low'. This will print all error messages and warnings from SVN to the console. There can be quite a lot of them because some commands fail on purpose (like status checks on unversioned items), so please look for a message that starts with 'SVN Lock failed'. This message should contain all the information if the lock fails.

    3. Does locking work if you directly lock the file in explorer using TortoiseSVN?
     
  4. Project-Mysh

    Project-Mysh

    Joined:
    Nov 3, 2013
    Posts:
    223
    Here it is a visual description of my problem:

    Computer 1 with user1:
    Locking TestSvn.cs with SVN tools in unity. (debug set to low, no errors on console):
    Pc1 Unity.jpg
    Cheking with TortoiseSVN ( there is no lock icon, but actually TortoiseSVN knows that the file is locked because there is "release lock" option) :
    Pc1 Tortoise.jpg
    Cheking with Repo-browse actually says that the server knows that this file is locked:
    Pc2 Repo.jpg

    Computer 2 with user2:
    Even using Refresh like 5 times is not showing any lock icon (check before open is enabled, but when I open the script there is no advise of the lock, no errors on console):
    Pc2 Unity.jpg
    TortoiseSVN is showing that the script is unlocked because I can lock it (even after checking for modifications):
    Pc2 Tortoise.jpg
    But when i check with Repo-browser... It actually says that the script is locked!:
    Pc2 Repo.jpg

    This is so confusing.... I wanted to use this plugin for the auto-lock feature, but its not working for me.

    P.D: Using TortoiseSVN 1.9.3 on Subversion 1.9.3. Unity 5.3.2f1

    Edit: The tortoiseSVN not showing overlay icons is about the 15 icon overlay limitation of windows

    Edit2: When I open the script on the computer 2, the console says that I cant lock the file because is locked by user1, but it actually lets me open the script, edit and save it creating a conflict. Any way that SVN tools force to not open the script if it is locked?
     
    Last edited: Jan 29, 2016
  5. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @Project Mysh,
    Thank you for sending the detailed description. It took a while to find the cause of this error but I managed to reproduce it and found the solution. The cause is a small typo in the source code where Svn Tools would check the working copy lock instead of the repository.
    A fix has been made and will be submitted to the Asset Store soon, it should be available around the end of this week. If you are in a hurry then please send me an email at support@visualdesigncafe.com with your invoice number and I can send you the updated version by mail. I am sorry for any inconvenience this bug has caused you.
     
  6. dpolyakov

    dpolyakov

    Joined:
    Dec 18, 2015
    Posts:
    16
    Why files that were moved are not deleted from the original place?

    Here is a scenario:
    1) add a file to Asset directory, let's say texture.png
    2) SVN: add, commit
    3) create folder: Textures
    4) move texture.png to Textures
    5) SVN: add, commit on Textures
    File is moved and original deleted from Asset root directory, BUT it still exists in SVN repository in Asset root. Is there any option to make a clean move?
     
  7. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @dpolyakov
    The file you moved should be marked as deleted in the asset root directory automatically. However you will still have to commit the asset folder to make sure the files are also deleted in the repository, so if you only commit the newly added files/folder then the deleted files will stay in the repository until you commit the asset folder. Svn Tools does not automatically commit any changes for you to not make a mess of your log.

    The deleted asset will be removed when committing the asset folder (tested your scenario with 'material.mat' and 'materials' folder):
     
  8. Project-Mysh

    Project-Mysh

    Joined:
    Nov 3, 2013
    Posts:
    223
    My problem solved with the new update!

    Thank you!
     
  9. Project-Mysh

    Project-Mysh

    Joined:
    Nov 3, 2013
    Posts:
    223
    With this new update you have send to me, I have noticed performance issues after 1 or 2 hours of work. Project becomes more and more slow (is progressive) when open/edit/save/add etc...
     
  10. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @Project Mysh
    Thank you for letting me know, I will run a few performance tests before submitting this new version to the store
     
    Project-Mysh likes this.
  11. Project-Mysh

    Project-Mysh

    Joined:
    Nov 3, 2013
    Posts:
    223
    Another bug happens when disabling auto bake lighting on a scene and do manual bake:

    Svn Tools: SVN Add failed: E150002: Entry already exists
    svn: warning: W150002: '\Project Mysh SVN\Assets\0_Mysh\Escenas\Prefab\PrefabCons\LightingData.asset.meta' is already under version control
    svn: E200009: Could not add all targets because some targets are already versioned
    svn: E200009: Illegal target for the requested operation

    Seems that dont recognize the new "LightingData.asset.meta" as new.
     
  12. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @Project Mysh
    Thank you for reporting the bug. It should be fixed in the new version that has been submitted to the asset store. It has been submitted last Friday, so it should be available soon.
    The bug itself should not cause any issues, it means that the asset has already been added. Sometimes the 'add' command is executed twice on the same item when a change was made during a status check. Therefore the second add is unnecessary and can be ignored, Subversion will return this as a W150002 error message. In the version currently pending review this error message is properly handled by Svn Tools.
     
    Project-Mysh likes this.
  13. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    Version 1.1.2 has been accepted and is now available for download! The most important fixes are for the lock functionality and error handling. Please take a look at the change log for all changes made: https://www.visualdesigncafe.com/products/svntools/changelog/

    Edit
    The meta file for the SvnTools.dll file has not been included in the latest version, therefore you will receive an error when trying to build your project. A new version will be submitted as soon as possible to fix this.

    For everyone who is getting this error, please select the SvnTools.dll file in your project view. When selected you can change the import settings in the inspector, please make sure only the toggle for 'Editor' is on. (see screenshot below)
    I am sorry for the inconvenience this has caused to anyone.

    Edit 2
    A new version with a fix (1.1.2f1) is now available for download on the Asset Store. The fix is currently only available for Unity 5. If you are using Unity 4 and are experiencing any build problems, please send an email to support@visualdesigncafe.com with your invoice number and you will receive the latest update by mail. An updated version for Unity 4 should be available on the Asset Store around the end of next week, depending on the speed of the submission process by the asset store team.

    Edit 3
    Version 1.1.2f2 is now available on the Asset Store with all build issues fixed.

     
    Last edited: Mar 2, 2016
  14. erictang

    erictang

    Joined:
    Jul 28, 2012
    Posts:
    15
    external feature not work well
     
  15. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @erictang
    Hi, what is not working for you? Is there a specific thing that is not working, or is the entire external feature not working for you? If you can provide me with a few more details then I will take a look at it for you.
     
  16. erictang

    erictang

    Joined:
    Jul 28, 2012
    Posts:
    15
    upload_2016-2-23_10-30-9.png FX is external folder,but it shown just like unversioned..I have already tick the external option in Unity Preference,and then refresh,
     
  17. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @erictang
    Svn Tools is directly showing the External status returned by Subversion, so if it shows as unversioned then it is likely that there is a problem with Subversion instead. Can you try the following:

    1. Enable debug messages in the preferences: Edit > Preferences > Svn Tools, scroll down to 'debug' and set 'debug filter' to low. This will show any error messages and warnings that may cause the problem.

    2. Please make sure the external definition is working. Can you try to update/commit to see if the external folder is working properly in SVN. The external should show up in the commit/update window as: commit_update_externals.jpg

    3. Please make sure you have the latest version of Subversion and Svn Tools installed.
     
  18. erictang

    erictang

    Joined:
    Jul 28, 2012
    Posts:
    15
    I think I know what happened.For convenience to review and edit svn property, I store it in the root directory of the project.so it can't work.right?
     
  19. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @erictang
    The external definition should be on the parent folder of the location where you want the external folder to be created. So if you want an external folder inside your Assets, you should create the external property on the 'Asset' folder.
    See the screenshot for an example of the external definitions of the actual Svn Tools project:
    externaldefinition.jpg
     
  20. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    Version 1.1.2f2 has been released on the Asset Store. All issues regarding creating builds have been fixed in this version.
     
  21. anarchy54

    anarchy54

    Joined:
    Sep 6, 2012
    Posts:
    1
    I have problem in Unity 5.3.3p2. Log as decribed below.

    InvalidOperationException: The following game object is invoking the DontDestroyOnLoad method: Svn Tools. Notice that DontDestroyOnLoad can only be used in play mode and, as such, cannot be part of an editor script.
    VisualDesignCafe.Editor.VersionControl.VersionControlSystem.GetCreateContainer ()
    UnitySvnTools.SvnToolsUtility.get_VersionControlSystem ()
    UnitySvnTools.SvnTools.Initialize ()
    UnitySvnTools.SvnTools.OnEditorUpdate ()
    UnityEditor.EditorApplication.Internal_CallUpdateFunctions () (at C:/buildslave/unity/build/artifacts/generated/common/editor/EditorApplicationBindings.gen.cs:217)

    InvalidOperationException: The following game object is invoking the DontDestroyOnLoad method: CoroutineUtility. Notice that DontDestroyOnLoad can only be used in play mode and, as such, cannot be part of an editor script.
    VisualDesignCafe.Editor.CoroutineUtility.GetContainer ()
    VisualDesignCafe.Editor.Analytics.AnalyticsSystem.SendAll ()
    UnitySvnTools.SvnTools.OnEditorUpdate ()
    UnityEditor.EditorApplication.Internal_CallUpdateFunctions () (at C:/buildslave/unity/build/artifacts/generated/common/editor/EditorApplicationBindings.gen.cs:217)

    Seems to be.. http://issuetracker.unity3d.com/iss...-makes-gameobject-to-disappear-from-hierarchy
     
  22. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @anarchy54
    Thank you for reporting the problem. A new version has been submitted last Friday with quite a lot of changes. It has been tested in Unity 4.5.3, 5.0.0, 5.3.1 and 5.3.3 but the problem you are experiencing could not be found, even though DontDestroyOnLoad is still being used. I will run a few extra tests to make sure the problem is fixed, or submit a new version if I manage to reproduce the problem.
     
    GoGoGadget likes this.
  23. GoGoGadget

    GoGoGadget

    Joined:
    Sep 23, 2013
    Posts:
    717
    Had this issue before updating to the latest SVN tools version, and still have it after updating, tried resetting SVN tools preferences, reinstalled my SVN client (latest tortoiseSVN), it still shows up as soon as I load/enter playmode in a scene (happened on 5.3.3 and also happens on 5.3.4):

    Code (CSharp):
    1. ArgumentNullException: Argument cannot be null.
    2. Parameter name: key
    3. System.Collections.Generic.Dictionary`2[System.String,VisualDesignCafe.Editor.VersionControl.FileInfo].set_Item (System.String key, VisualDesignCafe.Editor.VersionControl.FileInfo value) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:155)
    4. VisualDesignCafe.Editor.VersionControl.VersionControlCache.Deserialize (System.Collections.Generic.List`1& serializedCache)
    5. VisualDesignCafe.Editor.VersionControl.VersionControlSystem.OnAfterDeserialize ()
    6. VisualDesignCafe.Editor.VersionControl.VersionControlSystem.GetCreateContainer ()
    7. UnitySvnTools.SvnToolsUtility.get_VersionControlSystem ()
    8. UnitySvnTools.SvnTools.Initialize ()
    9. UnitySvnTools.SvnTools.OnEditorUpdate ()
    10. UnityEditor.EditorApplication.Internal_CallUpdateFunctions () (at C:/buildslave/unity/build/artifacts/generated/common/editor/EditorApplicationBindings.gen.cs:217)
    Edit: and also just managed to get this spammed in my editor (After doing seemingly nothing, just exited playmode):
    Code (CSharp):
    1.  
    2. MissingReferenceException: The object of type 'CoroutineUtility' has been destroyed but you are still trying to access it.
    3. Your script should either check if it is null or you should not destroy the object.
    4. UnityEngine.MonoBehaviour.StartCoroutine (IEnumerator routine) (at C:/buildslave/unity/build/artifacts/generated/common/runtime/UnityEngineMonoBehaviourBindings.gen.cs:60)
    5. VisualDesignCafe.Editor.Analytics.AnalyticsSystem.SendAll ()
    6. UnitySvnTools.SvnTools.OnEditorUpdate ()
    7. UnityEditor.EditorApplication.Internal_CallUpdateFunctions () (at C:/buildslave/unity/build/artifacts/generated/common/editor/EditorApplicationBindings.gen.cs:217)
    8.  
     
    Last edited: Mar 16, 2016
  24. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @GoGoGadget
    Thank you for reporting the bug, that is definitely a strange one. The functionality has been implemented since the very first version of Svn Tools and there has never been any problem with it. The first one should be easy to avoid (although I can't tell for sure it will solve the actual cause of the problem), the second one really puzzles me... Everything has been tested in version 4.5.3, 5.0.0, 5.2.3, 5.3.0 and 5.3.3 and I can't reproduce the bug anywhere. Can you send me an email at support@visualdesigncafe.com with a few more details, then I can send you a modified version by mail to see if it will fix your problems:

    1. Your installed version of Svn Tools (I assume you meant 1.1.3 with 'the latest version')
    2. How often do you see this exception? Does it show every time you enter playmode?
    3. Do you have any other third party tools in your project?
    4. Are you using the full version or the Lite version?
     
    wolfen231 likes this.
  25. GoGoGadget

    GoGoGadget

    Joined:
    Sep 23, 2013
    Posts:
    717
    So, just isolated the issue with those two errors - there was a gameobject in the scene with the "CoroutineUtility" component on it, which I think got added after I updated my project from U 5.2 to 5.3. Now, those errors are gone, but there is a new error, the exact same one that @anarchy54 is describing. Should there be a GameObject in the scene with a "VersionControlCacheContainer" component attached? That seems to be what's triggering it, and it gets auto-instantiated every time I reopen the project, even if I've previously deleted it.
     
  26. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @GoGoGadget
    Yes, those GameObjects should exist (although they should not be visible in your hierarchy). The VersionControlCacheContainer is used to serialize the internal cache whenever you enter/exit playmode or recompile any scripts. Without it you will lose the entire cache, and you will have to hit refresh every time. The CoroutineUtility is used to execute any coroutines in edit mode (when checking for new updates, for example). The error that @anarchy54 described and you are having now should be fixed in the latest version (the fix is already available for the Lite version, the full version will be available within a few days).
     
    GoGoGadget likes this.
  27. GDevTeam

    GDevTeam

    Joined:
    Feb 14, 2014
    Posts:
    70
    I've setup a new project and am using Unity 5 Pro with SVN Tools (Paid version).

    I'm seeing the following Error in the Console in Unity.

    Anything I need to do, or is this something that needs to be fixed by the SVN Tools author?

    1. ArgumentNullException: Argument cannot be null.
    2. Parameter name: key
    3. System.Collections.Generic.Dictionary`2[System.String,VisualDesignCafe.Editor.VersionControl.FileInfo].set_Item (System.String key, VisualDesignCafe.Editor.VersionControl.FileInfo value) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:155)
    4. VisualDesignCafe.Editor.VersionControl.VersionControlCache.Deserialize (System.Collections.Generic.List`1& serializedCache)
    5. VisualDesignCafe.Editor.VersionControl.VersionControlSystem.OnAfterDeserialize ()
    6. VisualDesignCafe.Editor.VersionControl.VersionControlSystem.GetCreateContainer ()
    7. UnitySvnTools.SvnToolsUtility.get_VersionControlSystem ()
    8. UnitySvnTools.SvnTools.Initialize ()
    9. UnitySvnTools.SvnTools.OnEditorUpdate ()
    10. UnityEditor.EditorApplication.Internal_CallUpdateFunctions () (at C:/buildslave/unity/build/artifacts/generated/common/editor/EditorApplicationBindings.gen.cs:217)

    Thanks for any help offered.
     
  28. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    Hi @UnityDesingingDev,

    The error you see in the console is a known issue and is caused by a small change in the latest version of Unity.This error has already been fixed and a new version of Svn Tools was submitted last week. Unfortunately it takes a few days until the new version is available for download on the store. You should be able to download it somewhere this week.

    Svn Tools should work properly even with this error, it only prevents the cache from being loaded after exiting play mode. To load the cache you can manually click 'Refresh' in the menu (right click in project view > Svn > Refresh), make a small change or wait until the cache is refreshed automatically.
     
  29. hoesterey

    hoesterey

    Joined:
    Mar 19, 2010
    Posts:
    558
    Hi,
    Having a really nasty issues when trying to check in a scene file. Thus far I've never been able to check one in and have had to duplicate/rename the file then add it. I've had this happen with two separate scene files now.

    Whenever I try to commit a modified scene file from either unity or explorer I get the following error:
    Commit failed (details follow):
    FIle: C:\Root\Bloodpunk\trunk\Assets|Game\Scene\Demo.unity is locked in another working copy
    '/bloodpunk'/!svn/txr/253-81/trunk/Assets/Game/Scene/Demo.unity': no lock token available.
    Additional errors:
    PUT of '/bloodpunk'/!svn/txr/253-81/trunk/Assets/Game/Scene/Demo.unity': 423 Locked

    I was able to get around the issue once by clicking commit, then stealing the lock from myself, and then releasing it. Odd that the server seams to think another user has the lock. Thoughts?
     
  30. Zajoman

    Zajoman

    Joined:
    May 31, 2014
    Posts:
    10
    Hey guys! Thank you for this handy plugin!

    I'm trying out the Lite version, and got a question. I read in some posts (link) that:

    Previously, a few prefabs in our project got corrupted thanks to this! A couple of times my colleagues here switched to Unity while still updating.

    How is this handled in the plugin?

    Thank you!
     
  31. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @hoesterey
    It is a strange bug that pops up occasionally, as far as I know it is an issue with Subversion itself. You can try a few things to prevent this from happening, although none of these will necessarily prevent the bug or fix it immediately:
    - Try to run a Cleanup on your project root.
    - Make sure you only have 1 active user in your TortoiseSVN/Svn Tools. You can directly enter your credentials in the preferences window to make sure the right user credentials will be used.
    - Usually a cleanup will fix most problems with SVN, however as a last resort you can try to remove your working copy and checkout your project again.

    @Zajoman
    There is not much that can be done to prevent this problem. It is possible to lock all asset imports in Unity, however that functionality of Unity is very sensitive to bugs and crashes. If you accidentally switch to Unity and something gets corrupted you can usually execute a Revert command on the corrupted files to restore them.
     
  32. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @UnityDesingingDev, @GoGoGadget, @anarchy54, and everyone else:
    A new version of Svn Tools is available for download with a fix for the 'DontDestroyOnLoad' exception and 'NullReferenceException' when exiting play mode. The version number itself has been kept the same because no big changes were made besides removing the DontDestroyOnLoad.
     
    GoGoGadget likes this.
  33. INCLUDES

    INCLUDES

    Joined:
    Nov 25, 2015
    Posts:
    1
    Hi, Thank you for good plugin.
    I have some problem in my project, I bougt it and installed.
    But I cant't use this plug in. Because It's not support SSH Protocol.
    Actually My svn repository use by SSH protocol.
    How can I use SSH protocol in this plug in?

    Thank you.
     
  34. GDevTeam

    GDevTeam

    Joined:
    Feb 14, 2014
    Posts:
    70

    UPDATE - (tested 2021 hours Eastern Time Zone, U.S.) - ISSUED FIXED

    The issue is now gone after your fix was updated through the Asset Store.

    Thanks for being timely on the fix. I've been pleased with your asset so far.
     
  35. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    Hi @INCLUDES,

    The SSH protocol works in some cases and doesn't in some other cases. Svn Tools uses the standard command line client of Subversion, so there is no specific reason for Svn Tools not working. You should however, input your credentials in the preferences window. Because the command line is executed in the background and any popups are blocked, so it might fail to connect because your credentials are incorrect.

    @UnityDesingingDev
    Thank you, good to hear that everything works for you!
     
    GDevTeam likes this.
  36. arkdzo

    arkdzo

    Joined:
    Oct 22, 2013
    Posts:
    9
    need help:
    1) download some new files, for example: assets\gold\coin.png
    2) replace this folder with file to assets\art\gold\coin.png
    3) Click to SVN-Commit... Check all values, click submit:
    4) Error:
    Error: 'D:\Project\Assets\gold' is scheduled for addition, but is missing
     
  37. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    HI @arkdzo,

    The problem is that the old folder was not properly removed from version control when it was moved, Svn Tools should do this automatically but sometimes it can fail when the cache is being refreshed or Subversion itself fails. If you just want to quickly fix this then you can remove (undo add) the assets in your commit window. The 'Assets\gold' folder should be listed there as 'added', you can right-click on it and 'undo add' or 'delete' to remove it.

    If you can tell me in what order you moved these files exactly, and when this happens then I can do my best to improve this functionality. I tried to reproduce your problem here, but everything seems to work just fine on my end.
     
  38. arkdzo

    arkdzo

    Joined:
    Oct 22, 2013
    Posts:
    9
    thanks, i'll try...
    my reproduce for this bug:
    1) Import any Unity Package from assetstore
    2) In Project Window replace imported folder through drag n drop to another folder.
    3) Click SVN-Commit to main Assets\ folder, check all items, then click Submit
    4) Error...
     
  39. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @arkdzo, Thank you, I will take a closer look at it this weekend.

    For everyone using Svn Tools: there are two known small issues at the moment:
    • Files that are locked by another user are sometimes shown as being locked by yourself.
    • The Move window gives an invalid path error for no apparent reason when typing or choosing a new path.
    A new version will be submitted this weekend to fix these errors, it should be available for download somewhere next week (depending on the review time by the Asset Store team).
     
  40. arkdzo

    arkdzo

    Joined:
    Oct 22, 2013
    Posts:
    9
    downlaod new update. When downloaded new assets and than it replaced to another folder error:
    Svn Tools: SVN Revert failed: E155038: The operation cannot be performed with the specified depth
    svn: E155038: Try 'svn revert --depth infinity' instead?
    svn: E155038: Can't revert 'D:\...\Assets\HD Scifi Level Kit' without reverting children
     
  41. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @arkdzo,
    Thank you for reporting the bug, I also found this error myself. Luckily it is not directly a problem, it happens when a folder is marked as added and then gets removed/deleted. Svn Tools tries to revert the folder (to undo the add) but this is not possible if the folder has children that are also marked as added. I will push a new fix as soon as possible so this error gets handled properly.

    When this happens, all files should still be removed automatically in the next commit (it is possible that they are marked as missing when doing a commit). If for some reason they are not removed in your next commit then please right click on the folder (in the commit) and click 'remove'.
     
  42. Sharlatan

    Sharlatan

    Joined:
    Jul 23, 2013
    Posts:
    111
    Hey there! Looks great! Do you have any idea about an ETA for the move/rename functionality or do you think it's even possible in a manner that doesn't cause any problems?
    This feature would definitely make it a must buy for me.

    Thanks for your answer!
     
  43. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    Hi @Sharlatan,

    The move/rename functionality has been added since version 1.1.3. It is currently in a basic state, you will get a move/rename popup window when you try to rename a file (using F2) or you can right-click in the project window and go to Svn > Rename or Svn > Move. The functionality will stay like this for a while, until it is sure that it can work 100% without any user interaction, at that time it will be added as an automatic background operation (for Unity Pro users only, unfortunately).
     
  44. Sharlatan

    Sharlatan

    Joined:
    Jul 23, 2013
    Posts:
    111
    @Visual Design Cafe Thanks for the fast reply! And sorry I missed that this functionality was already added. I read a bit of the thread completely, then glanced over the rest of the entries and even used the search function. Either it wasn't mentioned here or I missed it.. sorry for that!

    Anyway, thanks again! Considering your overall interaction in this thread and how fast you replied to me, I feel very confident that I'll be a very happy customer of yours!

    Keep up the great work!

    Edit: One more question that just popped into my mind: I'm a pro user at the moment but not sure yet I'll buy the next version of Unity Pro as I don't feel the features that are provided with Pro are worth it to me. I'll take it you'll still leave the F2/right click option in so non-Pro users can use the feature too..?
     
  45. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
  46. joe_ftg

    joe_ftg

    Joined:
    Nov 9, 2015
    Posts:
    42
    This is a great asset, nice work.

    Is there any way to access the API so I can for instance revert a list of assets that one of my editor scripts generates?
     
  47. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @joe_ftg
    Thanks, glad you like Svn Tools! The API is currently not publicly available, although API access is being worked on. A large part of this is already finished but it will take a few more months to have this ready.
    Access to the API should be accompanied with proper documentation and tutorials and unfortunately this is very time consuming.
     
  48. joe_ftg

    joe_ftg

    Joined:
    Nov 9, 2015
    Posts:
    42
    Thanks for the reply about the API.

    An issue I'm seeing at the moment is if I replace an asset in a script using AssetDatabase.CreateAsset, SVN Tools detects that unity deletes the old file but not that a new file has replaced it. So when I try to check in, I have to manually select the files it says has deleted and add them again.
     
  49. Visual-Design-Cafe

    Visual-Design-Cafe

    Joined:
    May 23, 2015
    Posts:
    508
    @joe_ftg
    The issue you are seeing happens because the internal cache is not updated immediately after deleting the old file. You can access some basic functionality of SVN Tools to automate this process, I have written a small script for you to fix this specific issue:

    Code (CSharp):
    1. // Create your asset. SVN Tools will automatically remove any previous assets.
    2. AssetDatabase.CreateAsset( yourNewAsset, "Assets/Your New Asset.asset" );
    3.  
    4. // Force SVN Tools to refresh the cache, otherwise the asset won't be marked as 'Removed'
    5. // and will be ignored in the next 'Add' command.
    6. EditorApplication.ExecuteMenuItem( "Assets/Svn/Refresh" );
    7.      
    8. // Select the new asset, SVN Tools only executes the menu commands for the current selection,
    9. // meta files are included automatically.
    10. Selection.objects = new Object[] { yourNewAsset };
    11.  
    12. // Execute the 'Add' command for the selection, this will add the new asset.
    13. EditorApplication.ExecuteMenuItem( "Assets/Svn/Add" );
    14.      
    15. // The asset should now be marked as 'Replaced' in SVN
     
  50. coke_fenta

    coke_fenta

    Joined:
    Jun 8, 2015
    Posts:
    3
    it can be used,but i find a problem in the it.
    as the image
    int the version control setting ,the status of the repository is worry.
    it shows "155007 : path is not a working copy directory"
    and "the repository URL" can not write in~~
    upload_2016-11-2_10-36-37.png

    how can i solve this problem???
    Steps are all in accordance with the document.
     
unityunity