Get SVN File Locks

It is good practice to get a file lock before editing a file. The lock tells other users that the file is being edited, and you can avoid merge issues. When you set up source control, you can configure SVN to make files with certain extensions read only. Users must get a lock on these read-only files before editing.

In the Current Folder browser, select the files you want to check out. Right-click the selected files and select Source Control > Get File Lock. A lock symbol appears in the source control status column. Other users cannot see the lock symbol in their sandboxes, but they cannot get a file lock or check in a change when you have the lock.

If you see an SVN message reporting a working copy locked error, remove stale locks. In the Current Folder browser, right-click and select Source Control > SVN Cleanup. SVN uses working copy locks internally and they are not the file locks you control using Source Control > Get File Lock.

Related Examples

Was this topic helpful?