1
HI,SVN後提交作品只能手動
我已經創建了一個所謂的後commit.bat批處理文件,並把它放在/ hooks目錄下。
文件的內容是:
TestCS.exe
的exe文件的內容是:
static void Main(string[] args)
{
try
{
// create a writer and open the file
TextWriter tw = new StreamWriter("date.txt");
// write a line of text to the file
tw.WriteLine(DateTime.Now);
// close the stream
tw.Close();
}
catch { }
}
當我上commit.bat後雙擊,它創建的日期。 txt文件。
當我在SVN提交,這需要時間,並最終使我有以下消息: alt text http://img688.imageshack.us/img688/3894/exception.jpg
可以採取什麼問題嗎?
謝謝!
我試過using語句,仍然是一樣的。甚至刪除了字符串args []。還是一樣。 – Oded 2010-02-01 08:09:01
我想通了。 當運行testCS.exe時,它顯然在/ SVNServer/bin中查找文件,而不是在鉤子文件夾中。在bin文件夾中,我有一個帶有IndexOutOfRangeException的testCS.exe文件。 謝謝。 – Oded 2010-02-01 08:29:57
我幾乎提到「你確定你在運行你認爲你正在運行的二進制文件」,但最終沒有打擾。哎呀。 – 2010-02-01 09:36:47