if(key == IDCANCEL)\r
return FALSE;\r
\r
- CString cmd;\r
+ CString format;\r
if(key == IDNO)\r
- cmd=_T("git.exe rm -r -f ");\r
+ format=_T("git.exe rm -r -f \"%s\"");\r
\r
if(key == IDYES)\r
- cmd= _T("git.exe update-index --force-remove -- ");\r
+ format= _T("git.exe update-index --force-remove -- \"%s\"");\r
\r
- for(int nPath = 0; nPath < pathList.GetCount(); nPath++)\r
+ CString output;\r
+ CString cmd;\r
+ int nPath;\r
+ for(nPath = 0; nPath < pathList.GetCount(); nPath++)\r
{\r
- CString output;\r
- if(g_Git.Run(cmd+pathList[nPath].GetGitPathString(),&output,CP_OEMCP))\r
+\r
+ cmd.Format(format,pathList[nPath].GetGitPathString());\r
+ if(g_Git.Run(cmd,&output,CP_OEMCP))\r
{\r
- key=CMessageBox::Show(hwndExplorer, output, _T("TortoiseGit"), MB_ICONINFORMATION|MB_OKCANCEL);\r
+ key=CMessageBox::Show(hwndExplorer, output, _T("TortoiseGit"), MB_ICONERROR|MB_OKCANCEL);\r
if(key == IDCANCEL)\r
return FALSE;\r
\r
}\r
}\r
\r
+ output.Format(_T("%d files removed"),nPath);\r
+ \r
+ CShellUpdater::Instance().AddPathsForUpdate(pathList);\r
+\r
+ CMessageBox::Show(hwndExplorer, output, _T("TortoiseGit"), MB_ICONINFORMATION|MB_OK);\r
+\r
+ CShellUpdater::Instance().Flush();\r
return bRet;\r
}\r