[cpp]
<PRE class=plain name="code"></PRE>
<PRE></PRE>
<P>TortoiseSVN設置-》常規設置-》subversion 配置文件 -》編輯<BR>
或者<BR>
Windows XP 在 C:\Documents and Settings\Administrator\Application Data\Subversion\config 文件<BR>
Windows7 在 C:\Users\Administrator\AppData\Roaming\Subversion\config 文件<BR>
注意:Administrator為用戶名<BR>
<BR>
<BR>
</P>
<P><SPAN style="COLOR: rgb(255,0,0)">第一步:</SPAN><BR>
解除enable-auto-props的注釋(刪掉前面的#):<BR>
enable-auto-props = yes<BR>
<BR>
<BR>
<SPAN style="COLOR: #ff0000">第二步:</SPAN><BR>
[auto-props] 下面加入<BR>
[auto-props]<BR>
*.c = svn:keywords=Author Date Id Revision URL Header<BR>
*.cpp = svn:keywords=Author Date Id Revision URL Header<BR>
*.h = svn:keywords=Author Date Id Revision URL Header</P>
<P><BR>
按照自己的擴展名需求來添加即可。<BR>
如果需要更多的關鍵字,可空格分隔即可。</P>
<P>如:<SPAN style="COLOR: #ff0000">svn:keywords=Author Date Id Revision URL Header</SPAN><BR>
<BR>
---------------------------------------------------------------------------------------------------------------------------------------<BR>
上面的方法只對新加入SVN的文件有效,如果要對SVN中已有的文件追加對$Id$識別,執行這個命令:<BR>
<SPAN style="WHITE-SPACE: pre"> svn propset svn:keywords "Id"</SPAN></P>
<P><BR>
</P>
<P>常用.h .cpp文件頭</P>
<P></P>
<PRE class=cpp name="code">/**
@(#)$Id$
@brief Multi-threaded programming critical section (lock)
@Author $Author$
@Date $Date$
@Revision $Revision$
@URL $URL$
@Header $Header$
*/
</PRE><BR>
<BR>
<P></P>
<P><BR>
常用文件設置屬性<BR>
</P>
<P></P>
<PRE class=plain name="code"># Image formats
*.bmp = svn:mime-type=image/bmp
*.gif = svn:mime-type=image/gif
*.ico = svn:mime-type=image/ico
*.jpeg = svn:mime-type=image/jpeg
*.jpg = svn:mime-type=image/jpeg
*.png = svn:mime-type=image/png
*.tif = svn:mime-type=image/tiff
*.tiff = svn:mime-type=image/tiff
# Data formats
*.pdf = svn:mime-type=application/pdf
*.avi = svn:mime-type=video/avi
*.doc = svn:mime-type=application/msword
*.eps = svn:mime-type=application/postscript
*.gz = svn:mime-type=application/gzip
*.mov = svn:mime-type=video/quicktime
*.mp3 = svn:mime-type=audio/mpeg
*.ppt = svn:mime-type=application/vnd.ms-powerpoint
*.ps = svn:mime-type=application/postscript
*.psd = svn:mime-type=application/photoshop
*.rtf = svn:mime-type=text/rtf
*.swf = svn:mime-type=application/x-shockwave-flash
*.tgz = svn:mime-type=application/gzip
*.wav = svn:mime-type=audio/wav
*.xls = svn:mime-type=application/vnd.ms-excel
*.zip = svn:mime-type=application/zip
# Text formats
.htaccess = svn:eol-style=native; svn:mime-type=text/plain
*.css = svn:eol-style=native; svn:mime-type=text/css
*.dtd = svn:eol-style=native; svn:mime-type=text/xml
*.htm = svn:eol-style=native; svn:mime-type=text/html
*.html = svn:eol-style=native; svn:mime-type=text/html
*.ini = svn:eol-style=native; svn:mime-type=text/plain
*.sql = svn:eol-style=native; svn:mime-type=text/x-sql; svn:keywords=Id
*.txt = svn:eol-style=native; svn:mime-type=text/plain
*.xhtml = svn:eol-style=native; svn:mime-type=text/xhtml+xml
*.xml = svn:eol-style=native; svn:mime-type=text/xml
# Code formats
*.js = svn:eol-style=native; svn:mime-type=text/javascript
*.inc = svn:eol-style=native; svn:mime-type=text/x-php
*.php = svn:eol-style=native; svn:mime-type=text/x-php; svn:keywords=Id</PRE><BR>
<BR>
<P></P>