I want to make post-commit hook that copy and commits all files to directory named "2" when I commit the directory named "1".
I use post-commit hook in server-side. my batch file is following:
svn update D:\test\1\ --trust-server-cert --non-interactive --username MyUserName --password "mypassword"
svn update D:\test\2\ --trust-server-cert --non-interactive --username MyUserName --password "mypassword"
svn add "D:\test\1\*" --trust-server-cert --non-interactive --username MyUserName --password "mypassword"
del /Q /S "D:\test\2\*.*"
xcopy /y "D:\test\1\" "D:\test\2\" /E /I
D:
cd D:\test\2\*
svn add * --trust-server-cert --non-interactive --username MyUserName --password "mypassword"
svn remove * --trust-server-cert --non-interactive --username MyUserName --password "mypassword"
svn commit --trust-server-cert --non-interactive --username MyUserName --password "mypassword" -m "[%DATE%] Data Synchronize"
that is my batch. and when I commit something then, errors pop up. that is my errors.
Error: post-commit hook failed (exit code 1) with output:
Error: svn: E170013: Unable to connect to a repository at URL 'url/svn/test'
Error: svn: E230001: Server SSL certificate verification failed: certificate issued for a different hostname, issuer is not trusted
Error: svn: E170013: Unable to connect to a repository at URL 'url/svn/test'
Error: svn: E230001: Server SSL certificate verification failed: certificate issued for a different hostname, issuer is not trusted
Error: svn: warning: W150002: 'D:\test\1\aef.txt' is already under version control
Error: svn: warning: W150002: 'D:\test\1\aiaiaiai.txt' is already under version control
Error: svn: warning: W150002: 'D:\test\1\asd (2).txt' is already under version control
Error: svn: warning: W150002: 'D:\test\1\df.txt' is already under version control
Error: svn: warning: W150002: 'D:\test\1\hooking.....txt' is already under version control
Error: svn: E200009: Could not add all targets because some targets are already versioned
Error: svn: E200009: Illegal target for the requested operation
Error: svn: warning: W150002: 'D:\test\2\aef.txt' is already under version control
Error: svn: warning: W150002: 'D:\test\2\aiaiaiai.txt' is already under version control
Error: svn: warning: W150002: 'D:\test\2\asd (2).txt' is already under version control
Error: svn: warning: W150002: 'D:\test\2\df.txt' is already under version control
Error: svn: warning: W150002: 'D:\test\2\hooking.....txt' is already under version control
Error: svn: E200009: Could not add all targets because some targets are already versioned
Error: svn: E200009: Illegal target for the requested operation
Error: svn: E170013: Commit failed (details follow):
Error: svn: E170013: Unable to connect to a repository at URL 'url/svn/test/2'
Error: svn: E230001: Server SSL certificate verification failed: certificate issued for a different hostname, issuer is not trusted
svn client (when committing something) and svn server are different machines.
how can I solve it?
Do I need other tools?