Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #71932 > unrolled thread

Re: shebang & windows: call an extensionless git hook

Started byAlbert-Jan Roskam <fomcl@yahoo.com>
First post2014-05-23 08:09 -0700
Last post2014-05-23 08:09 -0700
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: shebang & windows: call an extensionless git hook Albert-Jan Roskam <fomcl@yahoo.com> - 2014-05-23 08:09 -0700

#71932 — Re: shebang & windows: call an extensionless git hook

FromAlbert-Jan Roskam <fomcl@yahoo.com>
Date2014-05-23 08:09 -0700
SubjectRe: shebang & windows: call an extensionless git hook
Message-ID<mailman.10247.1400857942.18130.python-list@python.org>
----- Original Message -----
> From: Chris Angelico <rosuav@gmail.com>
> To: 
> Cc: Python <python-list@python.org>
> Sent: Friday, May 23, 2014 4:01 PM
> Subject: Re: shebang & windows: call an extensionless git hook
> 
> On Fri, May 23, 2014 at 11:53 PM, Albert-Jan Roskam
> 
> <fomcl@yahoo.com.dmarc.invalid> wrote:
>>  Ok, I just found out that the script works as-is under Windows (I need to 
> save it as 'pre-commit', not as 'pre-commit.py'. That's 
> great, though I still don't understand how Windows (or Git) knows how to do 
> with it.
>> 
> 
> Are you running git from inside bash? If so, it's probably parsing the
> shebang and simulating a Unixesque environment, as part of the whole
> "let's try to make Unix stuff mostly work" policy. I'm amazed 
> at how
> well it actually works; from drive letters to execution differences,
> everything's somehow finagled into operation.

Hi,
 
I just used cmd.exe and did some commits. And it just worked. Not sure about TortoiseGit. (*note to self: check this next week!*)
Maybe Git does something with the 'mode python' shebang (and python is on PATH). 
 
regards,
Albert-Jan  

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web