Hi,
I created a post-receive hook using python.
I put the hook into the hooks folder of a remote repository on the same machine where I run SCM Manager application. Operating System: Windows 2016 Server.
The hook works fine.
When I put the same hook into a SCM hooks repository:
repository
+ data
++ hooks
It doesn’t work; I receive the following error:
remote: error: [SCM] failure during file hook execution
from log:
2024-05-21 16:58:51.418 [qtp1288354730-103] [FdUDQAhyNi] ERROR sonia.scm.web.GitFileHook - failure during file hook execution
java.io.IOException: Cannot run program “D:\SCM-Manager\repositories\72UD2QABi3E\data\hooks\post-receive” (in directory “D:\SCM-Manager\repositories\72UD2QABi3E\data”): CreateProcess error=193, %1 is not a valid Win32 application
but, if I create a .bat file: post-receive.bat:
@echo off
echo Hello, World!
pause
It works.
Can you please help me?
Thanks,
Paolo