zoukankan      html  css  js  c++  java
  • SVN 悲观锁 五步曲

    In some case you need to force developers to always lock files on a project when they make changes. If this property is set the developers is forced to lock a file and then only he can make changes to that file. You will still have the functionality to steal locks when someone isn’t available to unlock a file.

    Here is how you need to setup your SVN solution.

    Step 1:

    Go to the properties screen of your repository.

    022210_0659_SVNneedsloc1

    Step 2:

    Click “New” to add a new property. Select “SVN:needs-lock” under Property Name. Give the following Property Value: “*”. This will set the property to all files in repository. Check the checkbox next to “Apply property recursively”. Click OK.

    022210_0659_SVNneedsloc2

    Step 3:

    The property will now be set to all your files. You need to commit all the files for the change to take effect.

    Step 4:

    Next you need to set properties in the Subversion config file on each user’s local machine. This config file ensures that every new file that’s added to your repository, property ’svn:needs-lock’, is also set.

    The config file will be in the following directory: “C:\Users\\AppData\Roaming\Subversion\”

    Open the ‘config’ file in notepad:

    Make sure your config file resembles the following:

    “### Automatic properties are defined in the section ‘auto-props’.
    enable-auto-props = yes

    ### Section for configuring automatic properties.
    [auto-props]
    *.* = svn:needs-lock = true”

    Step 5:

    Save the config file.

  • 相关阅读:
    Servlet 的生命周期
    关于JSP
    JQuery事件绑定
    JavaScript中操作元素
    javaScript的函数使用
    Servlet 的API
    JavaScript中BOM对象
    gridview 绑定时间列 取短日期
    A4纸网页打印中对应像素的设定和换算
    动态添加 控件 并获取值
  • 原文地址:https://www.cnblogs.com/wangcl/p/2149748.html
Copyright © 2011-2022 走看看