Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


#ActualBinaryPhysics

Posted 23 December 2012 - 06:39 PM

I'm currently attempting to construct a simple automated build server so that I can move towards a form of continual delivery on one of my projects. This involves an automated building system.

I use Git and I found this topic on hooks that allows Git to execute scripts based on events. The issue is that I'm using Windows ('$(GIT_DIR)\cmd' is on my path and I execute everything in the command line native to Windows) and I want to write the scripts in batch (rather than learning Bash or whatever).

However, I can't get any of the scripts to work. Surely they're automatically executed in the environment Git is being run in? I've only tried experiments like:

ECHO hello, world!

But nothing ever appears in the console. I've tried naming the hook 'post-commit' and 'post-commit.bat' but nothing ever happens when I make a commit.

I'm working off the assumption that I can use batch. My justification is based on the Git book on the website:

All the examples are written as shell scripts, with some Perl thrown in, but any properly named executable scripts will work fine — you can write them in Ruby or Python or what have you.

What am I doing wrong?

EDIT: Git spits out "error: cannot spawn .git/hooks/post-commit: No such file or directory" when I commit.

#10BinaryPhysics

Posted 23 December 2012 - 06:38 PM

I'm currently attempting to construct a simple automated build server so that I can move towards a form of continual delivery on one of my projects. This involves an automated building system.

I use Git and I found this topic on hooks that allows Git to execute scripts based on events. The issue is that I'm using Windows ('$(GIT_DIR)\cmd' is on my path and I execute everything in the command line native to Windows) and I want to write the scripts in batch (rather than learning Bash or whatever).

However, I can't get any of the scripts to work. Surely they're automatically executed in the environment Git is being run in? I've only tried experiments like:

ECHO hello, world!

But nothing ever appears in the console. I've tried naming the hook 'post-commit' and 'post-commit.bat' but nothing ever happens when I make a commit.

I'm working off the assumption that I can use batch. My justification is based on the Git book on the website:
All the examples are written as shell scripts, with some Perl thrown in, but any properly named executable scripts will work fine — you can write them in Ruby or Python or what have you.
What am I doing wrong?

EDIT: Git spits out
error: cannot spawn .git/hooks/post-commit: No such file or directory
when I commit.

#9BinaryPhysics

Posted 23 December 2012 - 06:37 PM

I'm currently attempting to construct a simple automated build server so that I can move towards a form of continual delivery on one of my projects. This involves an automated building system.

I use Git and I found this topic on hooks that allows Git to execute scripts based on events. The issue is that I'm using Windows ('$(GIT_DIR)\cmd' is on my path and I execute everything in the command line native to Windows) and I want to write the scripts in batch (rather than learning Bash or whatever).

However, I can't get any of the scripts to work. Surely they're automatically executed in the environment Git is being run in? I've only tried experiments like:

ECHO hello, world!

But nothing ever appears in the console. I've tried naming the hook 'post-commit' and 'post-commit.bat' but nothing ever happens when I make a commit.

 

 

I'm working off the assumption that I can use batch. My justification is based on the Git book on the website:

 

All the examples are written as shell scripts, with some Perl thrown in, but any properly named executable scripts will work fine — you can write them in Ruby or Python or what have you.


What am I doing wrong?
 

EDIT: Git spits out

 

error: cannot spawn .git/hooks/post-commit: No such file or directory

 

when I commit.

 


#8BinaryPhysics

Posted 23 December 2012 - 06:36 PM

I'm currently attempting to construct a simple automated build server so that I can move towards a form of continual delivery on one of my projects. This involves an automated building system.

I use Git and I found this topic on hooks that allows Git to execute scripts based on events. The issue is that I'm using Windows ('$(GIT_DIR)\cmd' is on my path and I execute everything in the command line native to Windows) and I want to write the scripts in batch (rather than learning Bash or whatever).

However, I can't get any of the scripts to work. Surely they're automatically executed in the environment Git is being run in? I've only tried experiments like:

ECHO hello, world!

But nothing ever appears in the console.

I've tried naming the hook 'post-commit' and 'post-commit.bat' but nothing ever happens when I make a commit.

What am I doing wrong?

I'm working off the assumption that I can use batch. My justification is based on the Git book on the website:
 

All the examples are written as shell scripts, with some Perl thrown in, but any properly named executable scripts will work fine — you can write them in Ruby or Python or what have you.

 

EDIT: Git spits out

 

error: cannot spawn .git/hooks/post-commit: No such file or directory

 

when I commit.


#7BinaryPhysics

Posted 23 December 2012 - 06:29 PM

I'm currently attempting to construct a simple automated build server so that I can move towards a form of continual delivery on one of my projects. This involves an automated building system.

I use Git and I found this topic on hooks that allows Git to execute scripts based on events. The issue is that I'm using Windows ('$(GIT_DIR)\cmd' is on my path and I execute everything in the command line native to Windows) and I want to write the scripts in batch (rather than learning Bash or whatever).

However, I can't get any of the scripts to work. Surely they're automatically executed in the environment Git is being run in? I've only tried experiments like:
ECHO hello, world!
But nothing ever appears in the console.

I've tried naming the hook 'post-commit' and 'post-commit.bat' but nothing ever happens when I make a commit.

What am I doing wrong?

I'm working off the assumption that I can use batch. My justification is based on the Git book on the website:

All the examples are written as shell scripts, with some Perl thrown in, but any properly named executable scripts will work fine — you can write them in Ruby or Python or what have you.

#6BinaryPhysics

Posted 23 December 2012 - 06:28 PM

I'm currently attempting to construct a simple automated build server so that I can move towards a form of continual delivery on one of my projects. This involves an automated building system.

I use Git and I found this topic on hooks that allows Git to execute scripts based on events. The issue is that I'm using Windows ('$(GIT_DIR)\cmd' is on my path and I execute everything in the command line native to Windows) and I want to write the scripts in batch (rather than learning Bash or whatever).

However, I can't get any of the scripts to work. Surely they're automatically executed in the environment Git is being run in? I've only tried experiments like:
ECHO hello, world!
But nothing ever appears in the console.

I've tried naming the hook 'post-commit' and 'post-commit.bat' but nothing ever happens when I make a commit.

What am I doing wrong?

I'm working off the assumption that I can use batch. My justification is based on the Git book on the website:

All the examples are written as shell scripts, with some Perl thrown in, but any properly named executable scripts will work fine — you can write them in Ruby or Python or what have you.

PARTNERS